|
|
|
@ -7,7 +7,7 @@
|
|
|
|
|
// | Author: 麦当苗儿 <zuojiazi@vip.qq.com> <http://www.zjzit.cn>
|
|
|
|
|
// +----------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
|
namespace Sdk\Model;
|
|
|
|
|
namespace Common\Model;
|
|
|
|
|
|
|
|
|
|
use Think\Model;
|
|
|
|
|
|
|
|
|
@ -37,10 +37,10 @@ class SmsLogModel extends Model
|
|
|
|
|
'30974' => '{1}您的验证码为{2},10分钟内有效,为保证账户安全,请勿向他人泄露验证信息。',
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
public function sendCode($strPhone, $type = '')
|
|
|
|
|
public function sendCode($strPhone, $code = '')
|
|
|
|
|
{
|
|
|
|
|
$params[0] = self::$sms_sign['001'];
|
|
|
|
|
$params[1] = rand(100000, 999999);
|
|
|
|
|
$params[1] = $code;
|
|
|
|
|
$str = self::getContent(self::$msgContent['30974'], $params);
|
|
|
|
|
$msg = $this->sms($str, $strPhone, $params[1]);
|
|
|
|
|
return $msg;
|
|
|
|
@ -70,8 +70,8 @@ class SmsLogModel extends Model
|
|
|
|
|
public function sms($content, $phone, $code)
|
|
|
|
|
{
|
|
|
|
|
$data = [
|
|
|
|
|
'apName' => 'wmtxhy',
|
|
|
|
|
'apPassword' => 'wmtxhy158',
|
|
|
|
|
'apName' => C('zhongwang.smtp_account'),
|
|
|
|
|
'apPassword' => C('zhongwang.smtp_password'),
|
|
|
|
|
'calledNumber' => $phone,
|
|
|
|
|
'content' => $content,
|
|
|
|
|
];
|
|
|
|
|