|
|
@@ -327,8 +327,8 @@ class CheckOrderClass extends BaseClass
|
|
|
$avCost = 0;
|
|
|
$changeCost = 0;
|
|
|
$unitCost = 0;
|
|
|
- $totalCost = 0;
|
|
|
- $totalStock = 0;
|
|
|
+ $remainCost = 0;
|
|
|
+ $remainStock = 0;
|
|
|
if (isset($params['motherId']) && $params['motherId'] > 0) {
|
|
|
$motherInfo = ProductClass::getById($params['motherId'], true);
|
|
|
$unitCost = $motherInfo->avCost ?? 0;
|
|
|
@@ -413,8 +413,8 @@ class CheckOrderClass extends BaseClass
|
|
|
$record['avCost'] = $avCost;
|
|
|
$record['changeCost'] = $changeCost;
|
|
|
$record['unitCost'] = $unitCost;
|
|
|
- $record['totalStock'] = $totalStock;
|
|
|
- $record['totalCost'] = $totalCost;
|
|
|
+ $record['totalStock'] = $remainStock;
|
|
|
+ $record['totalCost'] = $remainCost;
|
|
|
StockRecordClass::addCheckOrderRecord($record);
|
|
|
|
|
|
$amount = $v['amount'] ?? 0;
|