| | |
| | | if(StringUtils.isNotEmpty(operation.getOpid())){ |
| | | PatMedOperationItem patMedOperationItem = new PatMedOperationItem(); |
| | | //patMedOperation.opReqid = patMedOperationItem.operationid |
| | | patMedOperationItem.setOperationid(operation.getOpreqid()); |
| | | List<PatMedOperationItem> patMedOperationItems = chMapper.selectOperItemList(patMedOperationItem); |
| | | List<PatMedOperationItem> patMedOperationItems = new ArrayList<>(); |
| | | if (ObjectUtils.isNotEmpty(operation.getOpreqid())){ |
| | | patMedOperationItem.setOperationid(operation.getOpreqid()); |
| | | patMedOperationItems = chMapper.selectOperItemList(patMedOperationItem); |
| | | }else { |
| | | log.info("同步手术详情信息:手术申请单ID为空!"); |
| | | return count; |
| | | } |
| | | |
| | | PatMedOperationItem operItem = new PatMedOperationItem(); |
| | | operItem.setOperationid(operation.getOpreqid()); |
| | |
| | | log.info("selectDeptList的采集到的数量为:{}", sysDepts.size()); |
| | | // count = sysDept2Mapper.batchDept(sysDepts); |
| | | for (SysDept row : sysDepts) { |
| | | SysDept sysDeptTemp = sysDept2Mapper.selectDeptByCode(row.getDeptCode(), null); |
| | | // 科室和病区可能共用同一个 dept_code,必须按 dept_type + orgid 精确定位,否则 selectOne 会返回多条 |
| | | if (StringUtils.isEmpty(row.getDeptCode())) { |
| | | log.warn("selectDeptList跳过deptCode为空的记录:{}", row); |
| | | continue; |
| | | } |
| | | SysDept sysDeptTemp = sysDept2Mapper.selectDeptByCodeAndType(row.getDeptCode(), row.getOrgid(), row.getDeptType()); |
| | | if (sysDeptTemp != null && sysDeptTemp.getDeptName() != null) { |
| | | row.setDeptId(sysDeptTemp.getDeptId()); |
| | | count += sysDept2Mapper.updateDept(row); |