|
@@ -18,10 +18,10 @@ class OrderOutChild extends Model
|
|
|
static function makeChild(string $outCode=''){
|
|
|
if($outCode=='')throw new \Exception("分单发货单单号不能为空");
|
|
|
$out=self::name("order_out")->where(["outCode"=>$outCode,"is_del"=>0])->findOrEmpty();
|
|
|
- if(empty($out)) throw new \Exception("发货单信息为找到");
|
|
|
+ if(empty($out)) throw new \Exception("发货单信息未找到");
|
|
|
if($out['send_status']!=0) throw new \Exception("发货单拆单状态有误");
|
|
|
$sale = self::name("sale")->where(["orderCode"=>$out['orderCode'],"is_del"=>0])->findOrEmpty();
|
|
|
- if(empty($sale)) throw new \Exception("订单信息为找到");
|
|
|
+ if(empty($sale)) throw new \Exception("订单信息未找到");
|
|
|
if($sale['wsend_num']<$out['send_num']) throw new \Exception("订单待发货数量不足");
|
|
|
$num= $out['send_num'];
|
|
|
$wsmlist = self::name("good_stock")->alias("a")
|