From 223b7fc966800143d902e8143ebc4e556fa634f9 Mon Sep 17 00:00:00 2001 From: chenbo <709206448@qq.com> Date: Wed, 13 Sep 2023 19:40:48 +0800 Subject: [PATCH] =?UTF-8?q?add:=E5=95=86=E6=88=B7=E5=90=88=E5=90=8C?= =?UTF-8?q?=E5=8F=91=E8=B5=B7=E7=AD=BE=E7=BA=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/adminapi/logic/ShopContractLogic.php | 31 +++++++++--------------- 1 file changed, 11 insertions(+), 20 deletions(-) diff --git a/app/adminapi/logic/ShopContractLogic.php b/app/adminapi/logic/ShopContractLogic.php index 2973fa4a9..0a0ea57ab 100644 --- a/app/adminapi/logic/ShopContractLogic.php +++ b/app/adminapi/logic/ShopContractLogic.php @@ -202,27 +202,17 @@ class ShopContractLogic extends BaseLogic "type"=>"party_a" ], ]; - if($result['type']==1){ - $data[]= [ - "applyNo" => $result['contract_no'], //TODO * - "fullName" => $result['party_b_info']['company_name'], //TODO * - "identityCard" => $result['party_b_info']['organization_code'], //TODO * - "identityType" => 12, //TODO * - "master_phone" => $result['party_b_info']['master_phone'], - "type"=>"party_b" - ]; - }else{ - $data[]= [ - "applyNo" => $result['contract_no'], //TODO * - "fullName" => $result['party_b_info']['nickname'], //TODO * - "identityCard" => $result['party_b_info']['id_card'], //TODO * - "identityType" => 1, //TODO * - "master_phone" => $result['party_b_info']['mobile'], - "type"=>"party_b" + $data[]= [ + "applyNo" => $result['contract_no'], //TODO * + "fullName" => $result['party_b_info']['company_name'], //TODO * + "identityCard" => $result['party_b_info']['organization_code'], //TODO * + "identityType" => 12, //TODO * + "master_phone" => $result['party_b_info']['master_phone'], + "type"=>"party_b" + + ]; - ]; - } $find = Db::name('shop_contract')->where('id', $params['id']) ->withAttr('contract_type_name', function ($value, $data) { return Db::name('dict_data')->where('id', $data['contract_type'])->value('name'); @@ -242,10 +232,11 @@ class ShopContractLogic extends BaseLogic 'mobile' => $v['master_phone'], 'name' => $v['fullName'], 'type' => '《商户入驻合同》', - 'code' => 'api/Hetong/url?id=' . $find['id'].'&type='.$v['type'].'&sign_type=shop_contract', + 'code' => 'api/Hetong/url?id=' . $find['id'].'&type='.$v['type'].'&t=1', 'scene' => 'WQ' ]; $result = SmsLogic::contractUrl($sms); + if ($result != true) { return self::setError(SmsLogic::getError()); }