| | |
| | | //新增患者基本信息新增或修改 |
| | | PatArchive patArchive = addPatArchive(externalInHospPatientInfo, externalInHospPatientAddrInfo, externalInHospPatientLiaisonInfo); |
| | | |
| | | |
| | | PatMedInhosp patMedInhosp = new PatMedInhosp(); |
| | | patMedInhosp.setInhospno(externalInHospPatientInfo.getBingAnHao()); |
| | | patMedInhosp.setSerialnum(externalInHospPatientInfo.getJiuZhenYWID()); |
| | |
| | | |
| | | // 4. 新建(此时只剩冷表,PatMedOuthosp没了,需要新建一个) |
| | | patMedOuthospMapper.createPatMedOuthosp(newName, oldName); |
| | | //设置新表自增主键 |
| | | |
| | | //5.设置新表自增主键 |
| | | patMedOuthospMapper.createPatMedOuthospAutoAdd(oldName); |
| | | // 5. 设置新表自增起始值 |
| | | //6. 设置新表自增起始值 |
| | | patMedOuthospMapper.setAutoIncrement(oldName, maxId + 1); |
| | | |
| | | // 6. 更新/新建视图 |
| | | // 7. 更新/新建视图 |
| | | // 重新获取所有表名(包含刚新建的主表) |
| | | List<String> allTables = patMedOuthospMapper.getAllOuthospTableNames(); |
| | | StringBuilder sb = new StringBuilder(); |
| | |
| | | PatArchive patArchive = new PatArchive(); |
| | | //如果是刚出生的小孩子,是没有身份证的,怎么处理???????? |
| | | patArchive.setIdcardno(externalInHospPatientInfo.getZhengJianHM()); |
| | | //如果身份证为空的话,就用就诊卡号代替 |
| | | if (StringUtils.isEmpty(externalInHospPatientInfo.getZhengJianHM())) |
| | | patArchive.setIdcardno(externalInHospPatientInfo.getJiuZhenKH()); |
| | | patArchive.setOrgid(externalInHospPatientInfo.getZuZhiJGID()); |
| | | List<PatArchive> patArchives = null; |
| | | if (ObjectUtils.isNotEmpty(patArchive.getIdcardno())) |