wugg 2 gadi atpakaļ
vecāks
revīzija
a3c26d2dd9

+ 2 - 2
app/admin/controller/Activity.php

@@ -679,7 +679,7 @@ class Activity extends Base
           return error_show(1004,"参数skuCode不能为空");
       }
       $where=['a.is_del'=>0,"b.is_del"=>0,"a.status"=>6,"b.status"=>1,"b.skuCode"=>$skuCode];
-      $condition=['a.skuCode' =>$skuCode,"a.is_del"=>0,'a.exam_status'=>6];
+      $condition=['a.skuCode' =>$skuCode,"a.is_del"=>0,'a.exam_status'=>3];
       $company =  isset($this->post['companyNo'])&&$this->post['companyNo']!=""?trim($this->post['companyNo']):"";
       if($company!=""){
           $where['a.company_id'] = $company;
@@ -745,7 +745,7 @@ class Activity extends Base
     		return  error_show(1005,"活动商品信息不存在");
     	}
     	$good =  Db::name('good_platform')->alias('a')->join('good b', 'b.spuCode=a.spuCode', 'left')
-            ->where(['a.skuCode' =>$skuCode,"a.is_del"=>0,'a.exam_status'=>6])->findOrEmpty();
+            ->where(['a.skuCode' =>$skuCode,"a.is_del"=>0,'a.exam_status'=>3])->findOrEmpty();
 		if(empty($good)){
 			return  error_show(1005,"商品信息不存在或已下架");
 		}

+ 1 - 1
app/admin/controller/After.php

@@ -2314,7 +2314,7 @@ class After extends Base
         $goodinfo = Db::name('good')
             ->alias('g')
             ->field('g.*,gp.skuCode')
-            ->join('good_platform gp', 'gp.spuCode=g.spuCode AND gp.exam_status=6')
+            ->join('good_platform gp', 'gp.spuCode=g.spuCode AND gp.exam_status=3')
             ->where('g.spuCode', $spuCode)
             ->where('gp.skuCode', $old_sale['skuCode'])
             ->find();

+ 2 - 2
app/admin/controller/Good.php

@@ -1182,7 +1182,7 @@ class Good extends Base
     {
         $page = isset($this->post['page']) && $this->post['page'] !== "" ? intval($this->post['page']) : "1";
         $size = isset($this->post['size']) && $this->post['size'] !== "" ? intval($this->post['size']) : "10";
-        $where = [["a.is_del", "=", 0], ["b.exam_status", "=", 6], ["b.is_del", "=", 0], ["c.is_del", "=", 0], ["c.status", "=", 1]];
+        $where = [["a.is_del", "=", 0], ["b.exam_status", "=", 3], ["b.is_del", "=", 0], ["c.is_del", "=", 0], ["c.status", "=", 1]];
         $paltcode = isset($this->post["platform_code"]) && $this->post["platform_code"] != "" ? trim($this->post["platform_code"]) : "";
         if ($paltcode != "") {
             $where[] = ["platform_code", "=", $paltcode];
@@ -1319,7 +1319,7 @@ class Good extends Base
             'relaComNo'=>'',
         ], 'post', 'trim');
 
-        $where = [["gl.is_del", "=", 0], ['gp.exam_status', '=', 6]];//exam_status==6已上线
+        $where = [["gl.is_del", "=", 0], ['gp.exam_status', '=', 3]];//exam_status==6已上线
         if ($param['good_type']!='') $where[] = ['gb.good_type', '=', $param['good_type']];
 //        if (!empty($param['start'])) $where[] = ['gl.addtime', '>=', $param['start']];
 //        if (!empty($param['end'])) $where[] = ['gl.addtime', '<=', $param['end'] . ' 23:59:59'];

+ 11 - 10
app/admin/controller/Goodup.php

@@ -114,7 +114,7 @@ class Goodup extends Base
         }
         $isonline = isset($this->post['isonline']) && $this->post['isonline']!=="" ? $this->post['isonline']:"";
         if($isonline!==""){
-            $condit[] =['b.exam_status',"=",6];
+            $condit[] =['b.exam_status',"=",3];
 //            if($isonline==1){
 //                $condit[] =['b.exam_status',"=",6];
 //            }else{
@@ -194,11 +194,11 @@ class Goodup extends Base
         //查询一下这些spucode是否在平台上成功上线
         $exam_statuss = Db::name('good_platform')
             ->whereIn('spuCode',array_column($list,'spuCode'))
-            ->where(['is_del'=>0,'exam_status'=>6])//exam_status==6表示上线审核成功
+            ->where(['is_del'=>0,'exam_status'=>3])//exam_status==6表示上线审核成功
             ->column('id','spuCode');
         $exam_status_yz = Db::name('platform_youzan')
             ->whereIn('spuCode', array_column($list, 'spuCode'))
-            ->where(['is_del' => 0, 'exam_status' => 6])//exam_status==6表示上线审核成功
+            ->where(['is_del' => 0, 'exam_status' => 3])//exam_status==6表示上线审核成功
             ->column('id', 'spuCode');
 
         $account = checkHasAccountBySupplierNos(array_column($list, 'supplierNo'));
@@ -336,7 +336,7 @@ class Goodup extends Base
         }
         $isonline = isset($this->post['isonline']) && $this->post['isonline'] !== "" ? $this->post['isonline'] : "";
         if ($isonline !== "") {
-            $condit[] = ['b.exam_status', "=", 6];
+            $condit[] = ['b.exam_status', "=", 3];
 //            if($isonline==1){
 //                $condit[] =['b.exam_status',"=",6];
 //            }else{
@@ -407,11 +407,11 @@ class Goodup extends Base
         //查询一下这些spucode是否在平台上成功上线
         $exam_statuss = Db::name('good_platform')
             ->whereIn('spuCode', array_column($list, 'spuCode'))
-            ->where(['is_del' => 0, 'exam_status' => 6])//exam_status==6表示上线审核成功
+            ->where(['is_del' => 0, 'exam_status' => 3])//exam_status==3表示上线审核成功
             ->column('id', 'spuCode');
         $exam_status_yz = Db::name('platform_youzan')
             ->whereIn('spuCode', array_column($list, 'spuCode'))
-            ->where(['is_del' => 0, 'exam_status' => 6])//exam_status==6表示上线审核成功
+            ->where(['is_del' => 0, 'exam_status' => 3])//exam_status==3表示上线审核成功
             ->column('id', 'spuCode');
 
         $account = checkHasAccountBySupplierNos(array_column($list, 'supplierNo'));
@@ -833,7 +833,8 @@ class Goodup extends Base
         if($data==false){
             return error_show(1004,"未找到商品数据");
         }
-        $is_down = Db::name("good_platform")->where(["spuCode"=>$supcode,"is_del"=>0])->where("exam_status","<>",8)->find();
+        $is_down = Db::name("good_platform")->where(["spuCode"=>$supcode,"is_del"=>0])->where("exam_status","<>",5)
+        ->find();
         if($is_down!=false){
             return error_show(1004,"存在未下线商品数据");
         }
@@ -1105,7 +1106,7 @@ class Goodup extends Base
         if($datas==false){
             return error_show(1004,"未找到商品数据");
         }
-        $is_down = Db::name("good_platform")->where(["spuCode"=>$supcode,"is_del"=>0])->where("exam_status","<>",8)
+        $is_down = Db::name("good_platform")->where(["spuCode"=>$supcode,"is_del"=>0])->where("exam_status","<>",5)
             ->find();
         if($is_down!=false){
             return error_show(1004,"存在未下线商品数据");
@@ -1472,7 +1473,7 @@ class Goodup extends Base
                 ->field('gp.id,gp.exam_status,gp.skuCode')
                 ->leftJoin('good_platform gp', 'gp.spuCode=g.spuCode AND gp.is_del=0')
                 ->where(['g.spuCode' => $supcode, 'g.is_del' => 0])
-                ->whereNotIn('gp.exam_status', [1, 8])
+                ->where('gp.exam_status',"<>",5)
                 ->select()->toArray();
 
             if (!empty($good)) throw new Exception('该商品需要下线之后才能删除');
@@ -1488,7 +1489,7 @@ class Goodup extends Base
 
             Db::name("good_platform")
                 ->where(['spuCode' => $supcode, 'is_del' => 0])
-                ->whereIn('exam_status', [1, 8])
+                ->where('exam_status', "<>",5)
                 ->update(['is_del' => 1, 'updatetime' => date('Y-m-d H:i:s')]);
             Db::name("good_ladder")->where(["skuCode"=>array_column($good,"skuCode"),"is_del"=>0])->update(['is_del'
             => 1, 'updatetime' => date('Y-m-d H:i:s')]);

+ 4 - 3
app/admin/controller/OrderImport.php

@@ -102,7 +102,7 @@ class OrderImport extends Base
         if ($param['company_name']) $where[] = ['c.createrid', 'in', get_company_item_user_by_name($param['company_name'])];
 
         $total = OIFCModel::alias('c')
-            ->leftJoin('good_platform gp', 'gp.plat_code=c.plat_code AND gp.platform_code=c.platform_id AND gp.is_del=0 AND gp.exam_status=6')
+            ->leftJoin('good_platform gp', 'gp.plat_code=c.plat_code AND gp.platform_code=c.platform_id AND gp.is_del=0 AND gp.exam_status=3')
             ->leftJoin('good g', 'g.spuCode=gp.spuCode AND g.is_del=0')
             ->leftJoin('platform p', 'p.id=c.platform_id AND p.is_del=0')
             ->where($where)
@@ -110,7 +110,7 @@ class OrderImport extends Base
 
         $list = OIFCModel::alias('c')
             ->field('c.*,g.good_name,p.platform_name platform_title')
-            ->leftJoin('good_platform gp', 'gp.plat_code=c.plat_code AND gp.platform_code=c.platform_id AND gp.is_del=0 AND gp.exam_status=6')
+            ->leftJoin('good_platform gp', 'gp.plat_code=c.plat_code AND gp.platform_code=c.platform_id AND gp.is_del=0 AND gp.exam_status=3')
             ->leftJoin('good g', 'g.spuCode=gp.spuCode AND g.is_del=0')
             ->leftJoin('platform p', 'p.id=c.platform_id AND p.is_del=0')
             ->where($where)
@@ -349,7 +349,8 @@ class OrderImport extends Base
 
             $good_platform_info = Db::name('good_platform')
                 ->field('id,spuCode,platform_code,skuCode,plat_code')
-                ->where(['is_del' => 0, 'plat_code' => $param['plat_code'], 'platform_code' => $param['platform_id'], 'exam_status' => 6])//exam_status==6 已上线
+                ->where(['is_del' => 0, 'plat_code' => $param['plat_code'], 'platform_code' => $param['platform_id'],
+                 'exam_status' => 3])//exam_status==6 已上线
                 ->find();
 
             //商品信息

+ 2 - 2
app/command/ImportOrderFromCAnalysisData.php

@@ -106,7 +106,7 @@ class ImportOrderFromCAnalysisData extends Command
                     'is_del' => 0,
                     'plat_code' => $rs['plat_code'],
                     'platform_code' => $rs['platform_id'],
-                    'exam_status' => 6//exam_status==6 已上线
+                    'exam_status' => 3//exam_status==3 已上线
                 ])->find();
 
             //商品信息
@@ -250,7 +250,7 @@ class ImportOrderFromCAnalysisData extends Command
                 ->leftJoin('platform p', 'p.id=gp.platform_code AND p.is_del=0')
                 ->leftJoin('customer_org1 co', 'co.name=p.platform_name AND co.is_del=0')
                 ->where('gp.plat_code', $rs['plat_code'])
-                ->where('gp.exam_status', 6)//exam_status==6已上线
+                ->where('gp.exam_status', 3)//exam_status==3已上线
                 ->field('co.id,co.name')
                 ->find();
 

+ 1 - 1
app/command/ImportOrderFromCHandleData.php

@@ -102,7 +102,7 @@ class ImportOrderFromCHandleData extends Command
                 $ct = Db::name('good_platform')
                     ->alias('a')
                     ->join('good b', 'b.spuCode=a.spuCode', 'left')
-                    ->where(['a.skuCode' => $extend_data['skuCode'], 'a.exam_status' => 6])//exam_status==6已上线
+                    ->where(['a.skuCode' => $extend_data['skuCode'], 'a.exam_status' =>3])//exam_status==3已上线
                     ->field("b.*,a.skuCode,a.spuCode,a.platform_code,a.plat_code")
                     ->find();
                 if ($ct == false) throw new Exception('未找到商品数据');

+ 5 - 5
app/command/NowReportHandle.php

@@ -150,7 +150,7 @@ class NowReportHandle extends Command
         $list = [];
 
         $tmp_customer=[];
-        $userCommon = new User();
+        $userCommon = User::getIns();
         foreach ($data as $value) {
 
             $value['流程进度'] = isset($all_status[$value['流程进度']]) ? $all_status[$value['流程进度']] : '';
@@ -241,7 +241,7 @@ class NowReportHandle extends Command
             ->order('wgs.updatetime', 'desc')
             ->cursor();
 
-        $userCommon = new User();
+        $userCommon = User::getIns();
         $list = [];
         foreach ($data as $value) {
             $cat = made($value['一级分类']);
@@ -331,7 +331,7 @@ class NowReportHandle extends Command
 	ws.customer_code
 	")->order("wtd.addtime")->cursor();
 //if(wps.pay_type='0','现结',if(wps.pay_type='1','月结',if(wps.pay_type='2','双月结',wps.pay_type))) as '付款方式',
-        $userCommon = new User();
+        $userCommon = User::getIns();
 
         $temp_customer = [];
 
@@ -671,7 +671,7 @@ class NowReportHandle extends Command
 
         $list = $tmp_codes = $tmp_customer = [];
 
-        $userCommon = new User();
+        $userCommon = User::getIns();
         foreach ($data as $value) {
 
             if(!isset($tmp_codes[$value['supplierNo']])) {
@@ -737,7 +737,7 @@ class NowReportHandle extends Command
             ->order('wgs.addtime', 'desc')
             ->cursor();
 
-        $userCommon = new User();
+        $userCommon = User::getIns();
 
         $list = [];
         foreach ($data as $value) {

+ 1 - 1
app/command/handleYzOrderData.php

@@ -81,7 +81,7 @@ class handleYzOrderData extends Command
                     ->leftJoin('customer_org1 co', 'co.name=p.platform_name AND co.is_del=0')
                     ->leftJoin('good g', 'g.spuCode=py.spuCode AND g.is_del=0')
                     ->where('py.skuCode', $c_data['skuCode'])
-                    ->where('py.exam_status', 6)//exam_status==6已上线
+                    ->where('py.exam_status', 3)//exam_status==3已上线
                     ->find();
 
                 if ($ct) {