mirror of
https://gitee.com/hzchunfen/erp.git
synced 2025-12-01 06:30:49 +00:00
鲜花2.0-采购流程变更
This commit is contained in:
parent
53ac852284
commit
1b6bd4ffc4
@ -113,6 +113,12 @@ class GoodsCombinationController extends Controller
|
||||
|
||||
return response($this->res, $this->res['httpCode']);
|
||||
}
|
||||
$externalSkuId = $request->input('external_sku_id') ??
|
||||
GeneratorUtils::generateCombinationGoodNumber($request->combination_goods);
|
||||
$hasCodeSku = GoodsSku::query()->where("external_sku_id",$externalSkuId)->first();
|
||||
if(!empty($hasCodeSku)){
|
||||
throw new \Exception("该组合商品编码已存在");
|
||||
}
|
||||
DB::beginTransaction();
|
||||
try {
|
||||
$combinationGoods = $request->input('combination_goods');
|
||||
@ -142,8 +148,7 @@ class GoodsCombinationController extends Controller
|
||||
$sku->is_combination = 1;
|
||||
}
|
||||
|
||||
$externalSkuId = $request->input('external_sku_id') ??
|
||||
GeneratorUtils::generateCombinationGoodNumber($request->combination_goods);
|
||||
|
||||
$sku->status = $status;
|
||||
$sku->title = $request->input('title');
|
||||
$sku->name = $request->input('title');
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user