|
@@ -28,7 +28,12 @@ public class CustomAnalyseController {
|
|
@Operation(summary = "查询组别/分析项")
|
|
@Operation(summary = "查询组别/分析项")
|
|
@PostMapping("/queryAnalyseGroup")
|
|
@PostMapping("/queryAnalyseGroup")
|
|
public Response queryAnalyseGroup(@RequestBody SelectCustomAnalyseVO vo) {
|
|
public Response queryAnalyseGroup(@RequestBody SelectCustomAnalyseVO vo) {
|
|
- List<SelectCustomAnalyseListDTO> list = customAnalyseService.queryAnalyseGroup(vo);
|
|
|
|
|
|
+ List<SelectCustomAnalyseListDTO> list = null;
|
|
|
|
+ try {
|
|
|
|
+ list = customAnalyseService.queryAnalyseGroup(vo);
|
|
|
|
+ } catch (Exception e) {
|
|
|
|
+ return Response.success(e.getMessage());
|
|
|
|
+ }
|
|
return Response.success(list);
|
|
return Response.success(list);
|
|
}
|
|
}
|
|
|
|
|
|
@@ -49,21 +54,36 @@ public class CustomAnalyseController {
|
|
@Operation(summary = "添加组别/分析项")
|
|
@Operation(summary = "添加组别/分析项")
|
|
@PostMapping("/addAnalyseGroup")
|
|
@PostMapping("/addAnalyseGroup")
|
|
public Response addAnalyseGroup(@RequestBody CustomAnalyseDTO vo) throws Exception {
|
|
public Response addAnalyseGroup(@RequestBody CustomAnalyseDTO vo) throws Exception {
|
|
- Integer groupId = customAnalyseService.addAnalyseGroup(vo);
|
|
|
|
|
|
+ Integer groupId = null;
|
|
|
|
+ try {
|
|
|
|
+ groupId = customAnalyseService.addAnalyseGroup(vo);
|
|
|
|
+ } catch (Exception e) {
|
|
|
|
+ return Response.success(e.getMessage());
|
|
|
|
+ }
|
|
return Response.success(groupId);
|
|
return Response.success(groupId);
|
|
}
|
|
}
|
|
|
|
|
|
@Operation(summary = "编辑组别")
|
|
@Operation(summary = "编辑组别")
|
|
@PostMapping("/editAnalyseGroup")
|
|
@PostMapping("/editAnalyseGroup")
|
|
public Response editAnalyseGroup(@RequestBody CustomAnalyseDTO vo) throws Exception {
|
|
public Response editAnalyseGroup(@RequestBody CustomAnalyseDTO vo) throws Exception {
|
|
- Integer groupId = customAnalyseService.editAnalyseGroup(vo);
|
|
|
|
|
|
+ Integer groupId = null;
|
|
|
|
+ try {
|
|
|
|
+ groupId = customAnalyseService.editAnalyseGroup(vo);
|
|
|
|
+ } catch (Exception e) {
|
|
|
|
+ return Response.success(e.getMessage());
|
|
|
|
+ }
|
|
return Response.success(groupId);
|
|
return Response.success(groupId);
|
|
}
|
|
}
|
|
|
|
|
|
@Operation(summary = "删除组别/分析项")
|
|
@Operation(summary = "删除组别/分析项")
|
|
@PostMapping("/delAnalyseGroup")
|
|
@PostMapping("/delAnalyseGroup")
|
|
public Response delAnalyseGroup(@RequestBody CustomAnalyseIdVO vo) throws Exception {
|
|
public Response delAnalyseGroup(@RequestBody CustomAnalyseIdVO vo) throws Exception {
|
|
- Integer groupId = customAnalyseService.delAnalyseGroup(vo);
|
|
|
|
|
|
+ Integer groupId = null;
|
|
|
|
+ try {
|
|
|
|
+ groupId = customAnalyseService.delAnalyseGroup(vo);
|
|
|
|
+ } catch (Exception e) {
|
|
|
|
+ return Response.success(e.getMessage());
|
|
|
|
+ }
|
|
return Response.success(groupId);
|
|
return Response.success(groupId);
|
|
}
|
|
}
|
|
}
|
|
}
|