feat: #10000 盘点导入数据更新,过滤空数据
This commit is contained in:
parent
1c4e9cc040
commit
73285afbc1
@ -82,6 +82,7 @@ class InventoryImport implements ToCollection, SkipsEmptyRows
|
||||
->pluck('id')
|
||||
->toArray();
|
||||
$downSkuIds = array_diff($onSkuIds, $updateIds);
|
||||
if ($downSkuIds) {
|
||||
$goodsSkus = GoodsSku::query()->whereIn('id', $downSkuIds)
|
||||
->get(['id', 'yesterday_num', 'stock'])
|
||||
->toArray();
|
||||
@ -91,6 +92,7 @@ class InventoryImport implements ToCollection, SkipsEmptyRows
|
||||
'stock' => 0,
|
||||
]);
|
||||
}
|
||||
}
|
||||
sleep(2);
|
||||
event(new StockUpdateEvent($onSkuIds, 1));
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user