소스 검색

完善发送短信接口

15954078560 2 년 전
부모
커밋
36817e30db
2개의 변경된 파일2개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 0
      addons/qcloudsms/config.php
  2. 1 1
      application/api/controller/Sms.php

+ 1 - 0
addons/qcloudsms/config.php

@@ -102,6 +102,7 @@ return [
             'changepwd' => '1378407',
             'mobilelogin' => '1378407',
             'changemobile' => '1378407',
+            'changeyuanmobile' => '1378407',
         ],
         'rule' => 'required',
         'msg' => '',

+ 1 - 1
application/api/controller/Sms.php

@@ -47,7 +47,7 @@ class Sms extends Api
             } elseif (in_array($event, ['changemobile']) && $userinfo) {
                 //被占用
                 $this->error(__('已被占用'));
-            } elseif (in_array($event, ['changepwd', 'resetpwd', 'mobilelogin']) && !$userinfo) {
+            } elseif (in_array($event, ['changepwd', 'resetpwd', 'mobilelogin', 'changeyuanmobile']) && !$userinfo) {
                 //未注册
                 $this->error(__('未注册'));
             }