减少数据生成

This commit is contained in:
杨建炊 2024-12-10 17:46:11 +08:00
parent 1b06e308c8
commit 481042ac22

View File

@ -93,7 +93,8 @@ class BusinessGoodsSkusController extends Controller
if (empty($sku)) { if (empty($sku)) {
$this->setValidatorFailResponse('未找到对应的商品,请核实后再次同步或删除此平台商品'); $this->setValidatorFailResponse('未找到对应的商品,请核实后再次同步或删除此平台商品');
} else { } else {
event(new BusinessOrdersUpdate($businessGoodsSku, 0)); $shop = $businessGoodsSku->shop;
BusinessFactory::init()->make($shop['plat_id'])->setShopWithId($shop['id'])->incrQuantity($businessGoodsSku, 0, false);
$this->res['message'] = '库存同步请求发送成功,具体结果查看日志'; $this->res['message'] = '库存同步请求发送成功,具体结果查看日志';
} }
return response($this->res, $this->res['httpCode']); return response($this->res, $this->res['httpCode']);