|
@@ -62,6 +62,8 @@ public class MedicalViewApiController {
|
|
|
|
|
|
//海慈身份证类型
|
|
|
private static final String ID_CARD_TYPE = "11";
|
|
|
+ //诊疗卡类型
|
|
|
+ private static final String MEDICAL_CARD_TYPE = "99";
|
|
|
//海慈参数男性
|
|
|
private static final String MAN = "M";
|
|
|
//海慈参数女性
|
|
@@ -94,12 +96,20 @@ public class MedicalViewApiController {
|
|
|
results.put("resultMessage", "顾客证件号码不能为空");
|
|
|
return results;
|
|
|
}
|
|
|
- if (!ID_CARD_TYPE.equals(haicipat.getPatIdType())) {
|
|
|
+ if (!Arrays.asList(ID_CARD_TYPE,MEDICAL_CARD_TYPE).contains(haicipat.getPatIdType())) {
|
|
|
results.put("resultCode", -1);
|
|
|
- results.put("resultMessage", "顾客证件号码非身份证,暂不支持");
|
|
|
+ results.put("resultMessage", "顾客证件类型非身份证或者诊疗卡,暂不支持");
|
|
|
return results;
|
|
|
}
|
|
|
- List<MzPatientMi> mzPatientMis = mzPatientMiService.queryBySocialNo(haicipat.getPatIdNo(), null);
|
|
|
+ List<MzPatientMi> mzPatientMis =null;
|
|
|
+ if(ID_CARD_TYPE.equals(haicipat.getPatIdType())){
|
|
|
+ mzPatientMis = mzPatientMiService.queryBySocialNo(haicipat.getPatIdNo(), null);
|
|
|
+ }else if(MEDICAL_CARD_TYPE.equals(haicipat.getPatIdType())){
|
|
|
+ MzPatientMi mzPatientMi = mzPatientMiService.queryByIcCardNo(haicipat.getPatIdNo());
|
|
|
+ if(mzPatientMi!=null){
|
|
|
+ mzPatientMis=Arrays.asList(mzPatientMi);
|
|
|
+ }
|
|
|
+ }
|
|
|
if (mzPatientMis == null || mzPatientMis.size() == 0) {
|
|
|
results.put("resultCode", -1);
|
|
|
results.put("resultMessage", "没有查询到病人信息");
|