|
@@ -230,10 +230,6 @@ class Goodup extends Base
|
|
|
if($is_exclusive===''){
|
|
|
return error_show(1004,"参数is_exclusive不能为空");
|
|
|
}
|
|
|
-// $customized = isset($this->post['customized'])&&$this->post['customized']!==""? intval($this->post['customized']):"";
|
|
|
-// if($customized===''){
|
|
|
-// return error_show(1004,"参数customized不能为空");
|
|
|
-// }
|
|
|
$tax = isset($this->post['tax'])&&$this->post['tax']!==""? intval($this->post['tax']):"";
|
|
|
if($tax===''){
|
|
|
return error_show(1004,"参数tax不能为空");
|
|
@@ -328,6 +324,11 @@ class Goodup extends Base
|
|
|
if($is_stock===""){
|
|
|
return error_show(1004,"参数is_stock不能为空");
|
|
|
}
|
|
|
+ // $stock_moq=0 ;//库存品备库起订量; 如果是0 表示无限制;
|
|
|
+ $stock_moq = isset($this->post['stock_moq'])&&$this->post['stock_moq']!==""? intval($this->post['stock_moq']):"0";
|
|
|
+ if($is_stock==1 && $stock_moq ==0){
|
|
|
+ return error_show(1004,"库存品备库起订量不能为零");
|
|
|
+ }
|
|
|
$is_diff = isset($this->post['is_diff'])&&$this->post['is_diff']!==""? intval($this->post['is_diff']):"0";
|
|
|
|
|
|
$good_img = isset($this->post['good_img'])&&$this->post['good_img']!=""? trim($this->post['good_img']):"";
|
|
@@ -438,6 +439,7 @@ class Goodup extends Base
|
|
|
"field_change"=>'',
|
|
|
"is_step" => count($good_ladder) > 1 ? 1 : 0,//如果阶梯价个数大于1,说明启用阶梯价
|
|
|
"is_online"=>0,
|
|
|
+ "stock_moq"=>$stock_moq,
|
|
|
"status"=>0,
|
|
|
"createrid"=>$createrid,
|
|
|
"creater"=>$creater,
|
|
@@ -681,7 +683,11 @@ class Goodup extends Base
|
|
|
$config = isset($this->post['config'])&&$this->post['config']!==""? trim($this->post['config']):"";
|
|
|
$other_config = isset($this->post['other_config'])&&$this->post['other_config']!==""? trim($this->post['other_config']):"";
|
|
|
$is_diff = isset($this->post['is_diff'])&&$this->post['is_diff']!==""? intval($this->post['is_diff']):"0";
|
|
|
- $is_stock = isset($this->post['is_stock'])&&$this->post['is_stock']!==""? intval($this->post['is_stock']):"";
|
|
|
+ $is_stock = isset($this->post['is_stock'])&&$this->post['is_stock']!==""? intval($this->post['is_stock']):"0";
|
|
|
+ $stock_moq = isset($this->post['stock_moq'])&&$this->post['stock_moq']!==""? intval($this->post['stock_moq']):"0";
|
|
|
+ if($is_stock==1 && $stock_moq ==0){
|
|
|
+ return error_show(1004,"库存品备库起订量不能为零");
|
|
|
+ }
|
|
|
$good_img = isset($this->post['good_img'])&&$this->post['good_img']!=""? trim($this->post['good_img']):"";
|
|
|
if($good_img===""){
|
|
|
return error_show(1004,"参数good_img不能为空");
|
|
@@ -734,6 +740,7 @@ class Goodup extends Base
|
|
|
"config"=>$config,
|
|
|
"other_config"=>$other_config,
|
|
|
"good_img"=>$good_img,
|
|
|
+ "stock_moq"=>$stock_moq,
|
|
|
"good_thumb_img"=>$good_thumb_img,
|
|
|
"good_info_img"=>$good_info_img,
|
|
|
"status"=>$count>0?2:1,
|
|
@@ -820,6 +827,10 @@ class Goodup extends Base
|
|
|
if($market_price===""){
|
|
|
return error_show(1004,"参数market_price不能为空");
|
|
|
}
|
|
|
+ $stock_moq = isset($this->post['stock_moq'])&&$this->post['stock_moq']!==""? intval($this->post['stock_moq']):"0";
|
|
|
+ if($datas['is_stock']==1 && $stock_moq ==0){
|
|
|
+ return error_show(1004,"库存品备库起订量不能为零");
|
|
|
+ }
|
|
|
$nake_price = isset($this->post['nake_price'])&&$this->post['nake_price']!==""? floatval($this->post['nake_price']):"";
|
|
|
// $is_step = isset($this->post['is_step'])&&$this->post['is_step']!==""? intval($this->post['is_step']):"";
|
|
|
// if($is_step===""){
|
|
@@ -2060,6 +2071,10 @@ class Goodup extends Base
|
|
|
$other_config = isset($this->post['other_config'])&&$this->post['other_config']!==""? trim($this->post['other_config']):"";
|
|
|
$is_diff = isset($this->post['is_diff'])&&$this->post['is_diff']!==""? intval($this->post['is_diff']):"0";
|
|
|
$is_stock = isset($this->post['is_stock'])&&$this->post['is_stock']!==""? intval($this->post['is_stock']):"0";
|
|
|
+ $stock_moq = isset($this->post['stock_moq'])&&$this->post['stock_moq']!==""? intval($this->post['stock_moq']):"0";
|
|
|
+ if($is_stock==1 && $stock_moq ==0){
|
|
|
+ return error_show(1004,"库存品备库起订量不能为零");
|
|
|
+ }
|
|
|
// $is_step = isset($this->post['is_step'])&&$this->post['is_step']!==""? intval($this->post['is_step']):"";
|
|
|
// if($is_step===""){
|
|
|
// return error_show(1004,"参数is_step不能为空");
|
|
@@ -2123,6 +2138,7 @@ class Goodup extends Base
|
|
|
"nake_price"=>$nake_price,
|
|
|
"cgd_gold_price"=>$cgd_gold_price,
|
|
|
"is_step" => count($good_ladder) > 1 ? 1 : 0,
|
|
|
+ "stock_moq"=>$stock_moq,
|
|
|
"status"=>"0",
|
|
|
"updatetime"=>date("Y-m-d H:i:s")
|
|
|
];
|