Commit 9a814e07 authored by 吴琼's avatar 吴琼

修改返回状态码

parent 88e44011
...@@ -254,7 +254,7 @@ public class UserRest { ...@@ -254,7 +254,7 @@ public class UserRest {
@PostMapping(value = "/search/getRewardPointsType") @PostMapping(value = "/search/getRewardPointsType")
public JsonResult getRewardPointsTypeInit() { public JsonResult getRewardPointsTypeInit() {
MoResult<String> result = userService.getRewardPointsType(); MoResult<String> result = userService.getRewardPointsType();
if(!result.isSuccess()){ if(!"0000".equals(result.getCode())){
return JsonResult.buildErrorStateResult(result.getMsg(),result.getData()); return JsonResult.buildErrorStateResult(result.getMsg(),result.getData());
} }
return JsonResult.buildSuccessResult("success", result.getData()); return JsonResult.buildSuccessResult("success", result.getData());
...@@ -274,7 +274,7 @@ public class UserRest { ...@@ -274,7 +274,7 @@ public class UserRest {
@PostMapping(value = "/search/getUserCouponInfo") @PostMapping(value = "/search/getUserCouponInfo")
public JsonResult getUserCouponInfo(UserQueryParam userQueryParam) { public JsonResult getUserCouponInfo(UserQueryParam userQueryParam) {
MoResult<String> result = userService.queryUserCouponInfoByUserParam(userQueryParam); MoResult<String> result = userService.queryUserCouponInfoByUserParam(userQueryParam);
if(!result.isSuccess()){ if(!"0000".equals(result.getCode())){
return JsonResult.buildErrorStateResult(result.getMsg(),result.getData()); return JsonResult.buildErrorStateResult(result.getMsg(),result.getData());
} }
return JsonResult.buildSuccessResult("success",result); return JsonResult.buildSuccessResult("success",result);
...@@ -287,7 +287,7 @@ public class UserRest { ...@@ -287,7 +287,7 @@ public class UserRest {
@PostMapping(value = "/search/queryPointDetailByPage") @PostMapping(value = "/search/queryPointDetailByPage")
public JsonResult queryPointDetailByPage(UserQueryParam userQueryParam) { public JsonResult queryPointDetailByPage(UserQueryParam userQueryParam) {
MoResult<String> result = userService.queryPointDetailByPage(userQueryParam); MoResult<String> result = userService.queryPointDetailByPage(userQueryParam);
if(result == null || !result.isSuccess()){ if(result == null || !"0000".equals(result.getCode())){
return JsonResult.buildErrorStateResult(result.getMsg(),result.getData()); return JsonResult.buildErrorStateResult(result.getMsg(),result.getData());
} }
return JsonResult.buildSuccessResult("success", result.getData()); return JsonResult.buildSuccessResult("success", result.getData());
......
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