调整商品溯源
This commit is contained in:
parent
c9684b2f8b
commit
a49919882a
@ -268,6 +268,7 @@ class ProductSourceLinkLogic extends BaseLogic
|
||||
if ($inventoryTransfer['two_type'] == 1) {
|
||||
$info['store_id'] = $inventoryTransfer['two_id'];
|
||||
} else {
|
||||
$info['store_id'] = $inventoryTransfer['one_id'];
|
||||
$info['warehouse_id'] = $inventoryTransfer['two_id'];
|
||||
}
|
||||
$list = $query->where('current_nums', '>', 0)
|
||||
|
@ -99,9 +99,10 @@ class WarehouseProductReturnLogic extends BaseLogic
|
||||
|
||||
WarehouseProductReturn::create($datas);
|
||||
|
||||
$updateNums = bcsub($params['nums'], $find['nums'],2);
|
||||
if ($updateNums != 0) {
|
||||
WarehouseProductLogic::updateProductSourceLink($find, $params, $updateNums);
|
||||
$updateNums = bcsub($find['nums'], $params['nums'], 2);
|
||||
if ($params['nums'] != 0) {
|
||||
$numTemp = bcsub($find['nums'], $params['nums'], 2);
|
||||
WarehouseProductLogic::updateProductSourceLink($find, array_merge($params, ['nums' => $numTemp]), $updateNums);
|
||||
}
|
||||
|
||||
if ($params['financial_pm'] == 1 && $params['return_type'] == 1) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user