mirror of
https://gitee.com/zoujingli/ThinkAdmin.git
synced 2025-04-06 03:58:04 +08:00
[更新]修正阿里云短信服务
This commit is contained in:
parent
bdb56be6fe
commit
a63bbe225e
@ -32,7 +32,6 @@ class AlismsService
|
|||||||
*/
|
*/
|
||||||
private static $sdkVersion = [
|
private static $sdkVersion = [
|
||||||
"RegionId" => "cn-hangzhou",
|
"RegionId" => "cn-hangzhou",
|
||||||
"Action" => "SendBatchSms",
|
|
||||||
"Version" => "2017-05-25",
|
"Version" => "2017-05-25",
|
||||||
];
|
];
|
||||||
|
|
||||||
@ -52,6 +51,7 @@ class AlismsService
|
|||||||
$params["PageSize"] = $PageSize;
|
$params["PageSize"] = $PageSize;
|
||||||
$params["CurrentPage"] = $CurrentPage;
|
$params["CurrentPage"] = $CurrentPage;
|
||||||
$params["PhoneNumber"] = $PhoneNumber;
|
$params["PhoneNumber"] = $PhoneNumber;
|
||||||
|
$params['Action'] = 'QuerySendDetails';
|
||||||
is_null($BizId) || $params["BizId"] = $BizId;
|
is_null($BizId) || $params["BizId"] = $BizId;
|
||||||
return self::request("dysmsapi.aliyuncs.com", array_merge($params, self::$sdkVersion), true);
|
return self::request("dysmsapi.aliyuncs.com", array_merge($params, self::$sdkVersion), true);
|
||||||
}
|
}
|
||||||
@ -68,6 +68,7 @@ class AlismsService
|
|||||||
public static function batchSend(array $PhoneNumbers, $TemplateCode, array $SignNames, array $TemplateParams, $SmsUpExtendCodes = [])
|
public static function batchSend(array $PhoneNumbers, $TemplateCode, array $SignNames, array $TemplateParams, $SmsUpExtendCodes = [])
|
||||||
{
|
{
|
||||||
$params = [];
|
$params = [];
|
||||||
|
$params["Action"] = 'SendBatchSms';
|
||||||
$params["TemplateCode"] = $TemplateCode;
|
$params["TemplateCode"] = $TemplateCode;
|
||||||
!empty($SmsUpExtendCodes) && $params["SmsUpExtendCodeJson"] = json_encode($SmsUpExtendCodes);
|
!empty($SmsUpExtendCodes) && $params["SmsUpExtendCodeJson"] = json_encode($SmsUpExtendCodes);
|
||||||
$params["TemplateParamJson"] = json_encode($TemplateParams, JSON_UNESCAPED_UNICODE);
|
$params["TemplateParamJson"] = json_encode($TemplateParams, JSON_UNESCAPED_UNICODE);
|
||||||
@ -92,6 +93,7 @@ class AlismsService
|
|||||||
public static function send($PhoneNumbers, $TemplateCode, $SignName, array $TemplateParam, $OutId = null, $SmsUpExtendCode = null)
|
public static function send($PhoneNumbers, $TemplateCode, $SignName, array $TemplateParam, $OutId = null, $SmsUpExtendCode = null)
|
||||||
{
|
{
|
||||||
$params = [];
|
$params = [];
|
||||||
|
$params['Action'] = 'SendSms';
|
||||||
$params["SignName"] = $SignName;
|
$params["SignName"] = $SignName;
|
||||||
$params["TemplateCode"] = $TemplateCode;
|
$params["TemplateCode"] = $TemplateCode;
|
||||||
$params["PhoneNumbers"] = $PhoneNumbers;
|
$params["PhoneNumbers"] = $PhoneNumbers;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user