Commit 2abf5d7b authored by zhangwanglin's avatar zhangwanglin

Merge branch 'uat_ch_master' into dev_nursing_records_20230214

parents b7acf247 3674b6f9
......@@ -338,8 +338,8 @@ public class BuildBedController {
* @return
*/
@GetMapping("/chPunchDetailsQuery")
public Result chPunchDetailsQuery(Long taskDetailId,String sevStarTime,String sevEndTime){
ChPunchDetailsVO chPunchDetailsVO = buildBedService.chPunchDetailsQuery(taskDetailId,sevStarTime,sevEndTime);
public Result chPunchDetailsQuery(Long taskDetailId,String certiCode,String sevStarTime,String sevEndTime){
ChPunchDetailsVO chPunchDetailsVO = buildBedService.chPunchDetailsQuery(taskDetailId,certiCode,sevStarTime,sevEndTime);
return Result.success(chPunchDetailsVO);
}
......@@ -362,5 +362,4 @@ public class BuildBedController {
}
}
\ No newline at end of file
......@@ -40,7 +40,7 @@ public interface BuildBedMapper extends BaseMapper<ChSrvBuildBed> {
ChPunchDetailsVO getsrvOrgan(Long taskDetailId);
List<ChServiceTypeDetailedVO> getServiceTypeDetailed(@Param("taskDetailId")Long taskDetailId,@Param("sevStarTime")String sevStarTime,@Param("sevEndTime")String sevEndTime);
List<ChServiceTypeDetailedVO> getServiceTypeDetailed(@Param("taskDetailId")Long taskDetailId,@Param("certiCode")String certiCode,@Param("sevStarTime")String sevStarTime,@Param("sevEndTime")String sevEndTime);
List<ChServiceTypeVO> selectServiceTypeDetailed();
}
......@@ -53,5 +53,5 @@ public interface IBuildBedService extends IService<ChSrvBuildBed> {
* 打卡详情
* @param taskDetailId
*/
ChPunchDetailsVO chPunchDetailsQuery(Long taskDetailId,String sevStarTime,String sevEndTime);
ChPunchDetailsVO chPunchDetailsQuery(Long taskDetailId,String certiCode,String sevStarTime,String sevEndTime);
}
......@@ -122,7 +122,7 @@ public class BuildBedServiceImpl extends ServiceImpl<BuildBedMapper, ChSrvBuildB
* @param taskDetailId
*/
@Override
public ChPunchDetailsVO chPunchDetailsQuery(Long taskDetailId, String sevStarTime,String sevEndTime) {
public ChPunchDetailsVO chPunchDetailsQuery(Long taskDetailId,String certiCode, String sevStarTime,String sevEndTime) {
List<ChPunchDetailVO> chPunchDetailVOS = new ArrayList<>();
//获取项目信息
List<ChServiceTypeVO> chServiceTypeDetaileds = buildBedMapper.selectServiceTypeDetailed();
......@@ -144,7 +144,7 @@ public class BuildBedServiceImpl extends ServiceImpl<BuildBedMapper, ChSrvBuildB
}
log.info("chPunchDetailsQuery获取服务机构和服务类型:"+chPunchDetailsVO);
//打卡详情
List<ChServiceTypeDetailedVO> serviceTypeDetailed1s = buildBedMapper.getServiceTypeDetailed(taskDetailId,sevStarTime, sevEndTime);
List<ChServiceTypeDetailedVO> serviceTypeDetailed1s = buildBedMapper.getServiceTypeDetailed(taskDetailId,certiCode,sevStarTime, sevEndTime);
log.info("chPunchDetailsQuery打卡详情:"+serviceTypeDetailed1s);
chPunchDetailsVO.setRecordData(chPunchDetailVOS);
chPunchDetailsVO.setChPunchDetailVOS(serviceTypeDetailed1s);
......
......@@ -27,22 +27,19 @@
<select id="chSrvTaskDetailQuery" parameterType="com.hungraim.ltc.pojo.vo.disable.ChSrvTaskDetailVo"
resultType="com.hungraim.ltc.pojo.vo.disable.ChSrvTaskDetailVo">
SELECT
t.TASK_DETAIL_ID taskDetailId,
mode1.MODE_NAME modeName,----服务方式
select
program.PROGRAM_ID taskDetailId,
mode1.MODE_NAME modeName,
organ.SRV_ORGAN_NAME srvOrganName,--护理机构名称
info.REAL_NAME realName,--失能人员名字
info.CERTI_CODE certiCode,--失能人员身份证件号码
t.SRV_START_TIME sevStarTime,--服务开始时间
t.SRV_END_TIME sevEndTime,--服务结束时间
TO_DATE( '', 'yyyy-MM-dd' ) declarationTime
FROM
CH_SRV_TASK_DETAIL t --服务明细表
LEFT JOIN ch_srv_task task ON task.srv_task_id = t.srv_task_id --服务计划详情
LEFT JOIN CH_DISABLE_INFO info ON task.DISAB_INFO_ID = info.DISAB_INFO_ID --失能人员信息表
LEFT JOIN ch_srv_program program ON task.program_id = program.program_id --服务方案
LEFT JOIN ch_srv_organ organ ON program.srv_organ_id = organ.srv_organ_id --服务机构
program.PROGRAM_DATE sevStarTime,--服务开始时间
program.PROGRAM_EDN_DATE sevEndTime--服务结束时间
from ch_srv_program program
LEFT JOIN ch_cfg_srv_mode mode1 ON program.srv_mode_id = mode1.mode_id --服务方式
LEFT JOIN ch_srv_organ organ ON program.srv_organ_id = organ.srv_organ_id --服务机构
LEFT JOIN ch_srv_task task ON task.PROGRAM_ID = program.PROGRAM_ID --服务计划详情
LEFT JOIN CH_DISABLE_INFO info ON task.DISAB_INFO_ID = info.DISAB_INFO_ID --失能人员信息表
where 1=1
<if test="vo.srvOrganName != null and vo.srvOrganName != ''">
AND organ.SRV_ORGAN_NAME LIKE '%' || #{vo.srvOrganName} || '%'
......@@ -57,43 +54,10 @@
AND info.CERTI_CODE =#{vo.certiCode}
</if>
<if test="vo.sevStarTime != null and vo.sevStarTime != ''">
AND t.SRV_START_TIME &gt;= TO_DATE (#{vo.sevStarTime}, 'yyyy-mm-dd')
</if>
<if test="vo.sevEndTime != null and vo.sevEndTime != ''">
AND t.SRV_END_TIME &lt;= TO_DATE (#{vo.sevEndTime}, 'yyyy-mm-dd')
</if>
UNION
SELECT
d.TASK_DETAIL_ID taskDetailId,
d.MODE_NAME modeName,----服务方式
o.SRV_ORGAN_NAME srvOrganName,--护理机构名称
info.REAL_NAME realName,--失能人员名字
info.CERTI_CODE certiCode,--失能人员身份证件号码
TO_DATE( '', 'yyyy-MM-dd' ) sevStarTime,--服务开始时间
TO_DATE( '', 'yyyy-MM-dd' ) sevEndTime,--服务结束时间
d.DECLARATION_TIME declarationTime--申报日期
FROM
CH_DISAB_ACCOUNTS_DETAIL d --账户信息表
LEFT JOIN CH_DISABLE_INFO info ON d.DISAB_INFO_ID = info.DISAB_INFO_ID --失能人员信息表
LEFT JOIN CH_SRV_ORGAN o ON d.SRV_ORGAN_ID = o.SRV_ORGAN_ID --护理机构表
where 1=1
<if test="vo.srvOrganName != null and vo.srvOrganName != ''">
AND o.SRV_ORGAN_NAME LIKE '%' || #{vo.srvOrganName} || '%'
</if>
<if test="vo.modeName != null and vo.modeName != ''">
AND d.MODE_NAME = #{vo.modeName}
</if>
<if test="vo.realName != null and vo.realName != ''">
AND info.REAL_NAME LIKE '%' || #{vo.realName} || '%'
</if>
<if test="vo.certiCode != null and vo.certiCode != ''">
AND info.CERTI_CODE =#{vo.certiCode}
</if>
<if test="vo.sevStarTime != null and vo.sevStarTime != ''">
AND d.DECLARATION_TIME &gt;= TO_DATE (#{vo.sevStarTime}, 'yyyy-mm-dd')
AND program.PROGRAM_DATE &gt;= TO_DATE (#{vo.sevStarTime}, 'yyyy-mm-dd')
</if>
<if test="vo.sevEndTime != null and vo.sevEndTime != ''">
AND d.DECLARATION_TIME &lt;= TO_DATE (#{vo.sevEndTime}, 'yyyy-mm-dd')
AND program.PROGRAM_EDN_DATE &lt;= TO_DATE (#{vo.sevEndTime}, 'yyyy-mm-dd')
</if>
</select>
<select id="getsrvOrgan" resultType="com.hungraim.ltc.pojo.entity.account.ChPunchDetailsVO">
......@@ -103,43 +67,32 @@
FROM
CH_SRV_ORGAN n
LEFT JOIN CH_CFG_SRV_ORGAN_TYPE e ON n.ORGAN_ID = e.ORGAN_TYPE_ID
LEFT JOIN CH_DISAB_ACCOUNTS_DETAIL detail ON n.SRV_ORGAN_ID = detail.SRV_ORGAN_ID
WHERE detail.TASK_DETAIL_ID = #{taskDetailId}
LEFT JOIN ch_srv_program program ON n.SRV_ORGAN_ID = program.SRV_ORGAN_ID
WHERE program.PROGRAM_ID = #{taskDetailId}
</select>
<select id="getServiceTypeDetailed" parameterType="Long" resultType="com.hungraim.ltc.pojo.entity.account.ChServiceTypeDetailedVO">
SELECT
to_char( detail.DECLARATION_TIME, 'dd' ) executionTime,
service.SERVICE_TYPE_DETAILED_NAME itemName,
service.SERVICE_TYPE_DETAILED_ID serviceTypeDetailedId
FROM
CH_DISAB_ACCOUNTS_DETAIL detail
LEFT JOIN CH_SRV_TASK_FINISH_ITEM item ON detail.TASK_DETAIL_ID = item.TASK_DETAIL_ID
LEFT JOIN CH_SRV_ORGAN_PROJECT CSOP ON CSOP.PROJECT_ID = item.ITEM_ID
left join CH_SERVICE_TYPE_DETAILED service on service.SERVICE_TYPE_DETAILED_ID = CSOP.ITEM_NAME
WHERE 1=1
<if test="taskDetailId != null and taskDetailId != ''">
and detail.TASK_DETAIL_ID = #{taskDetailId}
</if>
<if test="sevStarTime != null and sevStarTime != ''">
AND detail.DECLARATION_TIME &gt;= TO_DATE (substr(#{sevStarTime} ,1,10), 'yyyy-mm-dd')
</if>
<if test="sevEndTime != null and sevEndTime != ''">
AND detail.DECLARATION_TIME &lt;= TO_DATE (substr(#{sevEndTime},1,10), 'yyyy-mm-dd')
</if>
UNION
SELECT
detail.TASK_DETAIL_ID,
detail.SRV_START_TIME ,
detail.SRV_END_TIME,
to_char( detail.SRV_START_TIME, 'dd' ) executionTime,
service.SERVICE_TYPE_DETAILED_NAME itemName,
service.SERVICE_TYPE_DETAILED_ID serviceTypeDetailedId
FROM
CH_SRV_TASK_DETAIL detail
LEFT JOIN ch_srv_task task ON task.srv_task_id = detail.srv_task_id --服务计划详情
LEFT JOIN CH_SRV_TASK_FINISH_ITEM item ON detail.TASK_DETAIL_ID = item.TASK_DETAIL_ID
LEFT JOIN CH_SRV_ORGAN_PROJECT CSOP ON CSOP.PROJECT_ID = item.ITEM_ID
left join CH_SERVICE_TYPE_DETAILED service on service.SERVICE_TYPE_DETAILED_ID = CSOP.ITEM_NAME
WHERE 1=1
<if test="taskDetailId != null and taskDetailId != ''">
and detail.TASK_DETAIL_ID = #{taskDetailId}
and task.PROGRAM_ID = #{taskDetailId}
</if>
<if test="certiCode != null and certiCode != ''">
and task.DISAB_INFO_ID = (select DISAB_INFO_ID from CH_DISABLE_INFO where CERTI_CODE =#{certiCode})
</if>
<if test="sevStarTime != null and sevStarTime != ''">
AND detail.SRV_START_TIME &gt;= TO_DATE (substr(#{sevStarTime},1,10), 'yyyy-mm-dd')
......
......@@ -62,7 +62,9 @@ public class SystemInterfaceServiceImpl extends ServiceImpl<SystemInterfaceMappe
List<String> systemResourceinterfaces = new ArrayList<>();
resourceinterfaceList.stream().forEach(resourceinterface->{
List<SystemInterface> collect = systemInterfaces.stream().filter(role2 -> role2.getInterfaceId().equals(resourceinterface.getInterfaceId())).collect(Collectors.toList());
systemResourceinterfaces.add(collect.get(0).getInterfaceUrl());
if(collect.size()>0) {
systemResourceinterfaces.add(collect.get(0).getInterfaceUrl());
}
});
//资源和接口
stringStringHashMap.put(roleResource.getResourceId().toString(),systemResourceinterfaces);
......
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