sys包下中英文返回值
This commit is contained in:
+5
-5
@@ -75,7 +75,7 @@ public class LawsProjectLibraryController extends JeroController<LawsProjectLibr
|
||||
public Result<T> add(@Validated @RequestBody LawsProjectLibrary lawsProjectLibrary) {
|
||||
lawsProjectLibrary.setDelFlag("0");
|
||||
lawsProjectLibraryService.add(lawsProjectLibrary);
|
||||
return Result.OK(MessageUtils.getLanguage().equals("EN") ? ResultCommon.OK : "操作成功!");
|
||||
return Result.OK(MessageUtils.getMessage(ResultCommon.OK));
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -86,7 +86,7 @@ public class LawsProjectLibraryController extends JeroController<LawsProjectLibr
|
||||
@PostMapping(value = "/edit")
|
||||
public Result<T> edit(@RequestBody LawsProjectLibrary lawsProjectLibrary) {
|
||||
lawsProjectLibraryService.editById(lawsProjectLibrary);
|
||||
return Result.OK(MessageUtils.getLanguage().equals("EN") ? ResultCommon.OK : "操作成功!");
|
||||
return Result.OK(MessageUtils.getMessage(ResultCommon.OK));
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -100,7 +100,7 @@ public class LawsProjectLibraryController extends JeroController<LawsProjectLibr
|
||||
return Result.error(MessageUtils.getLanguage().equals("EN") ? "Please select data!" : "请选择数据!");
|
||||
}
|
||||
lawsProjectLibraryService.deleteById(map.get("id"));
|
||||
return Result.OK(MessageUtils.getLanguage().equals("EN") ? ResultCommon.OK : "操作成功!");
|
||||
return Result.OK(MessageUtils.getMessage(ResultCommon.OK));
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -111,10 +111,10 @@ public class LawsProjectLibraryController extends JeroController<LawsProjectLibr
|
||||
@PostMapping(value = "/deleteBatch")
|
||||
public Result<T> deleteBatch(@RequestBody Map<String, String> map) {
|
||||
if(!map.containsKey("ids") || StringUtils.isEmpty(map.get("ids"))){
|
||||
return Result.error(MessageUtils.getLanguage().equals("EN") ? "Please select data!" : "请选择数据!");
|
||||
throw new JeroBootException(ResultCommon.PLEASE_SELECT_DATA);
|
||||
}
|
||||
this.lawsProjectLibraryService.deleteByIds(Arrays.asList(map.get("ids").split(",")));
|
||||
return Result.OK(MessageUtils.getLanguage().equals("EN") ? ResultCommon.OK : "批量删除成功!");
|
||||
return Result.error(MessageUtils.getMessage(ResultCommon.SUCCESSFULLY_DELETED_IN_BULK));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user