cqp 2 ヶ月 前
コミット
57fffbce0b

+ 3 - 1
app/Model/ProductCategory.php

@@ -13,5 +13,7 @@ class ProductCategory extends UseScopeBaseModel
         1 => "是",
     ];
     const Special_for_roll = 112; //有模有样
-    const Special_for_sn = 133; //车窗膜
+    const Special_for_roll1 = 306; //改色膜
+    const Special_for_roll2 = 313; //彩色车衣
+    const Special_for_sn = 297; //车窗膜
 }

+ 1 - 1
app/Service/DataSyncToU8Service.php

@@ -216,7 +216,7 @@ class DataSyncToU8Service extends Service
 
     public function forCheck2($product_category){
         $category = json_decode($product_category,true);
-        if(in_array(ProductCategory::Special_for_roll, $category)) return true;
+        if(in_array(ProductCategory::Special_for_roll1, $category) || in_array(ProductCategory::Special_for_roll2, $category)) return true;
         return false;
     }
 

+ 2 - 2
app/Service/ProductService.php

@@ -1313,7 +1313,7 @@ class ProductService extends Service
         foreach ($data['data'] as $key => $value){
             $arr = json_decode($value['product_category'], true);
             $arr = array_flip($arr);
-            if (isset($arr[ProductCategory::Special_for_roll])) {
+            if (isset($arr[ProductCategory::Special_for_roll1]) || isset($arr[ProductCategory::Special_for_roll2])) {
                 $data['data'][$key]['is_roll'] = true;
                 $is_roll = true;
             }else{
@@ -1394,7 +1394,7 @@ class ProductService extends Service
             $product[$key]['unit_title'] = $basic_map[$value['unit']] ?? "";
             $arr = json_decode($value['product_category'], true);
             $arr = array_flip($arr);
-            if (isset($arr[ProductCategory::Special_for_roll])) {
+            if (isset($arr[ProductCategory::Special_for_roll1]) || isset($arr[ProductCategory::Special_for_roll2])) {
                 $product[$key]['is_roll'] = true;
             }else{
                 $product[$key]['is_roll'] = false;