zhaowenxuan
2024-07-19 c4962d4a0cb4089bcffda90b07da34d666e4bbc2
ltkj-hosp/src/main/java/com/ltkj/hosp/mapper/TbTransitionMapper.java
@@ -96,7 +96,7 @@
//    @Select("SELECT * FROM tb_transition WHERE cus_id=#{cusId} AND ISNULL(pac_id)  AND pro_id =#{proId}")
//    public List<TbTransition> getTbTransitionListByCusIdAndPacIdAndProId(@Param("cusId") String cusId,@Param("proId") String proId);
    @Select("SELECT * FROM tb_transition WHERE cus_id=#{cusId}  AND pro_id =#{proId}")
    @Select("SELECT * FROM tb_transition WHERE cus_id=#{cusId}  AND pro_id =#{proId} and ISNULL(tj_num)")
    public List<TbTransition> getTbTransitionListByCusIdAndPacIdAndProId(@Param("cusId") String cusId,@Param("proId") String proId);
    @Select("SELECT DISTINCT pac_id FROM tb_transition WHERE cus_id=#{cusId} AND !ISNULL(pac_id)")
@@ -113,7 +113,7 @@
            "a.ord_price=a.now_price,\n" +
            "a.now_price=a.ord_price*(#{discount}/10)," +
            "a.tj_num=#{tjNum}"+
            " WHERE a.cus_id=#{cusId} ")
            " WHERE a.cus_id=#{cusId}  AND ISNULL(a.tj_num) ")
    boolean updateTbTransitionPriceByCusId(@Param("cusId")String cusId,@Param("discount")BigDecimal discount,@Param("tjNum")String tjNum);
@@ -141,7 +141,8 @@
            "\tb.pro_id,\n" +
            "\tb.pro_name,\n" +
            "\tTRUNCATE(c.pro_price,2),\n" +
            " IFNULL(TRUNCATE(c.pro_price * (TRUNCATE ( a.price_now / b.pro_price, 5 )),2),0), " +
            "\tTRUNCATE(c.pro_price,2),\n" +
//            " IFNULL(TRUNCATE(c.pro_price * (TRUNCATE ( a.price_now / b.pro_price, 5 )),2),0), " +
            "\tSYSDATE(),\n" +
            "\tc.pro_check_method,\n" +
            "\tIFNULL(c.pro_type,''),\n" +
@@ -238,4 +239,7 @@
            "\tAND a.tj_num = #{tjNumber}")
    boolean updateCardIdByTjNumAndIdCard(@Param("idCard")String idCard,@Param("cardId")String cardId,@Param("tjNumber") String tjNumber);
    @Delete("DELETE  FROM tb_transition WHERE jxbz=#{bldh}")
    void deleteTjOrderDetailByjxbz(String bldh);
}