| | |
| | | import org.apache.commons.collections4.CollectionUtils; |
| | | import org.apache.commons.collections4.MapUtils; |
| | | import org.apache.commons.lang3.ObjectUtils; |
| | | import org.apache.ibatis.annotations.Param; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.cache.annotation.Cacheable; |
| | |
| | | serviceSubtaskRes.setSendstateView(1L); |
| | | if (serviceSubtaskRes.getSendstate() == 6) serviceSubtaskRes.setSendstateView(2L); |
| | | if (serviceSubtaskRes.getSendstate() == 4) serviceSubtaskRes.setSendstateView(3L); |
| | | // 填充当前补偿 |
| | | if (StringUtils.isEmpty(serviceSubtask.getCurrentPreachform())){ |
| | | if(StringUtils.isNotEmpty(serviceSubtask.getPreachform())){ |
| | | //默认取第一个 |
| | | serviceSubtaskRes.setCurrentPreachform(serviceSubtask.getPreachform().split(",")[0]); |
| | | } |
| | | } |
| | | serviceSubtaskResList.add(serviceSubtaskRes); |
| | | } |
| | | return serviceSubtaskResList; |
| | |
| | | serviceTaskoper.setGuid(serviceTask.getGuid()); |
| | | serviceTaskoper.setOrgid(serviceTask.getOrgid()); |
| | | serviceTaskoper.setCreateTime(new Date()); |
| | | //配置科室病区 |
| | | //配置科室、病区 |
| | | serviceTaskoper.setDeptCode(serviceTaskVO.getDeptcode()); |
| | | serviceTaskoper.setDeptName(serviceTaskVO.getDeptname()); |
| | | serviceTaskoper.setWardCode(serviceTaskVO.getLeavehospitaldistrictcode()); |
| | | serviceTaskoper.setWardName(serviceTaskVO.getLeavehospitaldistrictname()); |
| | | |
| | | //多选手术等级 |
| | | if (StringUtils.isNotEmpty(serviceTaskVO.getOplevelcode())) { |
| | | String[] opLevelcodes = serviceTaskVO.getOplevelcode().split(","); |
| | |
| | | serviceSubtaskStatistic.setFollowUpNeeded(serviceSubtaskStatistic.getFollowUpNeeded() + 1L); |
| | | } |
| | | |
| | | //首次出院随访-统计再次推送数量 |
| | | if (serviceSubtask.getVisitCount() != null && serviceSubtask.getVisitCount() > 1) { |
| | | //再次应随访 |
| | | if (serviceSubtask.getSendstate() != null && serviceSubtask.getSendstate() != 4) { |
| | | serviceSubtaskStatistic.setNeedFollowUpAgain(serviceSubtaskStatistic.getNeedFollowUpAgain() + 1L); |
| | | } |
| | | //再次随访完成 |
| | | if (serviceSubtask.getSendstate() != null && serviceSubtask.getSendstate() == 6) { |
| | | serviceSubtaskStatistic.setFollowUpSuccessAgain(serviceSubtaskStatistic.getFollowUpSuccessAgain() + 1L); |
| | | } |
| | | } |
| | | |
| | | //首次出院随访 |
| | | if (serviceSubtask.getVisitCount() != null && serviceSubtask.getVisitCount() == 1) { |
| | | //首次应随访 |
| | |
| | | return resultMap; |
| | | } |
| | | |
| | | @Override |
| | | public List<ServiceSubtaskDetailRatioExport> statQuestionOption(List<Long> taskIds) { |
| | | return serviceSubtaskMapper.statQuestionOption(taskIds); |
| | | } |
| | | |
| | | private Boolean saveServiceSubtaskDetail(ServiceSubtask serviceSubtask) { |
| | | Boolean result = true; |
| | | //3.4 如果3.1或3.2为true的话,根据type判断什么类型 |