修改返回结果

master
星期八 5 years ago
parent 7fe29b9496
commit 9c44badcc8
  1. 4
      src/main/java/com/lq/cms/web/sys/RoleController.java

@ -89,7 +89,7 @@ public class RoleController {
@RequestMapping("/updatePermission") @RequestMapping("/updatePermission")
@RequiresPermissions(INDEX_URL+ Constant.PERSSION_MARK+Constant.PERMISSION_UPDATE) @RequiresPermissions(INDEX_URL+ Constant.PERSSION_MARK+Constant.PERMISSION_UPDATE)
public Object updatePermission(@RequestBody List<SysRoleResourcePermissionVo> list){ public Object updatePermission(@RequestBody List<SysRoleResourcePermissionVo> list){
AjaxResult ajaxResult=new AjaxResult(); AjaxResult ajaxResult=AjaxResult.getSuccessInstance();
boolean result=sysRoleResourcePermissionService.updateRolePermission(list); boolean result=sysRoleResourcePermissionService.updateRolePermission(list);
ajaxResult.setSuccess(result); ajaxResult.setSuccess(result);
if (!result){ if (!result){
@ -103,7 +103,7 @@ public class RoleController {
@RequiresPermissions(INDEX_URL+ Constant.PERSSION_MARK+Constant.PERMISSION_INSERT) @RequiresPermissions(INDEX_URL+ Constant.PERSSION_MARK+Constant.PERMISSION_INSERT)
public Object save(SysRole sysRole){ public Object save(SysRole sysRole){
Date nowTime = new Date(); Date nowTime = new Date();
AjaxResult ajaxResult = new AjaxResult(true," 保存成功",""); AjaxResult ajaxResult =AjaxResult.getSuccessInstance();
if (sysRole!=null){ if (sysRole!=null){
sysRole.setCreateTime(nowTime); sysRole.setCreateTime(nowTime);
sysRole.setUpdateTime(nowTime); sysRole.setUpdateTime(nowTime);

Loading…
Cancel
Save