刘远航 преди 4 години
родител
ревизия
7e4db71a9f
променени са 2 файла, в които са добавени 7 реда и са изтрити 7 реда
  1. 3 3
      app/Helpers/functions.php
  2. 4 4
      app/Http/Controllers/Api/V2/PatientController.php

+ 3 - 3
app/Helpers/functions.php

xqd
@@ -622,19 +622,19 @@ if (!function_exists('send_wechat_message_to_docter')) {
 if (!function_exists('send_wechatSubscription_message')) {
     function send_wechatSubscription_message($type, $arr,$message='docter_wechat_small_program')
     {
-        trace(['模板消息进入数据类型' =>$type , '请求参数' => $arr ?? '', '模板标识' => $message ?? ''], 'lyh_info');
+        order_trace(['公共方法-模板消息进入数据类型' =>$type , '请求参数' => $arr ?? '', '模板标识' => $message ?? ''], 'lyh_info');
 
         try {
             $app = Factory::miniProgram(config('config.'.$message));
             $data = config('config.wechatSubscription_template')[$type];
-            trace(['模板消息进入数据类型' =>$type , '请求参数' => $arr ?? '', '模板' => $data ?? ''], 'lyh_info');
+            order_trace(['公共方法-模板消息进入数据类型' =>$type , '请求参数' => $arr ?? '', '模板' => $data ?? ''], 'lyh_info');
 
             $json = json_encode($data, JSON_UNESCAPED_UNICODE);
             $json = vsprintf($json, $arr);
             $data = json_decode($json, true);
             $result = $app->uniform_message->send($data);
         } catch (Exception $e) {
-            trace(['发送微信模板消息失败' => $e->getMessage(), '请求参数' => $data ?? '', '返回数据' => $result ?? ''], 'lyh_error');
+            order_trace(['公共方法发送微信模板消息失败' => $e->getMessage(), '请求参数' => $data ?? '', '返回数据' => $result ?? ''], 'error');
         }
         return $result ?? false;
     }

+ 4 - 4
app/Http/Controllers/Api/V2/PatientController.php

xqd xqd xqd xqd
@@ -256,7 +256,7 @@ class PatientController extends AuthController
 
         $msg = $this->ReceivingReminderOK($find['id']);
 
-        trace(['完成订单日志', '请求参数' => $find['id'] ?? '', '返回数据' => $msg ?? ''], 'info');
+        order_trace(['完成订单日志', '请求参数' => $find['id'] ?? '', '返回数据' => $msg ?? ''], 'info');
 
         $axbwhere['docter_id'] = $user['id'];
         $axbwhere['user_id'] = $find['user_id'];
@@ -352,7 +352,7 @@ class PatientController extends AuthController
             DB::rollBack();
             return out('', 500, $e->getMessage());
         }
-        trace(['门诊完成订单日志', '请求参数' => $find['id'] ?? '', '返回数据' => $msg ?? ''], 'info');
+        order_trace(['门诊完成订单日志', '请求参数' => $find['id'] ?? '', '返回数据' => $msg ?? ''], 'info');
 
         $this->ReceivingReminderOK($find['id']);
 
@@ -409,7 +409,7 @@ class PatientController extends AuthController
             DB::commit();
 
             $msg = $this->ReceivingReminder($req['order_id']);
-            trace(['接单日志', '请求参数' => $req['order_id'] ?? '', '返回数据' => $msg ?? ''], 'info');
+            order_trace(['接单日志', '请求参数' => $req['order_id'] ?? '', '返回数据' => $msg ?? ''], 'info');
             return out();
         } catch (\Exception $e) {
 
@@ -918,7 +918,7 @@ class PatientController extends AuthController
     public function ReplyReminder($docter_id,$user_id){
 
         $list = Docter::with(['DocterOrganization','organization'])->where(['id'=>$docter_id,'is_open'=>2])->first();
-        trace(['消息回复', '请求参数' => $docter_id.'-'.$user_id ?? '', 'list数据' => $list ?? ''], 'info');
+        order_trace(['消息回复', '请求参数' => $docter_id.'-'.$user_id ?? '', 'list数据' => $list ?? ''], 'info');
 
         $user = User::where('id',$user_id)->first();
         if ($list){