FIX php 8 error
This commit is contained in:
parent
5146fee408
commit
9537fb3808
@ -48,11 +48,17 @@ if ($action == 'updateselectbatchbywarehouse' && $permissiontoproduce) {
|
|||||||
|
|
||||||
if ($resql) {
|
if ($resql) {
|
||||||
while ($obj = $db->fetch_object($resql)) {
|
while ($obj = $db->fetch_object($resql)) {
|
||||||
$TRes[$obj->batch] += $obj->qty;
|
if(empty($TRes[$obj->batch])){
|
||||||
|
$TRes[$obj->batch] = $obj->qty;
|
||||||
|
} else {
|
||||||
|
$TRes[$obj->batch] += $obj->qty;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
print json_encode($TRes);
|
echo json_encode($TRes);
|
||||||
|
exit();
|
||||||
|
|
||||||
} elseif ($action == 'updateselectwarehousebybatch' && $permissiontoproduce) {
|
} elseif ($action == 'updateselectwarehousebybatch' && $permissiontoproduce) {
|
||||||
$res = 0;
|
$res = 0;
|
||||||
|
|
||||||
@ -73,5 +79,7 @@ if ($action == 'updateselectbatchbywarehouse' && $permissiontoproduce) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
print json_encode($res);
|
echo json_encode($res);
|
||||||
|
exit();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user