diff --git a/app/admin/controller/BirdController.php b/app/admin/controller/BirdController.php index 574e761..727e1ef 100644 --- a/app/admin/controller/BirdController.php +++ b/app/admin/controller/BirdController.php @@ -36,8 +36,13 @@ class BirdController extends AdminBaseController * @throws \think\db\exception\ModelNotFoundException * @throws \think\exception\DbException */ - public function createOrder($indent_id = null) + public function createOrder() { + if(empty($_POST['indent_id'])){ + $indent_id = null; + }else{ + $indent_id = $_POST['indent_id']; + } if(empty($indent_id)){ return "缺少必要参数"; } diff --git a/app/config.php b/app/config.php index 9e3f7c2..0d3d043 100644 --- a/app/config.php +++ b/app/config.php @@ -236,12 +236,12 @@ $configs = [ //快递鸟参数配置 'bird'=>[ //正式 - 'EBusinessID' => '1472267',//电商ID - 'AppKey' => 'cc8314fd-0381-4e37-ad17-239287f1d8d2',//AppKey + /* 'EBusinessID' => '1472267',//电商ID + 'AppKey' => 'cc8314fd-0381-4e37-ad17-239287f1d8d2',//AppKey*/ //测试 -// 'EBusinessID' => 'test1472267', -// 'AppKey' => 'f84c7071-a6c7-48ce-8fe0-11b719d88a1d', - ], + 'EBusinessID' => 'test1472267', + 'AppKey' => 'f84c7071-a6c7-48ce-8fe0-11b719d88a1d', +], //快递鸟预约取件接口寄件人参数 'sender'=>[ 'Name' => "姚鹏程", diff --git a/app/portal/controller/BirdController.php b/app/portal/controller/BirdController.php index 3c81bdd..02c76cf 100644 --- a/app/portal/controller/BirdController.php +++ b/app/portal/controller/BirdController.php @@ -36,13 +36,8 @@ class BirdController extends HomeBaseController * @throws \think\db\exception\ModelNotFoundException * @throws \think\exception\DbException */ - public function createOrder() + public function createOrder($indent_id = null) { - if(empty($_POST['indent_id'])){ - $indent_id = null; - }else{ - $indent_id = $_POST['indent_id']; - } if(empty($indent_id)){ return "缺少必要参数"; } @@ -106,14 +101,13 @@ class BirdController extends HomeBaseController //解析在线下单返回结果 $result = json_decode($jsonResult, true); cache('test',$result); - dump($result);die; if ($result["ResultCode"] == "100") { if(!empty($result['Order']['LogisticCode'])){ $indentModel->updateData(['id'=>$indent_id],['logistic_code'=>$result['Order']['LogisticCode']]); } - return json_encode(['code'=>20000,'msg'=>'SUCCESS','data'=>$result]);//返回快递单号 + return dump(['code'=>20000,'msg'=>'SUCCESS','data'=>$result]);//返回快递单号 } else { - return json_encode(['code'=>40000,'msg'=>$result['Reason']]); + return dump(['code'=>40000,'msg'=>$result['Reason']]); } } diff --git a/public/themes/simpleboot3/public/assets/css/log.css b/public/themes/simpleboot3/public/assets/css/log.css index 0c63729..5493dd4 100755 --- a/public/themes/simpleboot3/public/assets/css/log.css +++ b/public/themes/simpleboot3/public/assets/css/log.css @@ -344,6 +344,7 @@ font-weight: 400; line-height: 0.36rem; color: #333; + padding: 0; }