<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ namespace Module\Vendor\Job; 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($cz6lT, $XPQ0m, $YxsLg) { goto pPZgw; exwHp: $n_tN1->templateData = $YxsLg; goto z6A_Y; z6A_Y: app('Illuminate\\Contracts\\Bus\\Dispatcher')->dispatch($n_tN1); goto ljnDc; OXz2s: $n_tN1->template = $XPQ0m; goto exwHp; pPZgw: $n_tN1 = new static(); goto Nbltw; Nbltw: $n_tN1->phone = $cz6lT; goto OXz2s; ljnDc: } public function handle() { goto siij8; CIgRf: try { goto Kg7zZ; ohfR6: Logger::info('Sms', 'End', $this->phone . ' - ' . json_encode($Ecj99, JSON_UNESCAPED_UNICODE)); goto gLHpb; Kg7zZ: BizException::throwsIfEmpty('短信发送未设置', $O9Vtg); goto ktXvi; Z8sEa: BizException::throwsIfResponseError($Ecj99); goto ohfR6; ktXvi: $Ecj99 = SmsSenderProvider::get($O9Vtg)->send($this->phone, $this->template, $this->templateData); goto Z8sEa; gLHpb: } catch (BizException $fWY9h) { Logger::error('Sms', 'Error', $this->phone . ' - ' . $fWY9h->getMessage()); } goto IdCOW; c5sHS: $O9Vtg = app()->config->get('SmsSenderProvider'); goto CIgRf; xxapP: Logger::info('Sms', 'Start', $x0Ets); goto c5sHS; siij8: $x0Ets = $this->phone . ' - ' . $this->template . ' - ' . json_encode($this->templateData, JSON_UNESCAPED_UNICODE); goto xxapP; IdCOW: } }