Selaa lähdekoodia

代家人问诊接诊界面字段新增

wangjun 4 vuotta sitten
vanhempi
commit
17aaf4897d

+ 16 - 0
business/base-service/src/main/java/com/yihu/jw/hospital/prescription/service/PrescriptionService.java

@ -4438,6 +4438,8 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres
                "room.outpatient_id AS \"id\"," +
                "room.patient_id AS \"patient_id\"," +
                "room.patient_name AS \"name\"," +
                "outpatient.patient_name AS \"outPatientName\"," +
                "outpatient.patient AS \"outPatient\"," +
                "patient.sex AS \"sex\"," +
                "patient.idcard AS \"idcard\"," +
                "patient.photo AS \"photo\"," +
@ -4527,6 +4529,20 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres
            //根据身份证计算年龄
            for (Map<String, Object> outpatient : list) {
                String idcard = (String) outpatient.get("idcard");
                int patientAge = 0;
                int patientSex = 3;
                if (null!=outpatient.get("outPatient")){
                   BasePatientDO basePatientDO = basePatientDao.findById(outpatient.get("outPatient").toString());
                   if (null!=basePatientDO){
                       if (StringUtils.isNotBlank(basePatientDO.getIdcard())){
                           patientAge = DateUtil.getAgeForIdcard(basePatientDO.getIdcard());
                           outpatient.put("patientAge", DateUtil.getAgeForIdcard(basePatientDO.getIdcard()));
                       }
                       patientSex =basePatientDO.getSex();
                   }
                }
                outpatient.put("patientAge", patientAge);
                outpatient.put("patientSex", patientSex);
                outpatient.put("age", DateUtil.getAgeForIdcard(idcard));
            }
        }

+ 1 - 1
business/base-service/src/main/java/com/yihu/jw/hospital/prescription/service/YkyyPrescriptionService.java

@ -252,7 +252,7 @@ public class YkyyPrescriptionService extends BaseJpaService<WlyyPrescriptionDO,
                expressageDO.setProvinceName(baseDrugStoreDO.getProvinceName());
                expressageDO.setTownCode(baseDrugStoreDO.getTownCode());
                expressageDO.setTownName(baseDrugStoreDO.getTownName());
                expressageDO.setHospitalCode(baseDrugStoreDO.getHospitalCode());
                expressageDO.setHospitalCode(baseDrugStoreDO.getDrugStoreCode());
                expressageDO.setHospitalName(baseDrugStoreDO.getHospitalName());
                expressageDO.setHospitalAddress(baseDrugStoreDO.getAddress());
            }

+ 9 - 0
business/im-service/src/main/java/com/yihu/jw/im/service/ImService.java

@ -1361,6 +1361,15 @@ public class ImService {
		jsonObject.put("age",DateUtil.getAgeForIdcard(p.getIdcard()));
		jsonObject.put("sex",p.getSex());
		jsonObject.put("name",p.getName());
		if (null!=wlyyOutpatientDO){
			BasePatientDO outPatient = basePatientDao.findById(wlyyOutpatientDO.getPatient());
			if (null!=outPatient){
				jsonObject.put("age",DateUtil.getAgeForIdcard(outPatient.getIdcard()));
				jsonObject.put("sex",outPatient.getSex());
				jsonObject.put("name",outPatient.getName());
			}
		}
		//4、创建咨询
		JSONObject users = new JSONObject();//咨询参与者