|
@ -852,7 +852,14 @@ public class PatientNoLoginEndPoint extends EnvelopRestEndpoint {
|
|
|
for (WlyyPrescriptionDO prescriptionDO:prescriptionDOList){
|
|
|
String patient = prescriptionDO.getPatientCode();
|
|
|
if (prescriptionDO.getStatus()!=30){
|
|
|
String pushPayLog = payInfoNoticeService.pushPrescriptionPay(prescriptionDO.getPatientCode(),prescriptionDO.getDoctorName(),voucherNo,prescriptionDO.getOutpatientId(),prescriptionDO.getId(),prescriptionDO.getDrugFee().toString());
|
|
|
WlyyOutpatientDO wlyyOutpatientDO = outpatientDao.findById(prescriptionDO.getOutpatientId());
|
|
|
String fee=null;
|
|
|
if (wlyyOutpatientDO.getHisStatus()!=null&&wlyyOutpatientDO.getHisStatus()==1){
|
|
|
fee=(prescriptionDO.getDrugFee()+15)+"";
|
|
|
}else {
|
|
|
fee=prescriptionDO.getDrugFee()+"";
|
|
|
}
|
|
|
String pushPayLog = payInfoNoticeService.pushPrescriptionPay(wlyyOutpatientDO.getConsumer(),prescriptionDO.getDoctorName(),voucherNo,prescriptionDO.getOutpatientId(),prescriptionDO.getId(),fee);
|
|
|
WlyyPrescriptionLogDO prescriptionLogDO = new WlyyPrescriptionLogDO();
|
|
|
prescriptionLogDO.setCreateTime(new Date());
|
|
|
prescriptionLogDO.setStatus(30);
|
|
@ -863,21 +870,21 @@ public class PatientNoLoginEndPoint extends EnvelopRestEndpoint {
|
|
|
prescriptionLogDO.setUserType(1);
|
|
|
prescriptionLogDO.setDatajson("处方结算");
|
|
|
prescriptionLogDao.save(prescriptionLogDO);
|
|
|
for (WaitPayDetailVO waitPayDetailVO1:listWPD){
|
|
|
if (waitPayDetailVO1.getItemName().equalsIgnoreCase("互联网医院复诊诊查费")){
|
|
|
List<WlyyPrescriptionDO> wlyyPrescriptionDOS = prescriptionDao.findByRealOrderList(waitPayDetailVO1.getRecipeNo());
|
|
|
if (wlyyPrescriptionDOS!=null&&wlyyPrescriptionDOS.size()!=0){
|
|
|
WlyyPrescriptionDO wlyyPrescriptionDO = wlyyPrescriptionDOS.get(0);
|
|
|
outpatientDao.updateHisStatusById(wlyyPrescriptionDO.getOutpatientId(),1);
|
|
|
logger.info("更新门诊结算状态");
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
logger.info("处方结算成功"+pushPayLog+"====="+waitPayDetailVO.getRecipeNo());
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
for (WaitPayDetailVO waitPayDetailVO:listWPD){
|
|
|
if (waitPayDetailVO.getItemName().equalsIgnoreCase("互联网医院复诊诊查费")){
|
|
|
List<WlyyPrescriptionDO> wlyyPrescriptionDOS = prescriptionDao.findByRealOrderList(waitPayDetailVO.getRecipeNo());
|
|
|
if (wlyyPrescriptionDOS!=null&&wlyyPrescriptionDOS.size()!=0){
|
|
|
WlyyPrescriptionDO wlyyPrescriptionDO = wlyyPrescriptionDOS.get(0);
|
|
|
WlyyOutpatientDO wlyyOutpatientDO = outpatientDao.findById(wlyyPrescriptionDO.getOutpatientId());
|
|
|
|
|
|
outpatientDao.updateHisStatusById(wlyyPrescriptionDO.getOutpatientId(),1);
|
|
|
logger.info("更新门诊结算状态");
|
|
|
}
|
|
|
}
|
|
|
prescriptionDao.updateStatusByRealOrder(waitPayDetailVO.getRecipeNo(),30,new Date());
|
|
|
}
|
|
|
logger.info("更新系统处方支付状态");
|