|
@@ -28,7 +28,7 @@ class Good extends Base
|
|
|
'createrid' => '',
|
|
|
'status' => '',
|
|
|
'platform_code' => '',
|
|
|
- 'platform_type' => 1,
|
|
|
+ 'platform_type' => 2,
|
|
|
'plat_code' => '',
|
|
|
'exam_status' => '',
|
|
|
'brand_id' => '',
|
|
@@ -60,7 +60,7 @@ class Good extends Base
|
|
|
if ($param['create_source'] !== '') $where[] = ['a.create_source', '=', $param['create_source']];
|
|
|
if ($param['is_compliance'] !== '') $where[] = ['b.is_compliance', '=', $param['is_compliance']];
|
|
|
if ($param['brand_id'] !== '') $where[] = ['a.brand_id', '=', $param['brand_id']];
|
|
|
- if($param['platform_type'] == ''){
|
|
|
+ if($param['platform_type'] !== ''){
|
|
|
$platfromId = $platfrom->where(['platform_type'=>$param['platform_type'],'is_del'=>0])->column('id');
|
|
|
$where[] = ['b.platform_id', 'in', $platfromId ];
|
|
|
}
|
|
@@ -120,12 +120,12 @@ class Good extends Base
|
|
|
$platform = $goodPlat->where(['skuCode'=>$post['skuCode'],'is_del'=>0])->findOrEmpty();
|
|
|
if($platform->isEmpty()) $this->error('未找到商品数据');
|
|
|
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
+ if($platform->is_fixed==1){
|
|
|
+
|
|
|
+ $nake=$goodNake->where(['spuCode'=> $platform->spuCode,'is_del'=>0,'nake_fee'=>0])
|
|
|
+ ->findOrEmpty();
|
|
|
+ if($nake->isEmpty()) $this->error('一口价商品请先完善商品成本单价');
|
|
|
+ }
|
|
|
if($post['exam_status']==3){
|
|
|
$is_exit = $goodPlat
|
|
|
->where(['plat_code' =>$post['plat_code'],'is_del' =>0, 'exam_status' =>3])
|
|
@@ -158,28 +158,6 @@ class Good extends Base
|
|
|
];
|
|
|
$inr=(new GoodExam())->save($data);
|
|
|
if($inr){
|
|
|
- $event=[];
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
- if ($post['exam_status'] == 5) {
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
- }
|
|
|
if ($post['exam_status'] == 3) {
|
|
|
|
|
|
if($post['proof_url']!=''){
|
|
@@ -220,6 +198,7 @@ class Good extends Base
|
|
|
}else throw new Exception('商品审核失败');
|
|
|
}else throw new Exception('商品审核失败');
|
|
|
$platform->commit();
|
|
|
+
|
|
|
$event=[ 'order_type' => 'SPSX',
|
|
|
'order_code' =>$platform->skuCode,
|
|
|
'order_id' => $platform->id,
|
|
@@ -231,6 +210,7 @@ class Good extends Base
|
|
|
];
|
|
|
event('ProcessOrder',$event);
|
|
|
if($post['exam_status']==5){
|
|
|
+
|
|
|
$enevt=[
|
|
|
'spuCode' => $platform->spuCode,
|
|
|
'skuCodes' => $platform->skuCode,
|