lvhao преди 6 дни
родител
ревизия
5d86951032
променени са 1 файла, в които са добавени 3 реда и са изтрити 3 реда
  1. 3 3
      core/CoreApp/models/Model_ck.php

+ 3 - 3
core/CoreApp/models/Model_ck.php

@@ -141,14 +141,14 @@ class Model_ck extends Lin_Model
 				$wh = $this->whlabel->find_count("state = '0' and number = '$num[0]' and warehouse = '".$warehouse['id']."' and (zd = '$number' or zd = '') and (shop IS NULL or shop = '')");//通用
 				$shopwh = $this->whlabel->find_count("state = '0' and number = '$num[0]' and warehouse = '".$warehouse['id']."' and (zd = '$number' or zd = '') and shop like '%,".$shop.",%'");//专属
 				$x++;
-				
+				$this->logic_ding->sendToDing("库存验证数据2【".$number."】".json_encode($num)."库存数量:".($wh+$shopwh)."仓库的占单模式".$warehouse['zdms']."$".json_encode($save));
 				if($wh+$shopwh < $num[1] || (isset($num[2]) && $num[2] == "DNOTO" && $warehouse['zdms'] == 2))
 				{
-					//$this->logic_ding->sendToDing("库存验证数据【".$number."】".json_encode($num)."库存数量:".($wh+$shopwh)."仓库的占单模式".$warehouse['zdms']);
+					$this->logic_ding->sendToDing("库存验证数据【".$number."】".json_encode($num)."库存数量:".($wh+$shopwh)."仓库的占单模式".$warehouse['zdms']);
 					$save[] = $x-1;continue;//提前先加X不然出错,所以要减1
 				}
 			}
-			//$this->logic_ding->sendToDing("2库存验证数据【".$number."】".json_encode($num)."库存数量:".($wh+$shopwh)."仓库的占单模式".$warehouse['zdms']."$".json_encode($save));
+			
 			if(isset($save[0]) && $warehouse['zdms'] == 2)
             {
 				return array('t'=>1,'m'=>json_encode(array('t'=>2,'msg'=>"红色商品名库存不够扣减或不允许占单",'error'=>$save,'hq'=>"state = '0' and number = '$num[0]' and warehouse = '".$warehouse['id']."' and (zd = '$number' or zd = '') and (shop IS NULL or shop = '')",'success'=>false)));exit;