소스 검색

getUserInfo

lyhzzz 2 년 전
부모
커밋
f1b9a82cbf

+ 1 - 1
src/main/java/com/fdkankan/ucenter/controller/app/AppUserController.java

@@ -27,7 +27,7 @@ public class AppUserController {
     @PostMapping("/getUserInfo")
     public Result getUserInfo(@RequestBody JSONObject param){
         String phoneNum = param.get("phoneNum") == null ? null : param.getString("phoneNum");
-        Integer cameraType = param.get("cameraType") == null ? null : param.getInteger("cameraType");
+        Integer cameraType = param.get("cameraType") == null ? 4 : param.getInteger("cameraType");
         return Result.success( appUserService.getUserInfo(phoneNum,cameraType));
     }
 

+ 1 - 1
src/main/java/com/fdkankan/ucenter/service/impl/AppUserService.java

@@ -28,7 +28,7 @@ public class AppUserService {
     IUserIncrementService userIncrementService;
 
     public UserVo getUserInfo(String phoneNum, Integer cameraType) {
-        if(StringUtils.isEmpty(phoneNum) || cameraType == null){
+        if(StringUtils.isEmpty(phoneNum) ){
             throw new BusinessException(LoginConstant.FAILURE_CODE_3001, LoginConstant.FAILURE_MSG_3001);
         }
         User user = userService.getByUserName(phoneNum);