Explorar o código

修改SQL语句,查找支付成功,未结算成功,增加过滤处方状态

huangwenjie %!s(int64=7) %!d(string=hai) anos
pai
achega
9a81debab6

+ 1 - 1
patient-co/patient-co-wlyy-job/src/main/java/com/yihu/wlyy/repository/prescription/PrescriptionDao.java

@ -22,7 +22,7 @@ public interface PrescriptionDao extends PagingAndSortingRepository<Prescription
    @Query("select p from Prescription p where p.jwCode=?1 and p.status=?2 ")
    List<Prescription> fingdByJwCodeAndStatus(String jwcode,Integer status);
    @Query(value = "select p.prescription_code from wlyy_prescription_pay p LEFT JOIN  wlyy_prescription a on a.code = p.prescription_code where p.trade_status = 1 and a.jw_pay_status = 0",nativeQuery = true)
    @Query(value = "select p.prescription_code from wlyy_prescription_pay p LEFT JOIN  wlyy_prescription a on a.code = p.prescription_code where p.trade_status = 1 and a.jw_pay_status = 0 and a.status=50",nativeQuery = true)
    List<String> findCodesByPayStautsAndExecuteSickStatus();
    @Modifying