<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ namespace Module\Vendor\Sms; use ModStart\Core\Exception\BizException; use ModStart\Core\Job\BaseJob; use Module\Vendor\Log\Logger; use Module\Vendor\Provider\SmsSender\SmsSenderProvider; class SmsSendJob extends BaseJob { public $phone; public $template; public $templateData; public static function create($xnZh3, $eMuYk, $EIJx6) { goto RPZ32; sK4F9: $jm4we->template = $eMuYk; goto jLrUh; RPZ32: $jm4we = new static(); goto E4z6Q; eeMlt: app('Illuminate\\Contracts\\Bus\\Dispatcher')->dispatch($jm4we); goto vCSIr; E4z6Q: $jm4we->phone = $xnZh3; goto sK4F9; jLrUh: $jm4we->templateData = $EIJx6; goto eeMlt; vCSIr: } public function handle() { goto pkISA; TMLIZ: Logger::info('Sms', 'Start', $Da747); goto JUKz7; Dk0Ug: try { goto LM81x; zY8hO: $gMg9x = SmsSenderProvider::get($pXrNS)->send($this->phone, $this->template, $this->templateData); goto yQZw9; LM81x: BizException::throwsIfEmpty('短信发送未设置', $pXrNS); goto zY8hO; yQZw9: BizException::throwsIfResponseError($gMg9x); goto G256S; G256S: Logger::info('Sms', 'End', $this->phone . ' - ' . json_encode($gMg9x, JSON_UNESCAPED_UNICODE)); goto E136P; E136P: } catch (BizException $re7gC) { Logger::error('Sms', 'Error', $this->phone . ' - ' . $re7gC->getMessage()); } goto J6Ux9; JUKz7: $pXrNS = app()->config->get('SmsSenderProvider'); goto Dk0Ug; pkISA: $Da747 = $this->phone . ' - ' . $this->template . ' - ' . json_encode($this->templateData, JSON_UNESCAPED_UNICODE); goto TMLIZ; J6Ux9: } }