Commit 67029526 authored by 何龙龙's avatar 何龙龙

Merge remote-tracking branch 'origin/master'

# Conflicts: # apply/apply-service/src/main/java/com/hungraim/ism/service/impl/DisableServiceImpl.java # assessment/assessment-service/src/main/java/com/hungraim/ltc/controller/DisableEvaluateController.java # common/common-core/src/main/java/com/hungraim/ltc/pojo/entity/disable/ChDisableApply.java # common/common-core/src/main/java/com/hungraim/ltc/pojo/entity/disable/ChDisableEvaluate.java # common/common-core/src/main/java/com/hungraim/ltc/pojo/entity/disable/ChDisableInfo.java
parents b55f439d 17d2d250
package com.hungraim.ism; package com.hungraim.ism;
import com.baomidou.mybatisplus.core.incrementer.IKeyGenerator;
import com.baomidou.mybatisplus.extension.incrementer.OracleKeyGenerator;
import org.springframework.boot.SpringApplication; import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication; import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient; import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.context.annotation.Bean;
/** /**
* 申请服务 * 申请服务
...@@ -16,4 +19,14 @@ public class ApplyApplication { ...@@ -16,4 +19,14 @@ public class ApplyApplication {
public static void main(String[] args) { public static void main(String[] args) {
SpringApplication.run(ApplyApplication.class, args); SpringApplication.run(ApplyApplication.class, args);
} }
/**
* 注册oracle生成器
* @return 返回mybatis-plus默认的oracle生成器
*/
@Bean
public IKeyGenerator getKeyGenerator() {
return new OracleKeyGenerator();
}
} }
package com.hungraim.ism.controller; package com.hungraim.ism.controller;
import cn.hutool.core.util.StrUtil;
import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.core.metadata.IPage;
import com.hungraim.ism.pojo.vo.disable.DisableExamineInfoVO; import com.hungraim.ism.pojo.vo.disable.DisableExamineInfoVO;
import com.hungraim.ism.pojo.vo.disable.DisableVO; import com.hungraim.ism.pojo.vo.disable.DisableVO;
...@@ -80,10 +81,23 @@ public class DisableController { ...@@ -80,10 +81,23 @@ public class DisableController {
} }
/** /**
* 查询护理机构下所有子机构id
*
* @param organId 机构id
* @return 机构及所有子机构id,以逗号分隔,如果没有子机构则只返回机构id
*/
@RequestMapping("/subsidiariesOrganId")
public Result<String> subsidiariesOrganId(String organId) {
if (StrUtil.isBlank(organId)) {
return Result.failed("organId不能为空!");
}
return Result.success(disableService.subsidiariesOrganId(organId));
}
/**
* 失能人员信息列表 * 失能人员信息列表
* *
* @param organId 适用机构代码 * @param organId 适用机构代码
* @param isIncludeSubsidiaries 是否包含子机构 0包含,1不包含
* @param districtProvincial 所在省 * @param districtProvincial 所在省
* @param districtCity 所在市 * @param districtCity 所在市
* @param districtArea 所在区域 * @param districtArea 所在区域
...@@ -96,11 +110,11 @@ public class DisableController { ...@@ -96,11 +110,11 @@ public class DisableController {
* @return 失能人员信息列表 * @return 失能人员信息列表
*/ */
@RequestMapping("/disableList") @RequestMapping("/disableList")
public Result<List<DisableVO>> disableList(String organId, String districtProvincial, String isIncludeSubsidiaries, public Result<List<DisableVO>> disableList(String organId, String districtProvincial,
String districtCity, String districtArea, String districtCity, String districtArea,
String realName, String certiCode, String dataFrom, String realName, String certiCode, String dataFrom,
String srvOrganName, int pageNum, int pageSize) { String srvOrganName, int pageNum, int pageSize) {
IPage<DisableVO> iPage = disableService.disableList(organId, isIncludeSubsidiaries, districtProvincial, IPage<DisableVO> iPage = disableService.disableList(organId, districtProvincial,
districtCity, districtArea, realName, certiCode, dataFrom, srvOrganName, pageNum, pageSize); districtCity, districtArea, realName, certiCode, dataFrom, srvOrganName, pageNum, pageSize);
return Result.success(iPage.getRecords()); return Result.success(iPage.getRecords());
} }
...@@ -133,6 +147,18 @@ public class DisableController { ...@@ -133,6 +147,18 @@ public class DisableController {
} }
/** /**
* 修改失能申请
*/
@RequestMapping("/updateDisable")
public Result updateDisable(ChDisableApply chDisableApply) {
if (chDisableApply.getApplyId() == null) {
return Result.failed("请求参数错误");
}
disableService.updateDisable(chDisableApply);
return Result.success();
}
/**
* 新增失能申请 * 新增失能申请
*/ */
@RequestMapping("/addDisable") @RequestMapping("/addDisable")
......
package com.hungraim.ism.dao;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.hungraim.ltc.pojo.entity.eval.ChAprTask;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;
/**
* 失能评定Mapper
*
* @author czz
*/
@Mapper
@Repository
public interface AprTaskMapper extends BaseMapper<ChAprTask> {
}
package com.hungraim.ism.dao;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.hungraim.ltc.pojo.entity.disable.ChDisableApplyHis;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;
@Repository
@Mapper
public interface DisableApplyHisMapper extends BaseMapper<ChDisableApplyHis> {
}
...@@ -22,22 +22,21 @@ public interface DisableApplyMapper extends BaseMapper<ChDisableApply> { ...@@ -22,22 +22,21 @@ public interface DisableApplyMapper extends BaseMapper<ChDisableApply> {
/** /**
* 查询待遇申请管理列表 * 查询待遇申请管理列表
* *
* @param organIds 机构代码集合 * @param organIds 机构代码集合
* @param isIncludeSubsidiaries 是否包含子机构 0包含,1不包含 * @param provincial 省
* @param provincial 省 * @param city 市
* @param city 市 * @param area 区
* @param area 区 * @param name 参保人员姓名
* @param name 参保人员姓名 * @param certiCode 参保人身份证号码
* @param certiCode 参保人身份证号码 * @param dataFrom 申请来源
* @param dataFrom 申请来源 * @param srvOrganName 护理机构
* @param srvOrganName 护理机构
*/ */
Page<DisableVO> disableList(Page<DisableVO> page, List<String> organIds, String isIncludeSubsidiaries, String provincial, Page<DisableVO> disableList(Page<DisableVO> page, List<String> organIds, String provincial,
String city, String area, String name, String certiCode, String city, String area, String name, String certiCode,
String dataFrom, String srvOrganName); String dataFrom, String srvOrganName);
DisableExamineInfoVO selectDisableExamineInfoByApplyId(String applyId); DisableExamineInfoVO selectDisableExamineInfoByApplyId(String applyId);
List<ExamineRecord> listExamineRecordByApplyId(String applyHisId); List<ExamineRecord> listExamineRecordByApplyId(String applyId);
} }
package com.hungraim.ism.dao;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.hungraim.ltc.pojo.entity.disable.ChDisableInfo;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;
/**
* 失能人员信息Mapper
*
* @author czz
*/
@Mapper
@Repository
public interface DisableInfoMapper extends BaseMapper<ChDisableInfo> {
}
...@@ -21,7 +21,6 @@ public interface DisableService { ...@@ -21,7 +21,6 @@ public interface DisableService {
* 查询所有资源对应的角色 * 查询所有资源对应的角色
* *
* @param organId 适用机构代码 * @param organId 适用机构代码
* @param isIncludeSubsidiaries 是否包含子机构 0包含,1不包含
* @param districtProvincial 所在省 * @param districtProvincial 所在省
* @param districtCity 所在市 * @param districtCity 所在市
* @param districtArea 所在区域 * @param districtArea 所在区域
...@@ -33,7 +32,7 @@ public interface DisableService { ...@@ -33,7 +32,7 @@ public interface DisableService {
* @param pageSize 每页几条数据 * @param pageSize 每页几条数据
* @return list * @return list
*/ */
Page<DisableVO> disableList(String organId, String isIncludeSubsidiaries, String districtProvincial, String districtCity, Page<DisableVO> disableList(String organId, String districtProvincial, String districtCity,
String districtArea, String realName, String certiCode, String dataFrom, String districtArea, String realName, String certiCode, String dataFrom,
String srvOrganId, int pageNum, int pageSize); String srvOrganId, int pageNum, int pageSize);
...@@ -77,4 +76,14 @@ public interface DisableService { ...@@ -77,4 +76,14 @@ public interface DisableService {
* @param parDiseTypeId 父疾病类型id * @param parDiseTypeId 父疾病类型id
*/ */
List<ChFndDiseaseType> fndDiseaseList(String parDiseTypeId); List<ChFndDiseaseType> fndDiseaseList(String parDiseTypeId);
/**
* 查询护理机构下所有子机构id
*
* @param organId 机构id
* @return 机构及所有子机构id,以逗号分隔,如果没有子机构则只返回机构id
*/
String subsidiariesOrganId(String organId);
void updateDisable(ChDisableApply chDisableApply);
} }
package com.hungraim.ism.service.impl; package com.hungraim.ism.service.impl;
import cn.hutool.core.bean.BeanUtil;
import cn.hutool.core.util.StrUtil; import cn.hutool.core.util.StrUtil;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
...@@ -9,12 +10,15 @@ import com.hungraim.ism.pojo.vo.disable.DisableVO; ...@@ -9,12 +10,15 @@ import com.hungraim.ism.pojo.vo.disable.DisableVO;
import com.hungraim.ism.pojo.vo.disable.ExamineRecord; import com.hungraim.ism.pojo.vo.disable.ExamineRecord;
import com.hungraim.ism.service.DisableService; import com.hungraim.ism.service.DisableService;
import com.hungraim.ltc.pojo.entity.disable.*; import com.hungraim.ltc.pojo.entity.disable.*;
import com.hungraim.ltc.pojo.entity.serviceManage.ChSrvProgram; import com.hungraim.ltc.pojo.entity.eval.ChAprTask;
import org.apache.commons.lang.StringUtils; import org.apache.commons.lang.StringUtils;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.Arrays;
import java.util.Date;
import java.util.List; import java.util.List;
@Service @Service
...@@ -34,6 +38,12 @@ public class DisableServiceImpl implements DisableService { ...@@ -34,6 +38,12 @@ public class DisableServiceImpl implements DisableService {
private SrvOrganMapper srvOrganMapper; private SrvOrganMapper srvOrganMapper;
@Autowired @Autowired
private FndDiseaseTypeMapper fndDiseaseTypeMapper; private FndDiseaseTypeMapper fndDiseaseTypeMapper;
@Autowired
private DisableApplyHisMapper disableApplyHisMapper;
@Autowired
private DisableInfoMapper disableInfoMapper;
@Autowired
private AprTaskMapper aprTaskMapper;
/** /**
* 获取机构ids * 获取机构ids
...@@ -59,21 +69,15 @@ public class DisableServiceImpl implements DisableService { ...@@ -59,21 +69,15 @@ public class DisableServiceImpl implements DisableService {
@Override @Override
public Page<DisableVO> disableList(String organId, String isIncludeSubsidiaries, String districtProvincial, String districtCity, public Page<DisableVO> disableList(String organId, String districtProvincial, String districtCity,
String districtArea, String realName, String certiCode, String dataFrom, String districtArea, String realName, String certiCode, String dataFrom,
String srvOrganName, int page, int pageSize) { String srvOrganName, int page, int pageSize) {
// 没有organId参数的时候,这个集合就为null // 没有organId参数的时候,这个集合就为null
List<String> organIds = null; List<String> organIds = null;
if (StrUtil.isNotBlank(organId)) { if (StrUtil.isNotBlank(organId)) {
organIds = new ArrayList<>(); organIds = Arrays.asList(organId.split(","));
// 先把最顶层id添加到集合
organIds.add(organId);
// 获取子孙机构集合`
if ("0".equals(isIncludeSubsidiaries)) {
this.getOrganList(organId, organIds);
}
} }
return disableApplyMapper.disableList(new Page<>(page, pageSize), organIds, isIncludeSubsidiaries, districtProvincial, return disableApplyMapper.disableList(new Page<>(page, pageSize), organIds, districtProvincial,
districtCity, districtArea, realName, certiCode, dataFrom, srvOrganName); districtCity, districtArea, realName, certiCode, dataFrom, srvOrganName);
} }
...@@ -93,9 +97,33 @@ public class DisableServiceImpl implements DisableService { ...@@ -93,9 +97,33 @@ public class DisableServiceImpl implements DisableService {
@Override @Override
public void disableExamine(String applyId, String checkName, Short applyStatus, String checkRemark) { public void disableExamine(String applyId, String checkName, Short applyStatus, String checkRemark) {
ChDisableApply chDisableApply = disableApplyMapper.selectById(applyId); ChDisableApply chDisableApply = disableApplyMapper.selectById(applyId);
chDisableApply.setCheckName(checkName); Date date = new Date();
chDisableApply.setApplyStatus(applyStatus); ChDisableApplyHis chDisableApplyHis = new ChDisableApplyHis();
chDisableApply.setCheckRemark(checkRemark); BeanUtils.copyProperties(chDisableApply, chDisableApplyHis);
chDisableApplyHis.setCheckName(checkName);
chDisableApplyHis.setApplyStatus(applyStatus);
chDisableApplyHis.setCheckRemark(checkRemark);
chDisableApplyHis.setCheckTime(date);
if (applyStatus.equals(Short.valueOf("2"))) {
// 审核通过
chDisableApply.setCheckName(checkName);
chDisableApply.setApplyStatus(applyStatus);
chDisableApply.setCheckRemark(checkRemark);
chDisableApply.setCheckTime(date);
disableApplyMapper.updateById(chDisableApply);
//添加失能人员信息
ChDisableInfo chDisableInfo = new ChDisableInfo();
BeanUtil.copyProperties(chDisableApply, chDisableInfo);
disableInfoMapper.insert(chDisableInfo);
//添加失能评定信息
ChAprTask chAprTask = new ChAprTask();
BeanUtil.copyProperties(chDisableApply, chAprTask);
aprTaskMapper.insert(chAprTask);
}
disableApplyHisMapper.insert(chDisableApplyHis);
} }
@Override @Override
...@@ -160,4 +188,22 @@ public class DisableServiceImpl implements DisableService { ...@@ -160,4 +188,22 @@ public class DisableServiceImpl implements DisableService {
return fndDiseaseTypeMapper.selectList(queryWrapper); return fndDiseaseTypeMapper.selectList(queryWrapper);
} }
@Override
public String subsidiariesOrganId(String organId) {
List<String> organIds = new ArrayList<>();
organIds.add(organId);
// 获取子孙机构集合
this.getOrganList(organId, organIds);
StringBuilder sb = new StringBuilder();
for (String o : organIds) {
sb.append(o).append(",");
}
sb.deleteCharAt(sb.length() - 1);
return sb.toString();
}
@Override
public void updateDisable(ChDisableApply chDisableApply) {
disableApplyMapper.updateById(chDisableApply);
}
} }
\ No newline at end of file
...@@ -6,9 +6,9 @@ ...@@ -6,9 +6,9 @@
select a.APPLY_ID applyId, select a.APPLY_ID applyId,
o.ORGAN_NAME organName, o.ORGAN_NAME organName,
a.organ_id organId, a.organ_id organId,
a.DISTRICT_PROVINCIAL provincial, (select DISTRICT_NAME from CH_FND_DISTRICT dis where a.DISTRICT_PROVINCIAL = dis.DISTRICT_CODE) provincial,
a.DISTRICT_CITY city, (select DISTRICT_NAME from CH_FND_DISTRICT dis where a.DISTRICT_CITY = dis.DISTRICT_CODE) city,
a.DISTRICT_AREA area, (select DISTRICT_NAME from CH_FND_DISTRICT dis where a.DISTRICT_AREA = dis.DISTRICT_CODE) area,
a.REAL_NAME name, a.REAL_NAME name,
a.birthday birthday, a.birthday birthday,
a.CERTI_CODE certiCode, a.CERTI_CODE certiCode,
...@@ -29,9 +29,9 @@ ...@@ -29,9 +29,9 @@
LEFT JOIN CH_SRV_ORGAN s ON a.SRV_ORGAN_ID = s.SRV_ORGAN_ID LEFT JOIN CH_SRV_ORGAN s ON a.SRV_ORGAN_ID = s.SRV_ORGAN_ID
<where> <where>
<if test="organIds != null"> <if test="organIds != null">
and a.organ_id in and a.organ_id in
<foreach collection="organIds" item="organId" open="(" close=")" separator=","> <foreach collection="organIds" item="organId" open="(" close=")" separator=",">
#{organId} #{organId}
</foreach> </foreach>
</if> </if>
<if test="provincial != null and provincial != ''"> <if test="provincial != null and provincial != ''">
...@@ -59,12 +59,12 @@ ...@@ -59,12 +59,12 @@
</select> </select>
<select id="selectDisableExamineInfoByApplyId" resultType="com.hungraim.ism.pojo.vo.disable.DisableExamineInfoVO"> <select id="selectDisableExamineInfoByApplyId" resultType="com.hungraim.ism.pojo.vo.disable.DisableExamineInfoVO">
select a.organ_id organId, select a.APPLY_ID applyId,
(select o1.organ_name from CH_FND_ORGAN o1 where a.organ_id = o1.organ_code) organName, a.organ_id organId,
a.DISTRICT_PROVINCIAL provincial, a.DISTRICT_PROVINCIAL districtProvincial,
a.DISTRICT_CITY city, a.DISTRICT_CITY districtCity,
a.DISTRICT_AREA area, a.DISTRICT_AREA districtArea,
a.REAL_NAME name, a.REAL_NAME realName,
a.CERTI_CODE certiCode, a.CERTI_CODE certiCode,
a.BIRTHDAY birthday, a.BIRTHDAY birthday,
a.GENDER gender, a.GENDER gender,
...@@ -81,15 +81,18 @@ ...@@ -81,15 +81,18 @@
a.ACPT_SRV_CITY acptSrvCity, a.ACPT_SRV_CITY acptSrvCity,
a.ACPT_SRV_AREA acptSrvArea, a.ACPT_SRV_AREA acptSrvArea,
a.ACPT_SRV_STREET acptSrvStreet, a.ACPT_SRV_STREET acptSrvStreet,
a.ACPT_SRV_ROAD_DETAIL acptSrvRoadDetail, a.ACPT_SRV_ADDRESS acptSrvAddress,
a.ACPT_SRV_TYPE acptSrvType,
a.ADRESS_DISTRICT_PROVINCIAL adressDistrictProvincial, a.ADRESS_DISTRICT_PROVINCIAL adressDistrictProvincial,
a.ADRESS_DISTRICT_CITY adressDistrictCity, a.ADRESS_DISTRICT_CITY adressDistrictCity,
a.ADRESS_DISTRICT_CODE adressDistrictCode, a.ADRESS_DISTRICT_CODE adressDistrictCode,
a.ADDRESS_ROAD_DETAIL addressRoadDetail, a.STREET street,
a.ADDRESS_NUMBER_DETAIL addressNumberDetail, a.ADRESS_DETAIL adressDetail,
a.ADDRESS_TYPE addressType,
a.DISEASE disease, a.DISE_TYPE_F diseTypeF,
a.APPLY_METHOD applyMethod, a.DISE_TYPE_S diseTypeS,
a.SRV_MODE_ID srvModeId,
a.DISEASE_DESC diseaseDesc, a.DISEASE_DESC diseaseDesc,
a.MEDICAL_CARD medicalCard, a.MEDICAL_CARD medicalCard,
a.MEDICAL_TYPE medicalType, a.MEDICAL_TYPE medicalType,
...@@ -111,19 +114,19 @@ ...@@ -111,19 +114,19 @@
a.APPLY_STATUS applyStatus, a.APPLY_STATUS applyStatus,
a.CHECK_REMARK checkRemark a.CHECK_REMARK checkRemark
from CH_DISABLE_APPLY a from CH_DISABLE_APPLY a
LEFT JOIN CH_SRV_ORGAN o ON a.SRV_ORGAN_ID = o.organ_code LEFT JOIN CH_SRV_ORGAN o ON a.SRV_ORGAN_ID = o.SRV_ORGAN_ID
where a.APPLY_ID = #{applyId} where a.APPLY_ID = #{applyId}
order by APPLY_ID desc order by APPLY_ID desc
</select> </select>
<select id="listExamineRecordByApplyId" resultType="com.hungraim.ism.pojo.vo.disable.ExamineRecord"> <select id="listExamineRecordByApplyId" resultType="com.hungraim.ism.pojo.vo.disable.ExamineRecord">
select CHECK_TIME checkTime, select CHECK_TIME checkTime,
TREATMENT_TYPE city, TREATMENT_TYPE teratmentType,
APPLY_STATUS status, APPLY_STATUS status,
CHECK_NAME name, CHECK_NAME name,
CHECK_REMARK certiCode CHECK_REMARK remark
from CH_DISABLE_APPLY_HIS from CH_DISABLE_APPLY_HIS
where APPLY_ID = #{applyHisId} where APPLY_ID = #{applyId}
</select> </select>
</mapper> </mapper>
\ No newline at end of file
package com.hungraim.ltc.controller;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.hungraim.ism.pojo.vo.disable.DisableEvaluateInfoVO;
import com.hungraim.ism.pojo.vo.disable.DisableEvaluateVO;
import com.hungraim.ltc.pojo.entity.disable.ChDisableEvaluate;
import com.hungraim.ltc.service.DisableEvaluateService;
import com.hungraim.ltc.util.Result;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import java.util.List;
/**
* 失能评定Controller
*
* @author czz
*/
@RestController
@RequestMapping("/api.apply/disableEvaluate")
@Slf4j
public class DisableEvaluateController {
@Autowired
private DisableEvaluateService disableEvaluateService;
/**
* 失能评定列表
*
* @param organId 适用机构代码
* @param srvOrganId 护理机构
* @param realName 失能人员姓名
* @param certiCode 失能人员身份证号码
* @param pageNum 当前页
* @param pageSize 每页几条数据
* @return 失能评定列表
*/
@RequestMapping("/disableEvaluateList")
public Result<List<DisableEvaluateVO>> disableEvaluateList(String organId, String srvOrganId, String realName, String certiCode, int pageNum, int pageSize) {
IPage<DisableEvaluateVO> iPage = disableEvaluateService.disableEvaluateList(organId, realName, certiCode, srvOrganId, pageNum, pageSize);
return Result.success(iPage.getRecords());
}
/**
* 失能评定详情
*
* @param evaluateId 评定id
* @return 失能审核信息详情
*/
@RequestMapping("/disableEvaluateInfo")
public Result<DisableEvaluateInfoVO> disableEvaluateInfo(String evaluateId) {
DisableEvaluateInfoVO disableEvaluateInfoVO = disableEvaluateService.disableEvaluateInfo(evaluateId);
return Result.success(disableEvaluateInfoVO);
}
/**
* 失能评定
*
* @param applyId 申请id
* @param checkName 审核人
* @param applyStatus 审核结果
* @param checkRemark 审核备注
* @return 失能审核信息详情
*/
@RequestMapping("/disableEvaluate")
public Result disableEvaluate(String applyId, String checkName, Short applyStatus, String checkRemark) {
//disableEvaluateService.disableExamine(applyId, checkName, applyStatus, checkRemark);
return Result.success();
}
/**
* 新增失能申请
*/
@RequestMapping("/addDisableEvaluate")
public Result addEvaluate(ChDisableEvaluate chDisableEvaluate) {
return Result.success();
}
}
package com.hungraim.ltc.controller;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.hungraim.ltc.pojo.entity.eval.ChAprEmp;
import com.hungraim.ltc.pojo.entity.eval.ChAprReport;
import com.hungraim.ltc.pojo.vo.assessment.TaskDistributionVO;
import com.hungraim.ltc.pojo.vo.assessment.TaskReportVO;
import com.hungraim.ltc.service.TaskService;
import com.hungraim.ltc.util.Result;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import java.util.Date;
import java.util.List;
/**
* 失能评定Controller
*
* @author czz
*/
@RestController
@RequestMapping("/api.assessment/task")
@Slf4j
public class TaskController {
@Autowired
private TaskService taskService;
/**
* 评定任务分配、查询列表
*
* @param organId 适用机构代码
* @param provincial 所在省
* @param city 所在市
* @param area 所在区域
* @param street 所在街道
* @param realName 失能人员姓名
* @param certiCode 失能人员身份证号码
* @param taskName 评定人员姓名
* @param taskTel 评定人员手机号码
* @param daysRemaining 评定剩余天数
* @param status 任务状态
* @param isReturn 是否退回
* @param pageNum 当前页
* @param pageSize 每页几条数据
*/
@RequestMapping("/taskDistributionList")
public Result<List<TaskDistributionVO>> taskDistributionList(String organId, String provincial, String city,
String street, String realName, String certiCode, String taskName, String taskTel,
String daysRemaining, String status, String isReturn, String area,
int pageNum, int pageSize) {
IPage<TaskDistributionVO> iPage = taskService.taskDistributionList(organId, provincial, city,
street, realName, certiCode, taskName, taskTel, daysRemaining, status, isReturn, area,
pageNum, pageSize);
return Result.success(iPage.getRecords());
}
/**
* 评定报告录入列表
*/
@RequestMapping("/taskReportList")
public Result<List<TaskReportVO>> taskReportList() {
List<TaskReportVO> taskReportList = taskService.taskReportList();
return Result.success(taskReportList);
}
/**
* 查询失能人员列表
*/
@RequestMapping("/aprEmpList")
public Result<List<ChAprEmp>> aprEmpList() {
List<ChAprEmp> chAprEmps = taskService.aprEmpList();
return Result.success(chAprEmps);
}
/**
* 评定报告新增
*/
@RequestMapping("/addReport")
public Result addReport(@RequestBody ChAprReport chAprReport) {
chAprReport.setEffTime(new Date());
taskService.addReport(chAprReport);
return Result.success();
}
}
package com.hungraim.ltc.dao; package com.hungraim.ltc.dao;
import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.hungraim.ltc.pojo.entity.eval.ChAprEmp;
import com.hungraim.ism.pojo.vo.disable.DisableEvaluateInfoVO;
import com.hungraim.ism.pojo.vo.disable.DisableEvaluateVO;
import com.hungraim.ism.pojo.vo.disable.DisableVO;
import com.hungraim.ltc.pojo.entity.disable.ChDisableEvaluate;
import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository; import org.springframework.stereotype.Repository;
/** /**
* 失能人员申请历史Mapper * 失能评定人员Mapper
* *
* @author czz * @author czz
*/ */
@Mapper @Mapper
@Repository @Repository
public interface DisableEvaluateMapper extends BaseMapper<ChDisableEvaluate> { public interface AprEmpMapper extends BaseMapper<ChAprEmp> {
/**
* 查询失能评定列表
*
* @param organId 适用机构代码
* @param srvOrganId 护理机构
* @param realName 失能人员姓名
* @param certiCode 失能人员身份证号码
*/
Page<DisableEvaluateVO> disableEvaluateList(Page<DisableVO> page, String organId, String srvOrganId, String realName, String certiCode);
DisableEvaluateInfoVO selectDisableEvaluateInfoByEvaluateId(String evaluateId);
} }
package com.hungraim.ltc.dao;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.hungraim.ltc.pojo.entity.eval.ChAprReport;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;
/**
* 失能评定报告Mapper
*
* @author czz
*/
@Mapper
@Repository
public interface AprReportMapper extends BaseMapper<ChAprReport> {
}
package com.hungraim.ltc.dao;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.hungraim.ltc.pojo.entity.eval.ChAprTask;
import com.hungraim.ltc.pojo.vo.assessment.TaskDistributionVO;
import com.hungraim.ltc.pojo.vo.assessment.TaskReportVO;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;
import java.util.List;
/**
* 失能评定Mapper
*
* @author czz
*/
@Mapper
@Repository
public interface TaskMapper extends BaseMapper<ChAprTask> {
/**
* 评定任务分配列表
*
* @param organIds 适用机构代码
* @param provincial 所在省
* @param city 所在市
* @param area 所在区域
* @param street 所在街道
* @param realName 失能人员姓名
* @param certiCode 失能人员身份证号码
* @param taskName 评定人员姓名
* @param taskTel 评定人员手机号码
* @param daysRemaining 评定剩余天数
* @param status 任务状态
* @param isReturn 是否退回
*/
Page<TaskDistributionVO> taskDistributionList(Page<TaskDistributionVO> page, List<String> organIds, String provincial, String city,
String street, String realName, String certiCode, String taskName, String taskTel,
String daysRemaining, String status, String isReturn, String area);
/**
* 评定报告录入
*/
List<TaskReportVO> taskReportList();
}
package com.hungraim.ltc.service;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.hungraim.ism.pojo.vo.disable.DisableEvaluateInfoVO;
import com.hungraim.ism.pojo.vo.disable.DisableEvaluateVO;
import com.hungraim.ltc.pojo.entity.disable.ChDisableEvaluate;
import org.springframework.stereotype.Service;
/**
* 失能申请Service
*
* @author czz
*/
@Service
public interface DisableEvaluateService {
/**
* 失能评定列表
*
* @param organId 适用机构代码
* @param srvOrganId 护理机构
* @param realName 失能人员姓名
* @param certiCode 失能人员身份证号码
* @param pageNum 当前页
* @param pageSize 每页几条数据
* @return
*/
IPage<DisableEvaluateVO> disableEvaluateList(String organId, String srvOrganId, String realName, String certiCode, int pageNum, int pageSize);
/**
* 失能评定详情
*
* @param evaluateId 评定id
* @return 失能评定详情
*/
DisableEvaluateInfoVO disableEvaluateInfo(String evaluateId);
void addEvaluate(ChDisableEvaluate disableEvaluate);
void disableEvaluate(String applyId, String checkName, Short applyStatus, String checkRemark);
}
package com.hungraim.ltc.service;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.hungraim.ltc.pojo.entity.eval.ChAprEmp;
import com.hungraim.ltc.pojo.entity.eval.ChAprReport;
import com.hungraim.ltc.pojo.vo.assessment.TaskDistributionVO;
import com.hungraim.ltc.pojo.vo.assessment.TaskReportVO;
import org.springframework.stereotype.Service;
import java.util.List;
/**
* 失能评定Service
*
* @author czz
*/
@Service
public interface TaskService {
/**
* 评定任务分配列表
*
* @param organId 适用机构代码
* @param provincial 所在省
* @param city 所在市
* @param area 所在区域
* @param street 所在街道
* @param realName 失能人员姓名
* @param certiCode 失能人员身份证号码
* @param taskName 评定人员姓名
* @param taskTel 评定人员手机号码
* @param daysRemaining 评定剩余天数
* @param status 任务状态
* @param isReturn 是否退回
* @param pageNum 当前页
* @param pageSize 每页几条数据
*/
IPage<TaskDistributionVO> taskDistributionList(String organId, String provincial, String city,
String street, String realName, String certiCode, String taskName, String taskTel,
String daysRemaining, String status, String isReturn, String area,
int pageNum, int pageSize);
/**
* 评定报告录入列表
*/
List<TaskReportVO> taskReportList();
List<ChAprEmp> aprEmpList();
void addReport(ChAprReport chAprReport);
}
package com.hungraim.ltc.service.impl;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.hungraim.ism.pojo.vo.disable.DisableEvaluateInfoVO;
import com.hungraim.ism.pojo.vo.disable.DisableEvaluateVO;
import com.hungraim.ltc.dao.DisableEvaluateMapper;
import com.hungraim.ltc.pojo.entity.disable.ChDisableEvaluate;
import com.hungraim.ltc.service.DisableEvaluateService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
@Service
public class DisableEvaluateServiceImpl implements DisableEvaluateService {
@Autowired
private DisableEvaluateMapper disableEvaluateList;
@Override
public IPage<DisableEvaluateVO> disableEvaluateList(String organId, String srvOrganId, String realName, String certiCode, int pageNum, int pageSize) {
return disableEvaluateList.disableEvaluateList(new Page(pageNum, pageSize), organId, realName, certiCode, srvOrganId);
}
@Override
public DisableEvaluateInfoVO disableEvaluateInfo(String evaluateId) {
return disableEvaluateList.selectDisableEvaluateInfoByEvaluateId(evaluateId);
}
@Override
public void addEvaluate(ChDisableEvaluate disableEvaluate) {
disableEvaluateList.insert(disableEvaluate);
}
@Override
public void disableEvaluate(String applyId, String checkName, Short applyStatus, String checkRemark) {
/*ChDisableApply chDisableApply = disableEvaluateList.selectById(applyId);
chDisableApply.setCheckName(checkName);
chDisableApply.setApplyStatus(applyStatus);
chDisableApply.setCheckRemark(checkRemark);*/
}
}
\ No newline at end of file
package com.hungraim.ltc.service.impl;
import cn.hutool.core.util.StrUtil;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.hungraim.ltc.dao.AprEmpMapper;
import com.hungraim.ltc.dao.AprReportMapper;
import com.hungraim.ltc.dao.TaskMapper;
import com.hungraim.ltc.pojo.entity.eval.ChAprEmp;
import com.hungraim.ltc.pojo.entity.eval.ChAprReport;
import com.hungraim.ltc.pojo.vo.assessment.TaskDistributionVO;
import com.hungraim.ltc.pojo.vo.assessment.TaskReportVO;
import com.hungraim.ltc.service.TaskService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.Arrays;
import java.util.List;
/**
* @author czz
*/
@Service
public class TaskServiceImpl implements TaskService {
@Autowired
private TaskMapper taskMapper;
@Autowired
private AprEmpMapper aprEmpMapper;
@Autowired
private AprReportMapper aprReportMapper;
@Override
public IPage<TaskDistributionVO> taskDistributionList(String organId, String provincial, String city,
String street, String realName, String certiCode, String taskName, String taskTel,
String daysRemaining, String status, String isReturn, String area,
int pageNum, int pageSize) {
List<String> organIds = null;
if (StrUtil.isNotBlank(organId)) {
organIds = Arrays.asList(organId.split(","));
}
return taskMapper.taskDistributionList(new Page<>(pageNum, pageSize), organIds, provincial, city,
street, realName, certiCode, taskName, taskTel, daysRemaining, status, isReturn, area);
}
@Override
public List<TaskReportVO> taskReportList() {
return taskMapper.taskReportList();
}
@Override
public List<ChAprEmp> aprEmpList() {
return aprEmpMapper.selectList(new QueryWrapper<ChAprEmp>().eq("IS_LOCK", 0));
}
@Override
public void addReport(ChAprReport chAprReport) {
aprReportMapper.insert(chAprReport);
}
}
\ No newline at end of file
package com.hungraim.ism.pojo.vo.disable; package com.hungraim.ism.pojo.vo.disable;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import java.util.Date; import java.util.Date;
@Data
public class ExamineRecord { public class ExamineRecord {
//审核时间 //审核时间
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date checkTime; private Date checkTime;
//申请类型 //申请类型
private String city; private String teratmentType;
//审核结果 //审核结果
private String status; private String status;
//审核人 //审核人
private String name; private String name;
//备注 //备注
private String certiCode; private String remark;
public Date getCheckTime() {
return checkTime;
}
public void setCheckTime(Date checkTime) {
this.checkTime = checkTime;
}
public String getCity() {
return city;
}
public void setCity(String city) {
this.city = city;
}
public String getStatus() {
return status;
}
public void setStatus(String status) {
this.status = status;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getCertiCode() {
return certiCode;
}
public void setCertiCode(String certiCode) {
this.certiCode = certiCode;
}
} }
package com.hungraim.ltc.pojo.entity.disable; package com.hungraim.ltc.pojo.entity.disable;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.KeySequence;
import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName; import com.baomidou.mybatisplus.annotation.TableName;
import com.hungraim.ltc.constant.AssignStatus;
import com.hungraim.ltc.pojo.entity.PageInfo;
import lombok.Data; import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat; import org.springframework.format.annotation.DateTimeFormat;
...@@ -16,15 +16,15 @@ import java.util.Date; ...@@ -16,15 +16,15 @@ import java.util.Date;
*/ */
@Data @Data
@TableName("CH_DISABLE_APPLY") @TableName("CH_DISABLE_APPLY")
public class ChDisableApply extends PageInfo implements Serializable { @KeySequence(value = "SEQ_CH_DISABLE_APPLY")
public class ChDisableApply implements Serializable {
/** /**
* 失能申请id * 失能申请id
*/ */
@TableId("apply_id") @TableId(value = "APPLY_ID", type = IdType.INPUT)
private Long applyId; private Long applyId;
/** /**
* 机构代码 * 机构代码
*/ */
...@@ -583,16 +583,6 @@ public class ChDisableApply extends PageInfo implements Serializable { ...@@ -583,16 +583,6 @@ public class ChDisableApply extends PageInfo implements Serializable {
private String medicalHistory; private String medicalHistory;
/** /**
* 历史操作时间
*/
//private Date hisTime;
/**
* 历史操作人
*/
// private Long hisEmp;
/**
* 代办人固话 * 代办人固话
*/ */
private String operFixedTel; private String operFixedTel;
......
package com.hungraim.ltc.pojo.entity.disable; package com.hungraim.ltc.pojo.entity.disable;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.KeySequence;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName; import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data; import lombok.Data;
...@@ -12,10 +15,12 @@ import java.util.Date; ...@@ -12,10 +15,12 @@ import java.util.Date;
*/ */
@Data @Data
@TableName("CH_DISABLE_APPLY_HIS") @TableName("CH_DISABLE_APPLY_HIS")
@KeySequence(value = "SEQ_CH_DISABLE_APPLY_HIS")
public class ChDisableApplyHis implements Serializable { public class ChDisableApplyHis implements Serializable {
/** /**
* 失能申请历史id * 失能申请历史id
*/ */
@TableId(value = "APPLY_HIS_ID", type = IdType.INPUT)
private Long applyHisId; private Long applyHisId;
/** /**
......
package com.hungraim.ltc.pojo.entity.eval;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
@Data
@TableName("CH_APR_EMP")
public class ChAprEmp {
private Integer empId;
private Integer eduId;
private String aprempTypeNameF;
private String certiCode;
private Integer isLock;
private String certifTypeCode;
private String eduCode;
private Integer basicEmpId;
private java.util.Date endTime;
private String gender;
private Integer defineEmp;
private Integer cfgModeId;
private Integer age;
private Integer aprempTypeIdF;
private java.util.Date fcd;
private Integer empType;
private java.util.Date lcd;
private String realName;
private Integer aprempTypeIdS;
private String aprempTypeNameS;
private Integer dataFrom;
private Integer endEmp;
private String address;
private Integer fcu;
private String tel;
private String certifTypeId;
private Integer groupLeader;
private java.util.Date effTime;
private Integer aprOrganId;
private Integer lcu;
}
package com.hungraim.ltc.pojo.entity.eval;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.KeySequence;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
@Data
@TableName("CH_APR_REPORT")
@KeySequence(value = "SEQ_CH_APR_REPORT")
public class ChAprReport {
@TableId(value = "REPORT_ID", type = IdType.INPUT)
private Integer reportId;
private Integer checkName;
private Integer evaluateRatingType;
private Integer status;
private java.util.Date endTime;
private String polNo;
private Integer disableLevelId;
private String evaluationRemark;
private Integer defineEmp;
private Integer cfgModeId;
private java.util.Date evaluateTime;
private String remark;
private java.util.Date publicityStartTime;
private java.util.Date evaluationTime;
private java.util.Date publicityEndTime;
private java.util.Date fcd;
private Integer srvModeId;
private java.util.Date lcd;
private Integer simpleIntelligentScore;
private Integer treatmentType;
private String srvModeName;
private Integer endEmp;
private String publicityRemark;
private Integer fcu;
private Integer cfgAprId;
private String evaluateRating;
private Integer evaluationEmp;
private java.util.Date effTime;
private Integer aprTotalScore;
private String checkRemark;
private Integer taskId;
private Integer lcu;
}
package com.hungraim.ltc.pojo.entity.eval;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
@Data
@TableName("CH_APR_TASK")
public class ChAprTask {
private Integer taskId;
private java.util.Date assignTime;
private Integer taskStatus;
private Integer assignEmp;
private String districtProvincial;
private Integer reAprStatus;
private java.util.Date endTime;
private java.util.Date finishTime;
private String districtArea;
private Integer applyId;
private Integer aprType;
private java.util.Date taskAppointmentDate;
private Integer defineEmp;
private Integer finishEmp;
private java.util.Date fcd;
private Integer acceptEmp;
private java.util.Date acceptTime;
private java.util.Date lcd;
private Integer aprEmpId;
private String organId;
private String districtCity;
private java.util.Date reAprTime;
private Integer endEmp;
private Integer disableInfoId;
private Integer fcu;
private java.util.Date effTime;
private Integer aprOrganId;
private Integer lcu;
private java.util.Date lastAprDate;
private String appointmentRemark;
}
package com.hungraim.ltc.pojo.vo.assessment;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import java.util.Date;
@Data
public class TaskDistributionVO {
//鉴定任务id ch_apr_task
private Integer taskId;
//任务明细id
private Integer applyId;
//适用机构 ch_apr_organ apr_organ_id
private String organName;
//机构代码
private String aprOrganId;
//所在省市区
private String districtProvincial;
private String districPity;
private String districtArea;
//失能人员姓名 ch_disable_info
private String realName;
//申请日期
@JsonFormat(pattern = "yyyy-MM-dd")
private Date fcd;
//失能人员身份证号码
private String certiCode;
//年龄
@JsonFormat(pattern = "yyyy-MM-dd")
private Date birthday;//出生年月
//诊断疾病 CH_FND_DISEASE_TYPE
private String diseTypeF;//大类
private String diseTypeS;//小类
//失能人员联系电话
private String tel;
//接受评定地址
private String acptProvincial;
private String acptCity;
private String acptArea;
//街道
private String acptStreet;
//评定截止日期
private Date endTime;
//评定人员 ch_apr_emp emp_id
private String empRealName;
//评定人员手机号码
private String empTel;
//任务分配时间
@JsonFormat(pattern = "yyyy-MM-dd")
private Date assignTime;
//任务接受时间
@JsonFormat(pattern = "yyyy-MM-dd")
private Date acceptTime;
//任务完成时间
@JsonFormat(pattern = "yyyy-MM-dd")
private Date finishTime;
//任务状态
private Integer taskStatus;
//拒绝原因
private String refuseReason;
//备注
private String refuseRemark;
}
package com.hungraim.ltc.pojo.vo.assessment;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import java.util.Date;
/**
* 评定报告录入列表
*/
@Data
public class TaskReportVO {
//评定id
private String reportId;
//机构id
private String organId;
//机构名
private String organName;
//所在省市区
private String districtProvincial;
private String districPity;
private String districtArea;
//失能人员姓名
private String realName;
//失能人员身份证号码
private String certiCode;
//诊断疾病
private String diseTypeF;
private String diseTypeS;
//失能人员手机号码
private String tel;
//接受评定地址
private String acptProvincial;
private String acptCity;
private String acptArea;
//评定结果
private String riskLevel;
//录入时间
@JsonFormat(pattern = "yyyy-MM-dd")
private Date effTime;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment