diff --git a/laws-modules/src/main/java/com/jero/modules/laws/common/service/ILawsCommonService.java b/laws-modules/src/main/java/com/jero/modules/laws/common/service/ILawsCommonService.java index 929a2020..3b199da2 100644 --- a/laws-modules/src/main/java/com/jero/modules/laws/common/service/ILawsCommonService.java +++ b/laws-modules/src/main/java/com/jero/modules/laws/common/service/ILawsCommonService.java @@ -167,13 +167,6 @@ public interface ILawsCommonService { */ List importExcelWithData(MultipartFile file, String module); - /** - * @Author: liao - * @Date: 2023/9/27 18:01 - * @Description: 增加浏览记录 - **/ - void addLookHistory(String id, String type, String module, String standardNo); - /** * 获取文件内容 * @param file diff --git a/laws-modules/src/main/java/com/jero/modules/laws/common/service/impl/LawsCommonServiceImpl.java b/laws-modules/src/main/java/com/jero/modules/laws/common/service/impl/LawsCommonServiceImpl.java index 137fcf01..4ac17eb7 100644 --- a/laws-modules/src/main/java/com/jero/modules/laws/common/service/impl/LawsCommonServiceImpl.java +++ b/laws-modules/src/main/java/com/jero/modules/laws/common/service/impl/LawsCommonServiceImpl.java @@ -1663,33 +1663,6 @@ public class LawsCommonServiceImpl implements ILawsCommonService { } } - /** - * @Author: liao - * @Date: 2023/9/27 18:02 - * @Description: 增加浏览记录 - **/ - @Override - public void addLookHistory(String id, String type, String module, String standardNo) { - if ("1".equals(type)) { - // 详情显示 - LawsBrowsingHistory history = new LawsBrowsingHistory(); - ManyStandardSelectionBox singleStandard = null; - if (StrUtil.isNotBlank(id)) { - singleStandard = getSingleStandard(null, id); - } else { - singleStandard = getSingleStandard(standardNo, null); - } - if (singleStandard == null) { - throw new JeroBootException(ResultCommon.NO_CORRESPONDING_DATA_FOUND); - } - history.setStandardId(id); - history.setStandardNumber(singleStandard.getStandardNumber()); - history.setStandardName(singleStandard.getStandardName()); - history.setStandardType(module); - lawsBrowsingHistoryService.add(history); - } - } - /** * 校验导入数据有效性 * @@ -1752,7 +1725,7 @@ public class LawsCommonServiceImpl implements ILawsCommonService { } if (tableName.equals(TableNameEnum.DOMESTIC_REGULATIONS.getTableName())) { // 检查Excel的文件名 - if (!excelName.equals("国内标准导入模板.xls")) { + if (!excelName.equals("外部标准导入模板.xls")) { FileUnZip.deleteDir(saveDirectory); throw new JeroBootException(MessageUtils.getMessage(ResultCommon.IMPORT_TEMPLATE_ERROR)); } @@ -2666,7 +2639,6 @@ public class LawsCommonServiceImpl implements ILawsCommonService { LawsDomesticStandard gbStandard = lawsDomesticStandardService.getOne(new LambdaQueryWrapper() .eq(LawsDomesticStandard::getStandardNumber, standardNumber)); if (gbStandard != null) { - this.addLookHistory(gbStandard.getId(), "1", TableNameEnum.DOMESTIC_REGULATIONS.getValue(), standardNumber); result = this.getByIdAndModule(gbStandard.getId(), TableNameEnum.DOMESTIC_REGULATIONS.getValue(), "1", standardNumber); result.put("source", TableNameEnum.DOMESTIC_REGULATIONS.getValue()); return result; @@ -2674,7 +2646,6 @@ public class LawsCommonServiceImpl implements ILawsCommonService { LawsEnterpriseStandard esStandard = lawsEnterpriseStandardService.getOne(new LambdaQueryWrapper() .eq(LawsEnterpriseStandard::getStandardNumber, standardNumber)); if (esStandard != null) { - this.addLookHistory(esStandard.getId(), "1", TableNameEnum.ENTERPRISE_STANDARDS.getValue(), standardNumber); result = this.getByIdAndModule(esStandard.getId(), TableNameEnum.ENTERPRISE_STANDARDS.getValue(), "1", standardNumber); result.put("source", TableNameEnum.ENTERPRISE_STANDARDS.getValue()); return result; diff --git a/laws-modules/src/main/java/com/jero/modules/laws/standard/controller/LawsDomesticController.java b/laws-modules/src/main/java/com/jero/modules/laws/standard/controller/LawsDomesticController.java index d79c6ae7..105840db 100644 --- a/laws-modules/src/main/java/com/jero/modules/laws/standard/controller/LawsDomesticController.java +++ b/laws-modules/src/main/java/com/jero/modules/laws/standard/controller/LawsDomesticController.java @@ -135,7 +135,6 @@ public class LawsDomesticController { public Result> getByIdAndModule(@RequestParam(name="id", required = false) @ApiParam("主键") String id, @RequestParam(name="type") @ApiParam("类型(1详情,2新增编辑)") String type, @RequestParam(name="standardNumber", required = false) @ApiParam("标准编号") String standardNumber) { - lawsCommonService.addLookHistory(id, type, MODULE_VALUE, standardNumber); return Result.OK(lawsCommonService.getByIdAndModule(id, MODULE_VALUE, type, standardNumber)); } @@ -184,7 +183,7 @@ public class LawsDomesticController { @RequiresPermissions("domesticStandard:export") public void exportData(HttpServletResponse response, @RequestBody(required = false) @ApiParam("标签管理") Map parameterMap) { parameterMap.put(FieldCommon.MODULE, MODULE_VALUE); - lawsCommonService.commonExport(response, parameterMap, "国内标准", "国内标准"); + lawsCommonService.commonExport(response, parameterMap, "外部标准", "外部标准"); } @AutoLog(value = "国内法规标准-带文件导出") @@ -194,7 +193,7 @@ public class LawsDomesticController { @RequiresPermissions("domesticStandard:exportFile") public void exportDataWithFile(HttpServletResponse response, @RequestBody(required = false) @ApiParam("标签管理") Map parameterMap) { parameterMap.put(FieldCommon.MODULE, MODULE_VALUE); - lawsCommonService.exportDataWithFile(response, parameterMap, "国内标准", "国内标准"); + lawsCommonService.exportDataWithFile(response, parameterMap, "外部标准", "外部标准"); } @AutoLog(value = "国内法规标准-模板下载") diff --git a/laws-modules/src/main/java/com/jero/modules/laws/standard/controller/LawsEnterpriseController.java b/laws-modules/src/main/java/com/jero/modules/laws/standard/controller/LawsEnterpriseController.java index 7aa92fbb..210b93bb 100644 --- a/laws-modules/src/main/java/com/jero/modules/laws/standard/controller/LawsEnterpriseController.java +++ b/laws-modules/src/main/java/com/jero/modules/laws/standard/controller/LawsEnterpriseController.java @@ -156,8 +156,6 @@ public class LawsEnterpriseController { public Result> getByIdAndModule(@RequestParam(name="id", required = false) @ApiParam("主键") String id, @RequestParam(name="type") @ApiParam("类型(1详情,2新增编辑)") String type, @RequestParam(name="standardNumber", required = false) @ApiParam("标准编号") String standardNumber) { - - lawsCommonService.addLookHistory(id, type, MODULE_VALUE, standardNumber); return Result.OK(lawsCommonService.getByIdAndModule(id, MODULE_VALUE, type, standardNumber)); } diff --git a/laws-modules/src/main/java/com/jero/modules/tag/enums/TableNameEnum.java b/laws-modules/src/main/java/com/jero/modules/tag/enums/TableNameEnum.java index 6c3b6fcb..ab4014e0 100644 --- a/laws-modules/src/main/java/com/jero/modules/tag/enums/TableNameEnum.java +++ b/laws-modules/src/main/java/com/jero/modules/tag/enums/TableNameEnum.java @@ -10,7 +10,7 @@ public enum TableNameEnum { /** * */ - DOMESTIC_REGULATIONS("国内标准","laws_domestic_standard","1"), + DOMESTIC_REGULATIONS("外部标准","laws_domestic_standard","1"), ENTERPRISE_STANDARDS("企业标准","laws_enterprise_standard","3"), DOCUMENT_SPLIT("条款拆分","laws_document_split","4"), HOME_SEARCH("高级搜索(全部)","home_search","5")