diff --git a/src/main/java/com/biutag/supervision/controller/system/DictController.java b/src/main/java/com/biutag/supervision/controller/system/DictController.java index 550fefd..497e52f 100644 --- a/src/main/java/com/biutag/supervision/controller/system/DictController.java +++ b/src/main/java/com/biutag/supervision/controller/system/DictController.java @@ -32,9 +32,10 @@ public class DictController { private final SupDictProblemSourceService dictProblemSourceService; @GetMapping - public Result> page(Page page, String dictName) { + public Result> page(Page page, String dictName, String dictType) { LambdaQueryWrapper queryWrapper = new LambdaQueryWrapper() .like(StrUtil.isNotBlank(dictName), SupDictType::getDictName, dictName) + .like(StrUtil.isNotBlank(dictType), SupDictType::getDictType, dictType) .orderByDesc(SupDictType::getUpdateTime); return Result.success(dictTypeService.page(page, queryWrapper)); } diff --git a/src/main/java/com/biutag/supervision/controller/system/HandleResultMapingController.java b/src/main/java/com/biutag/supervision/controller/system/HandleResultMapingController.java index 61a9b11..cebec52 100644 --- a/src/main/java/com/biutag/supervision/controller/system/HandleResultMapingController.java +++ b/src/main/java/com/biutag/supervision/controller/system/HandleResultMapingController.java @@ -26,7 +26,9 @@ public class HandleResultMapingController { @GetMapping public Result> list(DepartMapingQueryParam param) { LambdaQueryWrapper queryWrapper = new LambdaQueryWrapper<>(); - queryWrapper.like(StrUtil.isNotBlank(param.getExternalName()), SupDictHandleResultMaping::getExternalName, param.getExternalName()) + queryWrapper + .eq(SupDictHandleResultMaping::getSource, param.getSource()) + .like(StrUtil.isNotBlank(param.getExternalName()), SupDictHandleResultMaping::getExternalName, param.getExternalName()) .eq(StrUtil.isNotBlank(param.getInternalId()), SupDictHandleResultMaping::getInternalId, param.getInternalId()) .orderByDesc(SupDictHandleResultMaping::getCreateTime); return Result.success(handleResultMapingService.page(Page.of(param.getCurrent(), param.getSize()), queryWrapper)); @@ -49,8 +51,9 @@ public class HandleResultMapingController { public Result update(@RequestBody SupDictHandleResultMaping data) { if (handleResultMapingService.exists(new LambdaQueryWrapper() .eq(SupDictHandleResultMaping::getExternalName, data.getExternalName()) + .eq(SupDictHandleResultMaping::getSource, data.getSource()) .ne(SupDictHandleResultMaping::getId, data.getId()))) { - throw new RuntimeException(String.format("单位编码【%s】已存在", data.getExternalName())); + throw new RuntimeException(String.format("处理结果【%s】已存在", data.getExternalName())); } data.setUpdateTime(LocalDateTime.now()); handleResultMapingService.updateById(data); diff --git a/src/main/java/com/biutag/supervision/pojo/entity/SupDictHandleResultMaping.java b/src/main/java/com/biutag/supervision/pojo/entity/SupDictHandleResultMaping.java index 345f78d..27c5831 100644 --- a/src/main/java/com/biutag/supervision/pojo/entity/SupDictHandleResultMaping.java +++ b/src/main/java/com/biutag/supervision/pojo/entity/SupDictHandleResultMaping.java @@ -21,6 +21,9 @@ public class SupDictHandleResultMaping { @TableField("external_name") private String externalName; + // 处理结论形态 + private String externalType; + // @TableField("internal_name") private String internalName; @@ -38,4 +41,7 @@ public class SupDictHandleResultMaping { @JsonFormat(pattern = "yyyy-MM-dd HH:mm") private LocalDateTime updateTime; + // 来源 + private String source; + } \ No newline at end of file diff --git a/src/main/java/com/biutag/supervision/pojo/param/DepartMapingQueryParam.java b/src/main/java/com/biutag/supervision/pojo/param/DepartMapingQueryParam.java index 38d3881..d422103 100644 --- a/src/main/java/com/biutag/supervision/pojo/param/DepartMapingQueryParam.java +++ b/src/main/java/com/biutag/supervision/pojo/param/DepartMapingQueryParam.java @@ -21,4 +21,6 @@ public class DepartMapingQueryParam extends BasePage { // 是否已映射 private String activeMaping; + private String source; + }