Commit 09f831f8 by 赵增煜

注销开方审方短信发送

parent fdca59f4
...@@ -334,22 +334,22 @@ public function create(Request $request) ...@@ -334,22 +334,22 @@ public function create(Request $request)
// $doctorLog->log_info = $randomDoctor->name.'在'.$prescription_at.'为'.$patient->name.'('.$patient->mobile.')开具处方单(处方单编号:'.$prescription_number.')'; // $doctorLog->log_info = $randomDoctor->name.'在'.$prescription_at.'为'.$patient->name.'('.$patient->mobile.')开具处方单(处方单编号:'.$prescription_number.')';
// $doctorLog->save(); // $doctorLog->save();
} elseif ($randomDoctor->is_auto == 0) { } elseif ($randomDoctor->is_auto == 0) {
// 手动开方发送医师通知短信 // 手动开方发送医师通知短信 1219发送短信注销
if (env('SMS_CHANNEL') == 'chengliye') { // if (env('SMS_CHANNEL') == 'chengliye') {
$templateName = 'doctor_notification'; // $templateName = 'doctor_notification';
$templateData = []; // $templateData = [];
$smsService = new SmsService(); // $smsService = new SmsService();
$response = $smsService->sendSms($randomDoctor->mobile, $templateName, $templateData); // $response = $smsService->sendSms($randomDoctor->mobile, $templateName, $templateData);
Log::info(json_encode($response)); // Log::info(json_encode($response));
} elseif (env('SMS_CHANNEL') == 'qcloud') { // 腾讯短信 // } elseif (env('SMS_CHANNEL') == 'qcloud') { // 腾讯短信
$easySms = new EasySms(config('easysms')); // $easySms = new EasySms(config('easysms'));
$response = $easySms->send($randomDoctor->mobile, [ // $response = $easySms->send($randomDoctor->mobile, [
'content' => '您有一条处方需要开方。', // 'content' => '您有一条处方需要开方。',
'template' => '2316306', // 'template' => '2316306',
'data' => [], // 'data' => [],
]); // ]);
Log::info(json_encode($response)); // Log::info(json_encode($response));
} // }
} }
// 药店自动审方(必须处方单待审方) // 药店自动审方(必须处方单待审方)
...@@ -363,23 +363,23 @@ public function create(Request $request) ...@@ -363,23 +363,23 @@ public function create(Request $request)
// $currentTime = $review_at; // $currentTime = $review_at;
// $pharmacistLog->log_info = $pharmacist->name.'在'.$review_at.'为'.$patient->name.'('.$patient->mobile.')审方(处方单编号:'.$prescription_number.')'; // $pharmacistLog->log_info = $pharmacist->name.'在'.$review_at.'为'.$patient->name.'('.$patient->mobile.')审方(处方单编号:'.$prescription_number.')';
// $pharmacistLog->save(); // $pharmacistLog->save();
} elseif ($pharmacy->is_auto == 0) { } elseif ($pharmacy->is_auto == 0) {
// 手动审方发送药店通知短信 // 手动审方发送药店通知短信 1219发送短信注销
if (env('SMS_CHANNEL') == 'chengliye') { // if (env('SMS_CHANNEL') == 'chengliye') {
$templateName = 'pharmacist_notification'; // $templateName = 'pharmacist_notification';
$templateData = []; // $templateData = [];
$smsService = new SmsService(); // $smsService = new SmsService();
$response = $smsService->sendSms($pharmacy->mobile, $templateName, $templateData); // $response = $smsService->sendSms($pharmacy->mobile, $templateName, $templateData);
Log::info(json_encode($response)); // Log::info(json_encode($response));
} elseif (env('SMS_CHANNEL') == 'qcloud') { // 腾讯短信 // } elseif (env('SMS_CHANNEL') == 'qcloud') { // 腾讯短信
$easySms = new EasySms(config('easysms')); // $easySms = new EasySms(config('easysms'));
$response = $easySms->send($pharmacy->mobile, [ // $response = $easySms->send($pharmacy->mobile, [
'content' => '您有一条处方需要审方。', // 'content' => '您有一条处方需要审方。',
'template' => '2316307', // 'template' => '2316307',
'data' => [], // 'data' => [],
]); // ]);
Log::info(json_encode($response)); // Log::info(json_encode($response));
} // }
} }
return $this->success($prescription_number); return $this->success($prescription_number);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment