From 77024aeace1f6c9ac2b6e45d4b70cf1c7524b751 Mon Sep 17 00:00:00 2001 From: fomichev Date: Wed, 25 Jun 2025 10:16:09 +0300 Subject: [PATCH] =?utf8?q?=D0=A3=D0=B1=D1=80=D0=B0=D0=BB=20=D0=BE=D0=BA?= =?utf8?q?=D1=80=D1=83=D0=B3=D0=BB=D0=B5=D0=BD=D0=B8=D0=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- erp24/web/js/category-plan/index.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/erp24/web/js/category-plan/index.js b/erp24/web/js/category-plan/index.js index 65f57972..9962ca9f 100644 --- a/erp24/web/js/category-plan/index.js +++ b/erp24/web/js/category-plan/index.js @@ -64,13 +64,13 @@ function editField(zis) { // пересчитываем % p1Input.value = p1Cell.dataset.offline > 0 - ? (100 * offlineVal / +p1Cell.dataset.offline).toFixed(2) + ? (100 * offlineVal / +p1Cell.dataset.offline) : 0; p2Input.value = p2Cell.dataset.online > 0 - ? (100 * internetVal / +p2Cell.dataset.online).toFixed(2) + ? (100 * internetVal / +p2Cell.dataset.online) : 0; p3Input.value = p3Cell.dataset.writeoffs > 0 - ? (100 * writeoffsVal / +p3Cell.dataset.writeoffs).toFixed(2) + ? (100 * writeoffsVal / +p3Cell.dataset.writeoffs) : 0; // сохраняем на сервере @@ -102,19 +102,19 @@ function editProcent(zis, num) { switch (num) { case 1: { const pct = +p1Cell.querySelector('input').value; - const newVal = (pct / 100 * +p1Cell.dataset.offline).toFixed(2); + const newVal = (pct / 100 * +p1Cell.dataset.offline); tr.querySelector(`td[data-offline-type="${type}"] input[name="offline"]`).value = newVal; break; } case 2: { const pct = +p2Cell.querySelector('input').value; - const newVal = (pct / 100 * +p2Cell.dataset.online).toFixed(2); + const newVal = (pct / 100 * +p2Cell.dataset.online); tr.querySelector(`td[data-online-type="${type}"] input[name="internet_shop"]`).value = newVal; break; } case 3: { const pct = +p3Cell.querySelector('input').value; - const newVal = (pct / 100 * +p3Cell.dataset.writeoffs).toFixed(2); + const newVal = (pct / 100 * +p3Cell.dataset.writeoffs); tr.querySelector(`td[data-writeoffs-type="${type}"] input[name="write_offs"]`).value = newVal; break; } -- 2.39.5