Explorar o código

Merge branch 'dev' of http://192.168.1.220:10080/Amoy2/wlyy2.0 into dev

wangjun %!s(int64=4) %!d(string=hai) anos
pai
achega
11a5449a32

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

@ -41,7 +41,7 @@ public interface PrescriptionDao extends PagingAndSortingRepository<WlyyPrescrip
    @Query("update WlyyPrescriptionDO p set p.status=?1 ,p.finishTime =?2 where p.outpatientId=?3")
    void updateStatusByOutPatientId(Integer status, Date date,String id);
    @Query("select a from WlyyPrescriptionDO a where a.outpatientId = ?1 and a.checkStatus<>3 ")
    @Query("select a from WlyyPrescriptionDO a where a.outpatientId = ?1 ")
    List<WlyyPrescriptionDO> findByOutpatientId(String outpatientId);
    List<WlyyPrescriptionDO> findById(String id);

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

@ -2115,7 +2115,6 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres
            prescriptionDO.setDoctor(outpatientDO.getDoctor());
            prescriptionDO.setDoctorName(outpatientDO.getDoctorName());
            prescriptionDO.setPayStatus(0);
            prescriptionDO.setCheckStatus(3);
            if (wechatId.equalsIgnoreCase("xm_ykyy_wx")) {
                prescriptionDO.setAdmNo(outpatientDO.getAdmNo());
            }
@ -2172,12 +2171,10 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres
        //=====================保存日志 start=========================================================
        List<WlyyPrescriptionCheckDO> prescriptionCheckDOS = prescriptionCheckDao.findByStatus(prescription.getId(), 5);
        if (prescriptionCheckDOS == null || prescriptionCheckDOS.size() == 0) {
            savePrescriptionCheck(prescription.getDoctor(), "开具处方", 5, prescription.getId());
            savePrescriptionCheck(prescription.getDoctor(), "草稿", 6, prescription.getId());
        }
        if (wlyyPrescriptionDO1 != null && wlyyPrescriptionDO1.size() > 0) {
            savePrescriptionCheck(prescription.getDoctor(), "处方修改", 3, prescription.getId());
        }
        //=====================保存日志 end=========================================================
        //判断是否有检查检验或药品开方
@ -7380,6 +7377,9 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres
        } else if (status == 5) {
            wlyyPrescriptionDO.setCheckStatus(0);
            wlyyPrescriptionDO.setCheckReason("未审核");
        }else if (status == 6) {
            wlyyPrescriptionDO.setCheckStatus(3);
            wlyyPrescriptionDO.setCheckReason("草稿");
        }
        prescriptionDao.save(wlyyPrescriptionDO);
        return prescriptionCheckDO;