浏览代码

Merge branch 'system-zyj' of uskycloud/usky-cloud into master

James 1 年之前
父节点
当前提交
476403d1de

+ 5 - 2
base-modules/service-system/service-system-biz/src/main/java/com/usky/system/controller/web/SendSmsController.java

@@ -10,6 +10,7 @@ import com.aliyuncs.profile.DefaultProfile;
 import com.google.gson.Gson;
 import com.usky.common.core.bean.ApiResult;
 import com.usky.common.core.exception.BusinessException;
+import com.usky.common.core.util.StringUtils;
 import com.usky.common.redis.core.RedisHelper;
 import com.usky.system.domain.SysMobileTenantConfig;
 import com.usky.system.domain.SysUser;
@@ -47,8 +48,10 @@ public class SendSmsController {
     private ISysUserService sysUserService;
 
     @GetMapping("/noteSending")
-    public ApiResult<Void> noteSending(@RequestParam Integer tenantId,@RequestParam String phone) {
-        sysUserService.getAppUserInfo(null, tenantId, phone);
+    public ApiResult<Void> noteSending(@RequestParam(value = "tenantId" ,required = false) Integer tenantId,@RequestParam(value = "phone") String phone) {
+        if((tenantId != null) && !StringUtils.isBlank(phone)){
+            sysUserService.getAppUserInfo(null, tenantId, phone);
+        }
 
         DefaultProfile profile = DefaultProfile.getProfile("cn-beijing", "LTAI9WERPIFIlHDg", "p7SQ0rYpraebcdoJ0l3tOtYmmgrR4q");
         String code = String.valueOf(new Random().nextInt(1000000));