Commit 4193c4db authored by lee_mingzhu's avatar lee_mingzhu

允许修改用户经济和联系人信息以及地址

parent 77eebf4a
......@@ -56,7 +56,7 @@ public class UserCenterController {
public JsonResult userCenterIndex(String phoneNo) {
Long userId = queryUserId(phoneNo);
if(null == userId || userId == 0L) {
return JsonResult.buildErrorStateResult(null, null);
return JsonResult.buildErrorStateResult("该用户不存在", null);
}
UserAttached userAttached = userCenterService.searchUserAttachedByUserId(userId);
Map<String, String> result = new HashMap<>();
......@@ -86,7 +86,7 @@ public class UserCenterController {
}
Long userId = queryUserId(phoneNo);
if(null == userId || userId == 0L) {
return JsonResult.buildErrorStateResult(null, null);
return JsonResult.buildErrorStateResult("该用户不存在", null);
}
if(StringUtils.isBlank(avatarUrl)) {
avatarUrl = Constants.UserAvatar.AVATAR_DEFAULT;
......@@ -120,7 +120,7 @@ public class UserCenterController {
}
Long userId = queryUserId(phoneNo);
if(null == userId || userId == 0L) {
return JsonResult.buildErrorStateResult(null, null);
return JsonResult.buildErrorStateResult("该用户不存在", null);
}
UserAttached userAttached = userCenterService.searchUserAttachedByUserId(userId);
if(null != userAttached) {
......@@ -144,7 +144,7 @@ public class UserCenterController {
}
Long userId = queryUserId(phoneNo);
if(null == userId || userId == 0L) {
return JsonResult.buildErrorStateResult(null, null);
return JsonResult.buildErrorStateResult("该用户不存在", null);
}
UserAttached userAttached = userCenterService.searchUserAttachedByUserId(userId);
if(null == userAttached) {
......@@ -170,7 +170,7 @@ public class UserCenterController {
}
Long userId = queryUserId(phoneNo);
if(null == userId || userId == 0L) {
return JsonResult.buildErrorStateResult(null, null);
return JsonResult.buildErrorStateResult("该用户不存在", null);
}
UserDetail userDetail = userDetailService.findByUserId(userId);
if(null != userDetail) {
......@@ -192,7 +192,7 @@ public class UserCenterController {
}
Long userId = queryUserId(phoneNo);
if(null == userId || userId == 0L) {
return JsonResult.buildErrorStateResult(null, null);
return JsonResult.buildErrorStateResult("该用户不存在", null);
}
UserExtInfo userExtInfo = userExtInfoService.findByUserId(userId);
List<Contact> contacts = contactService.findByUserId(userId);
......@@ -234,7 +234,7 @@ public class UserCenterController {
Long userId = queryUserId(phoneNo);
if(null == userId || userId == 0L) {
LOGGER.error("保存联系人,未获取到用户id. userId:{}", userId);
return JsonResult.buildErrorStateResult(null, null);
return JsonResult.buildErrorStateResult("该用户不存在", null);
}
if(StringUtils.isEmpty(contactJson)) {
LOGGER.error("保存联系人,联系人参数为空.contactJson:{}", contactJson);
......@@ -288,7 +288,7 @@ public class UserCenterController {
Long userId = queryUserId(phoneNo);
if(null == userId || userId == 0L) {
LOGGER.error("保存联系人,未获取到用户id. userId:{}", userId);
return JsonResult.buildErrorStateResult(null, null);
return JsonResult.buildErrorStateResult("该用户不存在", null);
}
//查询用户是否有保存地址信息
Address addressInfo = addressService.findByUserId(userId);
......@@ -325,7 +325,7 @@ public class UserCenterController {
Long userId = queryUserId(phoneNo);
if(null == userId || userId == 0L) {
LOGGER.error("保存联系人,未获取到用户id. userId:{}", userId);
return JsonResult.buildErrorStateResult(null, null);
return JsonResult.buildErrorStateResult("该用户不存在", null);
}
Address address = addressService.findByUserId(userId);
if (address == null) {
......@@ -347,7 +347,7 @@ public class UserCenterController {
Long userId = queryUserId(phoneNo);
if(null == userId || userId == 0L) {
LOGGER.error("保存联系人,未获取到用户id. userId:{}", userId);
return JsonResult.buildErrorStateResult(null, null);
return JsonResult.buildErrorStateResult("该用户不存在", null);
}
List<Contact> contacts = contactService.findByUserId(userId);
if(null == contacts || contacts.size() == 0) {
......@@ -372,7 +372,7 @@ public class UserCenterController {
Long userId = queryUserId(phoneNo);
if(null == userId || userId == 0L) {
LOGGER.error("保存用户经济信息,未获取到用户id. userId:{}", userId);
return JsonResult.buildErrorStateResult(null, null);
return JsonResult.buildErrorStateResult("该用户不存在", null);
}
//查询用户是否保存过.
UserExtInfo userExtInfo = userExtInfoService.findByUserId(userId);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment