From a792122da03a6b0d53eb3b5806fea6868101569e Mon Sep 17 00:00:00 2001 From: hawind Date: Sun, 9 May 2021 22:41:25 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=88=97=E8=A1=A8=E8=A7=86?= =?UTF-8?q?=E5=9B=BE=E7=BC=96=E7=A0=81=E6=8F=90=E7=A4=BA=E4=B8=8D=E6=AD=A3?= =?UTF-8?q?=E7=A1=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/Gdoo/Customer/Hooks/CustomerApplyHook.php | 7 ++++--- app/Gdoo/Customer/Hooks/CustomerHook.php | 6 ++++-- app/Gdoo/Model/views/template/create2.blade.php | 2 +- 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/app/Gdoo/Customer/Hooks/CustomerApplyHook.php b/app/Gdoo/Customer/Hooks/CustomerApplyHook.php index 98134ba3..1dbaf188 100644 --- a/app/Gdoo/Customer/Hooks/CustomerApplyHook.php +++ b/app/Gdoo/Customer/Hooks/CustomerApplyHook.php @@ -26,7 +26,8 @@ class CustomerApplyHook return $params; } - public function onBeforeAudit($params) { + public function onBeforeAudit($params) + { $id = $params['id']; $apply = DB::table('customer_apply') @@ -98,7 +99,7 @@ class CustomerApplyHook 'status' => 1, ]); - // 客户档案同步外部接口 + // 客户档案同步接口 $department = DB::table('department')->where('id', $customer['department_id'])->first(); $class = DB::table('customer_class')->where('id', $customer['class_id'])->first(); $customer['class_code'] = $class['code']; @@ -106,7 +107,7 @@ class CustomerApplyHook $ret = plugin_sync_api('postCustomer', $customer); if ($ret['error_code'] > 0) { abort_error($ret['msg']); - } + } return $params; } diff --git a/app/Gdoo/Customer/Hooks/CustomerHook.php b/app/Gdoo/Customer/Hooks/CustomerHook.php index 046bc770..8e9c7571 100644 --- a/app/Gdoo/Customer/Hooks/CustomerHook.php +++ b/app/Gdoo/Customer/Hooks/CustomerHook.php @@ -38,8 +38,10 @@ class CustomerHook return $params; } - public function onAfterStore($params) { + public function onAfterStore($params) + { $master = $params['master']; + // 客户开票单位为空 $count = CustomerTax::where('customer_id', $master['id'])->count(); if ($count == 0) { @@ -62,7 +64,7 @@ class CustomerHook $ret = plugin_sync_api('postCustomer', $master); if ($ret['error_code'] > 0) { abort_error($ret['msg']); - } + } return $params; } diff --git a/app/Gdoo/Model/views/template/create2.blade.php b/app/Gdoo/Model/views/template/create2.blade.php index bcf9442c..f1880791 100644 --- a/app/Gdoo/Model/views/template/create2.blade.php +++ b/app/Gdoo/Model/views/template/create2.blade.php @@ -75,7 +75,7 @@