dev #60

Merged
ksenia_mikhailova merged 48 commits from dev into main 2024-07-26 10:41:38 +03:00
1 changed files with 4 additions and 1 deletions
Showing only changes of commit f8a6cb4096 - Show all commits

View File

@ -101,10 +101,13 @@ const changeParametres = () => {
if (full_sections == 0) { if (full_sections == 0) {
length = total_length_mm - fence_length - fence_length length = total_length_mm - fence_length - fence_length
} }
if ((total_length_mm - ((full_sections * length) + (full_sections * fence_length) + fence_length)) < fence_length) {
full_sections -= 1
}
} }
if (((full_sections * length) + (full_sections * fence_length) + fence_length) < total_length_mm) { if (((full_sections * length) + (full_sections * fence_length) + fence_length) < total_length_mm) {
form_state.extra_section = total_length_mm - ((full_sections * length) + (full_sections * fence_length) + fence_length + fence_length) form_state.extra_section = total_length_mm - ((full_sections * length) + (full_sections * fence_length) + fence_length) - fence_length
} else { } else {
form_state.extra_section = 0 form_state.extra_section = 0
} }