@yoooloo42/beat 1.0.12 → 1.0.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/libs/Ali-SMS.js +6 -6
- package/src/libs/Ali-SMS.js.txt +0 -2
package/package.json
CHANGED
package/src/libs/Ali-SMS.js
CHANGED
|
@@ -13,15 +13,15 @@ const Core = require('@alicloud/pop-core')
|
|
|
13
13
|
* @param {object} clientBox 客户端参数
|
|
14
14
|
* @returns {Promise<object>} 返回阿里云 API 的响应对象
|
|
15
15
|
*/
|
|
16
|
-
const
|
|
16
|
+
const clientBox = {
|
|
17
17
|
action: 'SendSms',
|
|
18
18
|
apiVersion: '2017-05-25',
|
|
19
19
|
regionId: 'cn-hangzhou', // 短信服务 API 的区域,通常使用杭州(cn-hangzhou)
|
|
20
20
|
endpoint: 'https://dysmsapi.aliyuncs.com', // 短信服务的 Endpoint
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
21
|
+
// accessKeyId: ' ',
|
|
22
|
+
// accessKeySecret: ' ',
|
|
23
|
+
// signName: ' ',
|
|
24
|
+
// templateCode: ' '
|
|
25
25
|
}
|
|
26
26
|
|
|
27
27
|
function sms(cellphone, shortMessageCode, clientBox) {
|
|
@@ -69,7 +69,7 @@ function sms(cellphone, shortMessageCode, clientBox) {
|
|
|
69
69
|
}
|
|
70
70
|
|
|
71
71
|
// 发送验证码
|
|
72
|
-
function sendVercode(cellphone, codeLength = 6){
|
|
72
|
+
function sendVercode(cellphone, codeLength = 6, clientBox){
|
|
73
73
|
return new Promise(function (resolve, reject) {
|
|
74
74
|
const vercode = random.vercode6N(codeLength);
|
|
75
75
|
sms(cellphone, vercode).then(result=>{
|
package/src/libs/Ali-SMS.js.txt
DELETED