lvhao il y a 17 heures
Parent
commit
aab5753639

+ 3 - 2
core/CoreApp/controllers/Fullorder.php

@@ -976,7 +976,7 @@ class Fullorder extends Start_Controller {
 			// 	echo json_encode(array('msg'=>'单条申报价为2为小数!','success'=>false));exit;
 			// }
 			$id = $this->input->post('id',true);
-			$data = $this->fullorder->read($id);
+			$ud = $data = $this->fullorder->read($id);
 			$post['type'] = $this->input->post('warehouse',true);
 			$post['country'] = $this->input->post('country',true);
 			$currency = $this->country->read($post['country']);
@@ -1093,7 +1093,7 @@ class Fullorder extends Start_Controller {
 					echo json_encode(array('msg'=>'美国电话号码应为10/11位!','success'=>false));exit;
 				}
 			}
-			
+			$post['library'] = $ud['library'];
 			//减少代码复用吧
 			$lo_ret = $this->logic_order->checkEditExpress($post);
 			if($lo_ret['code'] != 1){
@@ -2007,6 +2007,7 @@ class Fullorder extends Start_Controller {
 			$post['js'] = $ud['js'];
 			$post['sbpm'] = $ud['sbpm'];
 			$post['shouldmoney'] = $ud['shouldmoney'];
+			$post['library'] = $ud['library'];
 			//减少代码复用吧
 			$lo_ret = $this->logic_order->checkEditExpress($post);
 			if($lo_ret['code'] != 1){

+ 21 - 8
core/CoreApp/models/Model_logic_order.php

@@ -299,12 +299,18 @@ class Model_logic_order extends Lin_Model {
         }
 
         //惠程-联邦-9610 只允许加拿大使用
+
         if($post['express'] == 50){
             if($post['country'] != 35){
-                return [
-                    'code'=>-1,
-                    "msg"=>'该快递仅支持“加拿大”发货!'
-                ];
+                if(isset($post['library']) && $post['library'] == 2){
+
+                }else{
+                    return [
+                        'code'=>-1,
+                        "msg"=>'该快递仅支持“加拿大”发货!'
+                    ];
+                }
+               
             }
         }
 
@@ -567,12 +573,19 @@ class Model_logic_order extends Lin_Model {
         //惠程-联邦-9610 只允许加拿大使用
         if($post['express'] == 50){
             if($post['country'] != 35){
-                return [
-                    'code'=>-1,
-                    "msg"=>'该快递仅支持“加拿大”发货!'
-                ];
+                if(isset($post['library']) && $post['library'] == 2){
+                    
+                }else{
+                    return [
+                        'code'=>-1,
+                        "msg"=>'该快递仅支持“加拿大”发货!'
+                    ];
+                }
+               
             }
         }
+
+
         //惠程英国(ges)
         if($post['express'] == 88){
             if(!empty($post['address2'])){