Browse Source

提交代码 测试 网站手工单

lvhao 19 hours ago
parent
commit
2850fb5f3e
1 changed files with 24 additions and 0 deletions
  1. 24 0
      core/CoreApp/models/Model_api.php

+ 24 - 0
core/CoreApp/models/Model_api.php

@@ -1622,9 +1622,33 @@ function __construct(){
 		$post['fpdata'] = $matching['product'];
 		$post['whlabel'] = $matching['whlabel'];
 		$post['slpx'] = $matching['wcslpx'];
+		$post['wzsgd'] = $this->checkWzsgd($product_ids_tmp,$shop['id']);
 		return $post;
 	}
 
+	public function  checkWzsgd($product_ids,$shopid){
+		$map = [
+			6 => ['50958', '51003', '51015'],
+			3 => ['70127'],
+			2 => ['56034', '56014', '55985', '55916'],
+			4 => ['48461', '48603', '48629'],
+			5 => ['8898452291772', '8898451210428'],
+		];
+		$product_ids = explode(",",trim($product_ids,","));
+		if(isset($map[$shopid])){
+			$tmp_bj_flag = 0;
+			foreach($product_ids as $item){
+				if(in_array($item,$map[$shopid])){
+					$tmp_bj_flag = 1;
+				}
+			}
+			return $tmp_bj_flag;
+		}else{
+			return 0;
+		}
+
+	}
+
 	public function tranExtraPrice($issku,$org_qty,$org_price,$org_row_total,$org_tax_amount,$org_discount_amount,$product_ids_tmp){
 		$sku = explode(',',$issku);
 		$tmp_qty = explode(';',$org_qty);