From ca8500f81d53ebe24f2809e2c86ef98350efa896 Mon Sep 17 00:00:00 2001 From: Alexander Smirnov Date: Tue, 30 Jul 2024 15:28:33 +0300 Subject: [PATCH] =?utf8?q?=D0=9D=D0=B5=20=D1=84=D0=BB=D0=BE=D1=82=20=D0=BD?= =?utf8?q?=D0=B5=20=D0=B8=D0=BD=D1=82,=20=D0=B0=20=D1=86=D0=B5=D0=BB=D0=BE?= =?utf8?q?=D0=B5=20=D1=87=D0=B8=D1=81=D0=BB=D0=BE=20=D0=B8=20=D0=B4=D1=80?= =?utf8?q?=D0=BE=D0=B1=D1=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- erp24/services/MotivationService.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/erp24/services/MotivationService.php b/erp24/services/MotivationService.php index ca1aeed1..43b77979 100644 --- a/erp24/services/MotivationService.php +++ b/erp24/services/MotivationService.php @@ -88,8 +88,8 @@ class MotivationService continue; } switch ($motivationCostsItems[$row[0]]->data_type) { - case MotivationCostsItem::DATA_TYPE_INT: { if (is_int($row[2])) { $value = (int)$row[2]; } else { $error = "Не инт [$ind,2] '" . $row[2] . "'"; }; break; } - case MotivationCostsItem::DATA_TYPE_FLOAT: { if (is_int($row[2]) || is_float($row[2])) { $value = (float)$row[2]; } else {$error = "Не флот [$ind,2] '" . $row[2] . "'"; } break; } + case MotivationCostsItem::DATA_TYPE_INT: { if (is_int($row[2])) { $value = (int)$row[2]; } else { $error = "Не целое число [$ind,2] '" . $row[2] . "'"; }; break; } + case MotivationCostsItem::DATA_TYPE_FLOAT: { if (is_int($row[2]) || is_float($row[2])) { $value = (float)$row[2]; } else {$error = "Не дробь [$ind,2] '" . $row[2] . "'"; } break; } case MotivationCostsItem::DATA_TYPE_STRING: { $value = $row[2]; break; } } if (!empty($error)) { -- 2.39.5