diff --git a/postdischarge-admin/src/main/resources/template/科室信息导入表.xlsx b/postdischarge-admin/src/main/resources/template/科室信息导入表.xlsx index 96e2fb96..5a0c7c8f 100644 Binary files a/postdischarge-admin/src/main/resources/template/科室信息导入表.xlsx and b/postdischarge-admin/src/main/resources/template/科室信息导入表.xlsx differ diff --git a/postdischarge-common/src/main/java/com/xinelu/common/constant/Constants.java b/postdischarge-common/src/main/java/com/xinelu/common/constant/Constants.java index e7d20390..e118190c 100644 --- a/postdischarge-common/src/main/java/com/xinelu/common/constant/Constants.java +++ b/postdischarge-common/src/main/java/com/xinelu/common/constant/Constants.java @@ -194,6 +194,16 @@ public class Constants { */ public static final String TASK_STATUS_CODE = "TSC"; + /** + * 任务状态编码 + */ + public static final String AGENCY_CODE = "AYC"; + + /** + * 任务状态编码 + */ + public static final String DEPARTMENT_CODE = "DTC"; + /** * 门诊患者 */ @@ -323,9 +333,4 @@ public class Constants { * 资讯编码前缀 */ public static final String INFO_CODE = "IC"; - - /** - * 科室编码前缀 - */ - public static final String DEPARTMENT_CODE = "HDC"; } diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/domain/department/Department.java b/postdischarge-manage/src/main/java/com/xinelu/manage/domain/department/Department.java index 4e2d3884..8879a9f1 100644 --- a/postdischarge-manage/src/main/java/com/xinelu/manage/domain/department/Department.java +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/domain/department/Department.java @@ -165,7 +165,6 @@ public class Department extends BaseEntity { */ @ApiModelProperty(value = "成立日期") @JsonFormat(pattern = "yyyy-MM-dd") - @Excel(name = "成立日期", width = 30, dateFormat = "yyyy-MM-dd") private LocalDate establishDate; /** @@ -173,7 +172,6 @@ public class Department extends BaseEntity { */ @ApiModelProperty(value = "撤销日期") @JsonFormat(pattern = "yyyy-MM-dd") - @Excel(name = "撤销日期", width = 30, dateFormat = "yyyy-MM-dd") private LocalDate revokeDate; @Override diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/service/agency/impl/AgencyServiceImpl.java b/postdischarge-manage/src/main/java/com/xinelu/manage/service/agency/impl/AgencyServiceImpl.java index 443309c3..b63f026f 100644 --- a/postdischarge-manage/src/main/java/com/xinelu/manage/service/agency/impl/AgencyServiceImpl.java +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/service/agency/impl/AgencyServiceImpl.java @@ -1,10 +1,12 @@ package com.xinelu.manage.service.agency.impl; +import com.xinelu.common.constant.Constants; import com.xinelu.common.core.domain.AjaxResult; import com.xinelu.common.enums.NodeTypeEnum; import com.xinelu.common.exception.ServiceException; import com.xinelu.common.utils.SecurityUtils; import com.xinelu.common.utils.bean.BeanUtils; +import com.xinelu.common.utils.codes.GenerateSystemCodeUtil; import com.xinelu.common.utils.regex.RegexUtil; import com.xinelu.manage.domain.agency.Agency; import com.xinelu.manage.domain.department.Department; @@ -48,6 +50,8 @@ public class AgencyServiceImpl implements IAgencyService { private SysAreaMapper sysAreaMapper; @Resource private DepartmentMapper departmentMapper; + @Resource + private GenerateSystemCodeUtil generateSystemCodeUtil; /** @@ -114,6 +118,7 @@ public class AgencyServiceImpl implements IAgencyService { } agency.setCreateTime(LocalDateTime.now()); agency.setCreateBy(SecurityUtils.getUsername()); + agency.setAgencyCode(Constants.AGENCY_CODE + generateSystemCodeUtil.generateSystemCode(Constants.AGENCY_CODE)); return AjaxResult.success(agencyMapper.insertAgency(agency)); } diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/service/department/impl/DepartmentServiceImpl.java b/postdischarge-manage/src/main/java/com/xinelu/manage/service/department/impl/DepartmentServiceImpl.java index da78de81..946f1ea0 100644 --- a/postdischarge-manage/src/main/java/com/xinelu/manage/service/department/impl/DepartmentServiceImpl.java +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/service/department/impl/DepartmentServiceImpl.java @@ -1,11 +1,13 @@ package com.xinelu.manage.service.department.impl; +import com.xinelu.common.constant.Constants; import com.xinelu.common.core.domain.AjaxResult; import com.xinelu.common.core.domain.entity.SysUser; import com.xinelu.common.exception.ServiceException; import com.xinelu.common.utils.SecurityUtils; import com.xinelu.common.utils.StringUtils; import com.xinelu.common.utils.bean.BeanUtils; +import com.xinelu.common.utils.codes.GenerateSystemCodeUtil; import com.xinelu.common.utils.regex.RegexUtil; import com.xinelu.manage.domain.department.Department; import com.xinelu.manage.dto.department.DepartmentDTO; @@ -41,6 +43,8 @@ public class DepartmentServiceImpl implements IDepartmentService { private RegexUtil regexUtil; @Resource private SysUserMapper sysUserMapper; + @Resource + private GenerateSystemCodeUtil generateSystemCodeUtil; /** * 查询科室信息 @@ -108,6 +112,7 @@ public class DepartmentServiceImpl implements IDepartmentService { } department.setCreateTime(LocalDateTime.now()); department.setCreateBy(SecurityUtils.getUsername()); + department.setDepartmentCode(Constants.DEPARTMENT_CODE + generateSystemCodeUtil.generateSystemCode(Constants.DEPARTMENT_CODE)); return departmentMapper.insertDepartment(department); } diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/service/infocategory/impl/InfoCategoryServiceImpl.java b/postdischarge-manage/src/main/java/com/xinelu/manage/service/infocategory/impl/InfoCategoryServiceImpl.java index 27fad338..4504c16c 100644 --- a/postdischarge-manage/src/main/java/com/xinelu/manage/service/infocategory/impl/InfoCategoryServiceImpl.java +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/service/infocategory/impl/InfoCategoryServiceImpl.java @@ -89,7 +89,7 @@ public class InfoCategoryServiceImpl implements IInfoCategoryService { infocategory.setCreateTime(LocalDateTime.now());//设置添加时间 infocategory.setInfoCategoryCreator(SecurityUtils.getUsername());//设置当前的用户 infocategory.setInfoCategoryType(infocategory.getInfoCategoryName());//类型 无用 直接赋值和名称相同 - infocategory.setInfoCategoryCode(Constants.INFO_CATEGORY_CODE + generateSystemCodeUtil.generateSystemCode(Constants.DEPARTMENT_CODE)); + infocategory.setInfoCategoryCode(Constants.INFO_CATEGORY_CODE + generateSystemCodeUtil.generateSystemCode(Constants.INFO_CATEGORY_CODE)); } int insertCount = infoCategoryMapper.insertInfoCategoryList(infoCategoryDTO.getInfoCategoryList()); if (insertCount < 0) {