字典回显修改
This commit is contained in:
parent
f273b5a5a5
commit
f06a6db9f4
@ -2,12 +2,12 @@ package com.xinelu.manage.service.department.impl;
|
||||
|
||||
import com.xinelu.common.annotation.DataScope;
|
||||
import com.xinelu.common.core.domain.AjaxResult;
|
||||
import com.xinelu.common.core.domain.entity.SysDictData;
|
||||
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.agency.Agency;
|
||||
import com.xinelu.manage.domain.department.Department;
|
||||
@ -18,6 +18,7 @@ import com.xinelu.manage.service.department.IDepartmentService;
|
||||
import com.xinelu.manage.vo.department.DepartmentBaseVo;
|
||||
import com.xinelu.manage.vo.department.DepartmentListVO;
|
||||
import com.xinelu.manage.vo.department.DepartmentVO;
|
||||
import com.xinelu.system.mapper.SysDictDataMapper;
|
||||
import com.xinelu.system.mapper.SysUserMapper;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import org.apache.commons.lang3.BooleanUtils;
|
||||
@ -50,7 +51,7 @@ public class DepartmentServiceImpl implements IDepartmentService {
|
||||
@Resource
|
||||
private AgencyMapper agencyMapper;
|
||||
@Resource
|
||||
private GenerateSystemCodeUtil generateSystemCodeUtil;
|
||||
private SysDictDataMapper sysDictDataMapper;
|
||||
|
||||
/**
|
||||
* 查询科室信息
|
||||
@ -71,7 +72,22 @@ public class DepartmentServiceImpl implements IDepartmentService {
|
||||
*/
|
||||
@Override
|
||||
public List<Department> selectDepartmentList(Department department) {
|
||||
return departmentMapper.selectDepartmentList(department);
|
||||
List<Department> departmentList = departmentMapper.selectDepartmentList(department);
|
||||
List<String> strings = new ArrayList<>();
|
||||
strings.add("provide_service_category");
|
||||
strings.add("department_type");
|
||||
List<SysDictData> sysDictDataList = sysDictDataMapper.selectDictDataByTypeList(strings);
|
||||
for (Department dataDepartment : departmentList) {
|
||||
SysDictData departmentType = sysDictDataList.stream().filter(Objects::nonNull).filter(item -> item.getDictValue().equals(dataDepartment.getDepartmentType())).findFirst().orElse(new SysDictData());
|
||||
if (org.apache.commons.lang3.StringUtils.isNotBlank(departmentType.getDictLabel())){
|
||||
dataDepartment.setDepartmentType(departmentType.getDictLabel());
|
||||
}
|
||||
SysDictData provideServiceCategory = sysDictDataList.stream().filter(Objects::nonNull).filter(item -> item.getDictValue().equals(dataDepartment.getProvideServiceCategory())).findFirst().orElse(new SysDictData());
|
||||
if (org.apache.commons.lang3.StringUtils.isNotBlank(provideServiceCategory.getDictLabel())){
|
||||
dataDepartment.setProvideServiceCategory(provideServiceCategory.getDictLabel());
|
||||
}
|
||||
}
|
||||
return departmentList;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -1,6 +1,7 @@
|
||||
package com.xinelu.manage.service.labelfieldinfo.impl;
|
||||
|
||||
import com.xinelu.common.core.domain.AjaxResult;
|
||||
import com.xinelu.common.core.domain.entity.SysDictData;
|
||||
import com.xinelu.common.exception.ServiceException;
|
||||
import com.xinelu.common.utils.SecurityUtils;
|
||||
import com.xinelu.manage.domain.labelfieldinfo.LabelFieldInfo;
|
||||
@ -13,6 +14,7 @@ import com.xinelu.manage.service.labelfieldinfo.ILabelFieldInfoService;
|
||||
import com.xinelu.manage.vo.labelfieldinfo.LabelFieldTreeVO;
|
||||
import com.xinelu.manage.vo.labelfieldinfo.LabelFieldVO;
|
||||
import com.xinelu.manage.vo.tasktypedict.TaskTypeDictVO;
|
||||
import com.xinelu.system.mapper.SysDictDataMapper;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import org.apache.commons.lang3.ObjectUtils;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
@ -40,6 +42,8 @@ public class LabelFieldInfoServiceImpl implements ILabelFieldInfoService {
|
||||
private TaskTypeDictMapper taskTypeDictMapper;
|
||||
@Resource
|
||||
private TaskPartitionDictMapper taskPartitionDictMapper;
|
||||
@Resource
|
||||
private SysDictDataMapper sysDictDataMapper;
|
||||
|
||||
/**
|
||||
* 查询标签字段信息
|
||||
@ -60,7 +64,15 @@ public class LabelFieldInfoServiceImpl implements ILabelFieldInfoService {
|
||||
*/
|
||||
@Override
|
||||
public List<LabelFieldInfo> selectLabelFieldInfoList(LabelFieldInfo labelFieldInfo) {
|
||||
return labelFieldInfoMapper.selectLabelFieldInfoList(labelFieldInfo);
|
||||
List<LabelFieldInfo> labelFieldInfoList = labelFieldInfoMapper.selectLabelFieldInfoList(labelFieldInfo);
|
||||
List<SysDictData> sysDictDataList = sysDictDataMapper.selectDictDataByType("field_type");
|
||||
for (LabelFieldInfo fieldInfo : labelFieldInfoList) {
|
||||
SysDictData sysDictData = sysDictDataList.stream().filter(Objects::nonNull).filter(item -> item.getDictValue().equals(fieldInfo.getFieldType())).findFirst().orElse(new SysDictData());
|
||||
if (StringUtils.isNotBlank(sysDictData.getDictLabel())) {
|
||||
fieldInfo.setFieldType(sysDictData.getDictLabel());
|
||||
}
|
||||
}
|
||||
return labelFieldInfoList;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -12,6 +12,7 @@ import com.xinelu.common.annotation.DataScope;
|
||||
import com.xinelu.common.config.AliYunSmsTwoConfig;
|
||||
import com.xinelu.common.constant.*;
|
||||
import com.xinelu.common.core.domain.AjaxResult;
|
||||
import com.xinelu.common.core.domain.entity.SysDictData;
|
||||
import com.xinelu.common.enums.*;
|
||||
import com.xinelu.common.exception.ServiceException;
|
||||
import com.xinelu.common.utils.AgeUtil;
|
||||
@ -31,6 +32,7 @@ import com.xinelu.manage.domain.signpatientmanageroute.SignPatientManageRoute;
|
||||
import com.xinelu.manage.domain.signpatientmanageroutenode.SignPatientManageRouteNode;
|
||||
import com.xinelu.manage.domain.signpatientrecord.SignPatientRecord;
|
||||
import com.xinelu.manage.domain.signroutetriggercondition.SignRouteTriggerCondition;
|
||||
import com.xinelu.manage.domain.taskpartitiondict.TaskPartitionDict;
|
||||
import com.xinelu.manage.dto.aiob.ActualTimeTaskDto;
|
||||
import com.xinelu.manage.dto.manualfollowup.ManualFollowUpDTO;
|
||||
import com.xinelu.manage.dto.patientinfo.PatientInfoDto;
|
||||
@ -80,6 +82,7 @@ import com.xinelu.manage.vo.specialdiseasenode.RouteTaskAuditVo;
|
||||
import com.xinelu.manage.vo.specialdiseasenode.SpecialDiseaseNodeAuditVo;
|
||||
import com.xinelu.manage.vo.specialdiseaseroute.SpecialDiseaseChildRouteAuditVo;
|
||||
import com.xinelu.manage.vo.specialdiseaseroute.SpecialDiseaseRouteAuditVo;
|
||||
import com.xinelu.system.mapper.SysDictDataMapper;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import org.apache.commons.lang3.ObjectUtils;
|
||||
@ -147,15 +150,14 @@ public class SignPatientManageRouteServiceImpl implements ISignPatientManageRout
|
||||
private ShortMessageSendRecordMapper shortMessageSendRecordMapper;
|
||||
@Resource
|
||||
private IPatientTaskStatisticsService patientTaskStatisticsService;
|
||||
|
||||
@Resource
|
||||
private ILabelFieldContentService labelFieldContentService;
|
||||
|
||||
|
||||
@Resource
|
||||
private PatientInfoMapper patientInfoMapper;
|
||||
@Resource
|
||||
private IAIOBService aiobService;
|
||||
@Resource
|
||||
private SysDictDataMapper sysDictDataMapper;
|
||||
@Value("${aiob.callBackUrl}")
|
||||
private String callBackUrl;
|
||||
|
||||
@ -383,6 +385,21 @@ public class SignPatientManageRouteServiceImpl implements ISignPatientManageRout
|
||||
}
|
||||
//1、查询
|
||||
List<ManualFollowUpVO> manualFollowUpVOS = signPatientManageRouteMapper.selectManualFollowUpList(manualFollowUpDTO);
|
||||
//字典名称匹配
|
||||
ArrayList<String> strings = new ArrayList<>();
|
||||
strings.add("task_node_type");
|
||||
strings.add("route_name");
|
||||
List<SysDictData> sysDictDataList = sysDictDataMapper.selectDictDataByTypeList(strings);
|
||||
for (ManualFollowUpVO manualFollowUpVO : manualFollowUpVOS) {
|
||||
SysDictData taskNodeType = sysDictDataList.stream().filter(Objects::nonNull).filter(item -> item.getDictValue().equals(manualFollowUpVO.getTaskNodeType())).findFirst().orElse(new SysDictData());
|
||||
if (StringUtils.isNotBlank(taskNodeType.getDictLabel())){
|
||||
manualFollowUpVO.setTaskNodeTypeName(taskNodeType.getDictLabel());
|
||||
}
|
||||
SysDictData routeNodeName = sysDictDataList.stream().filter(Objects::nonNull).filter(item -> item.getDictValue().equals(manualFollowUpVO.getRouteNodeName())).findFirst().orElse(new SysDictData());
|
||||
if (StringUtils.isNotBlank(routeNodeName.getDictLabel())){
|
||||
manualFollowUpVO.setRouteNode(routeNodeName.getDictLabel());
|
||||
}
|
||||
}
|
||||
//2、1如果是查询已执行的任务,直接返回查询结果
|
||||
if (manualFollowUpDTO.getNodeExecuteStatus().equals(NodeExecuteStatusEnum.EXECUTED.getInfo())) {
|
||||
return manualFollowUpVOS;
|
||||
|
||||
@ -1,16 +1,20 @@
|
||||
package com.xinelu.manage.service.taskpartitiondict.impl;
|
||||
|
||||
import com.xinelu.common.constant.Constants;
|
||||
import com.xinelu.common.core.domain.entity.SysDictData;
|
||||
import com.xinelu.common.utils.SecurityUtils;
|
||||
import com.xinelu.common.utils.codes.GenerateSystemCodeUtil;
|
||||
import com.xinelu.manage.domain.taskpartitiondict.TaskPartitionDict;
|
||||
import com.xinelu.manage.mapper.taskpartitiondict.TaskPartitionDictMapper;
|
||||
import com.xinelu.manage.service.taskpartitiondict.ITaskPartitionDictService;
|
||||
import com.xinelu.system.mapper.SysDictDataMapper;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
|
||||
|
||||
/**
|
||||
@ -25,6 +29,8 @@ public class TaskPartitionDictServiceImpl implements ITaskPartitionDictService {
|
||||
private TaskPartitionDictMapper taskPartitionDictMapper;
|
||||
@Resource
|
||||
private GenerateSystemCodeUtil generateSystemCodeUtil;
|
||||
@Resource
|
||||
private SysDictDataMapper sysDictDataMapper;
|
||||
|
||||
/**
|
||||
* 查询任务细分字典
|
||||
@ -45,7 +51,15 @@ public class TaskPartitionDictServiceImpl implements ITaskPartitionDictService {
|
||||
*/
|
||||
@Override
|
||||
public List<TaskPartitionDict> selectTaskPartitionDictList(TaskPartitionDict taskPartitionDict) {
|
||||
return taskPartitionDictMapper.selectTaskPartitionDictList(taskPartitionDict);
|
||||
List<TaskPartitionDict> taskPartitionDicts = taskPartitionDictMapper.selectTaskPartitionDictList(taskPartitionDict);
|
||||
List<SysDictData> sysDictDataList = sysDictDataMapper.selectDictDataByType("task_node_type");
|
||||
for (TaskPartitionDict partitionDict : taskPartitionDicts) {
|
||||
SysDictData sysDictData = sysDictDataList.stream().filter(Objects::nonNull).filter(item -> item.getDictValue().equals(partitionDict.getTaskNodeType())).findFirst().orElse(new SysDictData());
|
||||
if (StringUtils.isNotBlank(sysDictData.getDictLabel())){
|
||||
partitionDict.setTaskNodeType(sysDictData.getDictLabel());
|
||||
}
|
||||
}
|
||||
return taskPartitionDicts;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -37,6 +37,8 @@ public class ManualFollowUpVO {
|
||||
@ApiModelProperty(value = "管理路径节点名称,出院后:AFTER_DISCHARGE,入院后:AFTER_ADMISSION,就诊后:AFTER_CONSULTATION,就诊/出院后:AFTER_VISIT_DISCHARGE,术前:PREOPERATIVE,术后:POSTOPERATIVE")
|
||||
private String routeNodeName;
|
||||
|
||||
private String routeNode;
|
||||
|
||||
@ApiModelProperty(value = "管理路径节点时间,时间单位为:天")
|
||||
private Integer routeNodeDay;
|
||||
|
||||
@ -146,6 +148,8 @@ public class ManualFollowUpVO {
|
||||
@ApiModelProperty(value = "任务节点类型,电话外呼:PHONE_OUTBOUND,问卷量表:QUESTIONNAIRE_SCALE,宣教文章:PROPAGANDA_ARTICLE,文字提醒:TEXT_REMIND")
|
||||
private String taskNodeType;
|
||||
|
||||
private String taskNodeTypeName;
|
||||
|
||||
/**
|
||||
* AI:自动 或 COMMON:手动
|
||||
*/
|
||||
|
||||
Loading…
Reference in New Issue
Block a user