陈昶聿
96 分钟以前 717abbe819892d3cded73b12772b216b48d7e357
【丽水】宣教超链接跳转调整
已修改2个文件
26 ■■■■■ 文件已修改
smartor/src/main/java/com/smartor/service/impl/ServiceSubtaskServiceImpl.java 20 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
smartor/src/main/resources/mapper/smartor/ServiceSubtaskMapper.xml 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
smartor/src/main/java/com/smartor/service/impl/ServiceSubtaskServiceImpl.java
@@ -2617,16 +2617,21 @@
    @Cacheable(value = "sfStatistics", key = "T(org.springframework.util.DigestUtils).md5DigestAsHex(#serviceSubtaskCountReq.toString().getBytes())", unless = "#result == null or #result.isEmpty()")
    public List<ServiceSubtaskStatistic> getSfStatistics(ServiceSubtaskCountReq serviceSubtaskCountReq) {
        log.info("getSfStatistics的入参为:{}", serviceSubtaskCountReq);
        String groupKey = "drcode";
        String drcode = "drcode";
        //缙云人民 根据经管医生分组
        if(serviceSubtaskCountReq.getOrgid().equals("47246116333112211A1001")){
            drcode = "management_doctor_code";
        }
        String groupKey = drcode;
        if (serviceSubtaskCountReq.getStatisticaltype() != null && serviceSubtaskCountReq.getStatisticaltype() == 1) {
            if (serviceSubtaskCountReq.getDrcode() != null && !serviceSubtaskCountReq.getDrcode().isEmpty()) {
                groupKey = "drcode";
                groupKey = drcode;
            } else {
                groupKey = "leavehospitaldistrictcode";
            }
        } else if (serviceSubtaskCountReq.getStatisticaltype() != null && serviceSubtaskCountReq.getStatisticaltype() == 2) {
            if (serviceSubtaskCountReq.getDrcode() != null && !serviceSubtaskCountReq.getDrcode().isEmpty()) {
                groupKey = "drcode";
                groupKey = drcode;
            } else {
                groupKey = "deptcode";
            }
@@ -2639,12 +2644,15 @@
        serviceSubtaskCountReq.setGroupKeyList(groupKeyList);
        List<ServiceSubtask> rawData = serviceSubtaskMapper.getSfStatistics(serviceSubtaskCountReq);
        switch (groupKey) {
            case "deptcode":
                collect = rawData.stream().collect(Collectors.groupingBy(subtask -> Optional.ofNullable(subtask.getDeptcode()).orElse("Unknown")));
                break;
            case "drcode":
                collect = rawData.stream().collect(Collectors.groupingBy(subtask -> Optional.ofNullable(subtask.getDrcode()).orElse("Unknown")));
                break;
            case "management_doctor_code":
                collect = rawData.stream().collect(Collectors.groupingBy(subtask -> Optional.ofNullable(subtask.getManagementDoctorCode()).orElse("Unknown")));
                break;
            case "deptcode":
                collect = rawData.stream().collect(Collectors.groupingBy(subtask -> Optional.ofNullable(subtask.getDeptcode()).orElse("Unknown")));
                break;
            case "leavehospitaldistrictcode":
                collect = rawData.stream().collect(Collectors.groupingBy(subtask -> Optional.ofNullable(subtask.getLeavehospitaldistrictcode()).orElse("Unknown")));
                break;
smartor/src/main/resources/mapper/smartor/ServiceSubtaskMapper.xml
@@ -1484,6 +1484,8 @@
        orgid,
        drcode,
        drname,
        management_doctor_code,
        management_doctor,
        leavehospitaldistrictcode,
        leavehospitaldistrictname,
        deptcode,
@@ -2916,7 +2918,7 @@
        </choose>
    </select>
    <select id="gethelibraryCountHyperlink" parameterType="com.smartor.domain.ServiceSubtaskCountReq"
    <select id="gethelibraryCountHyperlink" parameterType="com.smartor.domain.VO.HeLibraryCountVO"
            resultMap="ServiceSubtaskResult">
        select id,
        visit_count,
@@ -2966,7 +2968,7 @@
        <if test="sendstate != null">
            AND sendstate = #{sendstate}
        </if>
        <if test="isFinished != null and isFinished == '1'">
        <if test="isFinished != null and isFinished = '1'">
            AND finishtime is not null
        </if>
        <if test="hospitaldistrictcodes != null and hospitaldistrictcodes.size() > 0">