|
@ -10494,16 +10494,39 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres
|
|
|
}
|
|
|
return null;
|
|
|
}
|
|
|
public Map saveNatAppointment(String mediaCard,String patientId,String name,String cardNo,String cardType,String mobile,
|
|
|
public Map saveNatAppointment(String chargeAmount,String inspectionName,String mediaCard,String patientId,String name,String cardNo,String cardType,String mobile,
|
|
|
String firstJobCode,String firstJobName,String secondJobCode,String secondJobName,String natTime,String address,String provinceName,String cityName,String townName,String streetName,String pm,String pushChannel,String pushFlag,String cardNoType,String consumer) throws Exception {
|
|
|
Map returnMap = new HashMap();
|
|
|
List<WlyyHospitalSysDictDO> natConfigList = wlyyHospitalSysDictDao.findByDictName("natConfigList");
|
|
|
String checkPart = "鼻/咽拭子";
|
|
|
String chargeFlag = "2";
|
|
|
String chargeCode = "361322";
|
|
|
String icdCode = "Z00.000";
|
|
|
Integer winNo = 6;
|
|
|
for (WlyyHospitalSysDictDO wlyyHospitalSysDictDO:natConfigList){
|
|
|
if (StringUtils.isNoneBlank(wlyyHospitalSysDictDO.getDictValue())&&"checkPart".equalsIgnoreCase(wlyyHospitalSysDictDO.getDictCode())){
|
|
|
checkPart = wlyyHospitalSysDictDO.getDictValue();
|
|
|
}
|
|
|
if (StringUtils.isNoneBlank(wlyyHospitalSysDictDO.getDictValue())&&"chargeFlag".equalsIgnoreCase(wlyyHospitalSysDictDO.getDictCode())){
|
|
|
chargeFlag = wlyyHospitalSysDictDO.getDictValue();
|
|
|
}
|
|
|
if (StringUtils.isNoneBlank(wlyyHospitalSysDictDO.getDictValue())&&"chargeCode".equalsIgnoreCase(wlyyHospitalSysDictDO.getDictCode())){
|
|
|
chargeCode = wlyyHospitalSysDictDO.getDictValue();
|
|
|
}
|
|
|
if (StringUtils.isNoneBlank(wlyyHospitalSysDictDO.getDictValue())&&"icdCode".equalsIgnoreCase(wlyyHospitalSysDictDO.getDictCode())){
|
|
|
icdCode = wlyyHospitalSysDictDO.getDictValue();
|
|
|
}
|
|
|
if (StringUtils.isNoneBlank(wlyyHospitalSysDictDO.getDictValue())&&"winNo".equalsIgnoreCase(wlyyHospitalSysDictDO.getDictCode())){
|
|
|
winNo = Integer.parseInt(wlyyHospitalSysDictDO.getDictValue());
|
|
|
}
|
|
|
}
|
|
|
if (wechatId.equalsIgnoreCase("xm_zsyy_wx")){
|
|
|
net.sf.json.JSONObject jsondate = new JSONObject();
|
|
|
jsondate.put("checkPart","鼻/咽拭子");
|
|
|
jsondate.put("checkPart",checkPart);
|
|
|
jsondate.put("cardNo",mediaCard);
|
|
|
jsondate.put("chargeFlag","2");
|
|
|
jsondate.put("chargeCode","361322");
|
|
|
jsondate.put("icdCode","Z00.000");
|
|
|
jsondate.put("chargeFlag",chargeFlag);
|
|
|
jsondate.put("chargeCode",chargeCode);
|
|
|
jsondate.put("icdCode",icdCode);
|
|
|
jsondate.put("socialNo",cardNo);
|
|
|
jsondate.put("tellPhone",mobile);
|
|
|
jsondate.put("address1",provinceName);
|
|
@ -10512,7 +10535,7 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres
|
|
|
jsondate.put("address4",streetName);
|
|
|
jsondate.put("address5",address);
|
|
|
jsondate.put("area",townName);
|
|
|
jsondate.put("winNo",6);
|
|
|
jsondate.put("winNo",winNo);
|
|
|
if (StringUtils.isNoneBlank(secondJobName)){
|
|
|
jsondate.put("target",secondJobName);
|
|
|
}else {
|
|
@ -10540,6 +10563,7 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres
|
|
|
}
|
|
|
if (flag){
|
|
|
BaseNatAppointmentDO baseNatAppointmentDO= new BaseNatAppointmentDO();
|
|
|
baseNatAppointmentDO.setChargeAmount(chargeAmount);
|
|
|
baseNatAppointmentDO.setMedicare(mediaCard);
|
|
|
baseNatAppointmentDO.setName(name);
|
|
|
baseNatAppointmentDO.setCardNo(cardNo);
|
|
@ -10560,11 +10584,11 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres
|
|
|
baseNatAppointmentDO.setPayStatus("0");
|
|
|
baseNatAppointmentDO.setCreateTime(new Date());
|
|
|
baseNatAppointmentDO.setMobile(mobile);
|
|
|
baseNatAppointmentDO.setInspectionCode("鼻/咽拭子");
|
|
|
baseNatAppointmentDO.setInspectionName("鼻/咽拭子");
|
|
|
baseNatAppointmentDO.setIcdCode("Z00.000");
|
|
|
baseNatAppointmentDO.setChargeCode("361322");
|
|
|
baseNatAppointmentDO.setWinNo("6");
|
|
|
baseNatAppointmentDO.setInspectionCode(chargeCode);
|
|
|
baseNatAppointmentDO.setInspectionName(inspectionName);
|
|
|
baseNatAppointmentDO.setIcdCode(icdCode);
|
|
|
baseNatAppointmentDO.setChargeCode(chargeCode);
|
|
|
baseNatAppointmentDO.setWinNo(String.valueOf(winNo));
|
|
|
baseNatAppointmentDO.setDept("3150000");
|
|
|
baseNatAppointmentDO.setDeptName("感染疾病科");
|
|
|
baseNatAppointmentDO.setAmpm(pm);
|
|
@ -10702,8 +10726,13 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres
|
|
|
}
|
|
|
return returnMap;
|
|
|
}else if (wechatId.equalsIgnoreCase("xm_ykyy_wx")){
|
|
|
Double natFee = 8000.0;
|
|
|
if(StringUtils.isNoneBlank(chargeAmount)){
|
|
|
natFee= Double.parseDouble(chargeAmount);
|
|
|
}
|
|
|
BaseNatAppointmentDO baseNatAppointmentDO= new BaseNatAppointmentDO();
|
|
|
baseNatAppointmentDO.setMedicare(mediaCard);
|
|
|
baseNatAppointmentDO.setChargeAmount(chargeAmount);
|
|
|
baseNatAppointmentDO.setName(name);
|
|
|
baseNatAppointmentDO.setCardNo(cardNo);
|
|
|
baseNatAppointmentDO.setCardType(cardType);
|
|
@ -10722,11 +10751,11 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres
|
|
|
baseNatAppointmentDO.setPayStatus("0");
|
|
|
baseNatAppointmentDO.setCreateTime(new Date());
|
|
|
baseNatAppointmentDO.setMobile(mobile);
|
|
|
baseNatAppointmentDO.setInspectionCode("鼻/咽拭子");
|
|
|
baseNatAppointmentDO.setInspectionName("鼻/咽拭子");
|
|
|
baseNatAppointmentDO.setIcdCode("Z00.000");
|
|
|
baseNatAppointmentDO.setChargeCode("361322");
|
|
|
baseNatAppointmentDO.setWinNo("6");
|
|
|
baseNatAppointmentDO.setInspectionCode(chargeCode);
|
|
|
baseNatAppointmentDO.setInspectionName(inspectionName);
|
|
|
baseNatAppointmentDO.setIcdCode(icdCode);
|
|
|
baseNatAppointmentDO.setChargeCode(chargeCode);
|
|
|
baseNatAppointmentDO.setWinNo(String.valueOf(winNo));
|
|
|
baseNatAppointmentDO.setDept("3150000");
|
|
|
baseNatAppointmentDO.setDeptName("感染疾病科");
|
|
|
baseNatAppointmentDO.setAmpm(pm);
|
|
@ -10746,7 +10775,7 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres
|
|
|
businessDO.setRelationName("核酸检测订单");
|
|
|
businessDO.setOrderCategory("6");
|
|
|
businessDO.setOrderType(12);
|
|
|
businessDO.setPayPrice(8000.0);
|
|
|
businessDO.setPayPrice(natFee);
|
|
|
businessDO.setRematk("核酸检测订单");
|
|
|
businessDO.setDescription("核酸检测订单");
|
|
|
businessDO.setPayType(1);
|
|
@ -10963,6 +10992,7 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres
|
|
|
"t.id as \"id\"," +
|
|
|
"t.card_no_type as \"cardNoType\"," +
|
|
|
"t.HOSPITAL_FLAG as \"hospitalFlag\"," +
|
|
|
"t.charge_amount as \"chargeAmount\"," +
|
|
|
"t.appointment_time as \"appointmentTime\" " +
|
|
|
" from base_nat_appointment t where 1=1 ";
|
|
|
if (StringUtils.isNoneBlank(patientId)){
|
|
@ -11092,24 +11122,51 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres
|
|
|
baseNatAppointmentDO.setCancelBy(patientId);
|
|
|
baseNatAppointmentDao.save(baseNatAppointmentDO);
|
|
|
if (StringUtils.isNoneBlank(baseNatAppointmentDO.getRealOrder())){
|
|
|
List<WlyyHospitalSysDictDO> natConfigList = wlyyHospitalSysDictDao.findByDictName("natConfigList");
|
|
|
String checkPart = "鼻/咽拭子";
|
|
|
String chargeFlag = "2";
|
|
|
String chargeCode = "361322";
|
|
|
String icdCode = "Z00.000";
|
|
|
Integer winNo = 6;
|
|
|
for (WlyyHospitalSysDictDO wlyyHospitalSysDictDO:natConfigList){
|
|
|
if (StringUtils.isNoneBlank(wlyyHospitalSysDictDO.getDictValue())&&"checkPart".equalsIgnoreCase(wlyyHospitalSysDictDO.getDictCode())){
|
|
|
checkPart = wlyyHospitalSysDictDO.getDictValue();
|
|
|
}
|
|
|
if (StringUtils.isNoneBlank(wlyyHospitalSysDictDO.getDictValue())&&"chargeFlag".equalsIgnoreCase(wlyyHospitalSysDictDO.getDictCode())){
|
|
|
chargeFlag = wlyyHospitalSysDictDO.getDictValue();
|
|
|
}
|
|
|
if (StringUtils.isNoneBlank(wlyyHospitalSysDictDO.getDictValue())&&"chargeCode".equalsIgnoreCase(wlyyHospitalSysDictDO.getDictCode())){
|
|
|
chargeCode = wlyyHospitalSysDictDO.getDictValue();
|
|
|
}
|
|
|
if (StringUtils.isNoneBlank(wlyyHospitalSysDictDO.getDictValue())&&"icdCode".equalsIgnoreCase(wlyyHospitalSysDictDO.getDictCode())){
|
|
|
icdCode = wlyyHospitalSysDictDO.getDictValue();
|
|
|
}
|
|
|
if (StringUtils.isNoneBlank(wlyyHospitalSysDictDO.getDictValue())&&"winNo".equalsIgnoreCase(wlyyHospitalSysDictDO.getDictCode())){
|
|
|
winNo = Integer.parseInt(wlyyHospitalSysDictDO.getDictValue());
|
|
|
}
|
|
|
}
|
|
|
//删除处方
|
|
|
logger.info("删除处方开始");
|
|
|
net.sf.json.JSONObject jsondate = new JSONObject();
|
|
|
jsondate.put("checkPart","鼻/咽拭子");
|
|
|
jsondate.put("checkPart",checkPart);
|
|
|
jsondate.put("cardNo",baseNatAppointmentDO.getMedicare());
|
|
|
jsondate.put("chargeFlag","2");
|
|
|
jsondate.put("chargeCode","361322");
|
|
|
jsondate.put("icdCode","Z00.000");
|
|
|
jsondate.put("chargeFlag",chargeFlag);
|
|
|
jsondate.put("chargeCode",chargeCode);
|
|
|
jsondate.put("icdCode",icdCode);
|
|
|
jsondate.put("socialNo",baseNatAppointmentDO.getCardNo());
|
|
|
jsondate.put("tellPhone",baseNatAppointmentDO.getMobile());
|
|
|
jsondate.put("address1",baseNatAppointmentDO.getProvinceName());
|
|
|
jsondate.put("address2",baseNatAppointmentDO.getCityName());
|
|
|
jsondate.put("address3",baseNatAppointmentDO.getTownName());
|
|
|
jsondate.put("address4",baseNatAppointmentDO.getStreetName());
|
|
|
jsondate.put("address5",2);
|
|
|
jsondate.put("area",baseNatAppointmentDO.getAddress());
|
|
|
jsondate.put("winNo",6);
|
|
|
jsondate.put("target",2);
|
|
|
jsondate.put("address5",baseNatAppointmentDO.getAddress());
|
|
|
jsondate.put("area",baseNatAppointmentDO.getTownName());
|
|
|
jsondate.put("winNo",winNo);
|
|
|
if (StringUtils.isNoneBlank(baseNatAppointmentDO.getSecondJobName())){
|
|
|
jsondate.put("target",baseNatAppointmentDO.getSecondJobName());
|
|
|
}else {
|
|
|
jsondate.put("target",baseNatAppointmentDO.getFirstJobName());
|
|
|
}
|
|
|
jsondate.put("quantity",1);
|
|
|
jsondate.put("serialNo",baseNatAppointmentDO.getRegisterNo());
|
|
|
jsondate.put("dept",baseNatAppointmentDO.getDept());
|
|
@ -11239,6 +11296,7 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres
|
|
|
"t.card_no_type as \"cardNoType\"," +
|
|
|
"t.HOSPITAL_FLAG as \"hospitalFlag\"," +
|
|
|
"m.order_no as \"orderNo\"," +
|
|
|
"t.charge_amount as \"chargeAmount\"," +
|
|
|
"t.appointment_time as \"appointmentTime\" " +
|
|
|
" from base_nat_appointment t left join base_business_order_pay m ";
|
|
|
if ("xm_ykyy_wx".equalsIgnoreCase(wechatId)){
|