zjh
2025-02-14 408e037640b27edfc0b800a437d02be2deb4fcc4
ltkj-hosp/src/main/java/com/ltkj/hosp/mapper/TjOrderDetailMapper.java
@@ -143,14 +143,14 @@
            "  create_id,\n" +
            "  pro_type) \n" +
            "  \n" +
            "  SELECT #{orderId},a.pro_id,IFNULL(trim(b.pro_default),null),'0',SYSDATE(),#{userName},b.is_sampling,#{userId},IFNULL(a.pac_id,0)" +
            "  SELECT #{orderId},a.pro_id,IFNULL(trim(b.pro_default),null),IF(b.need_report<>'Y',1,0),SYSDATE(),#{userName},b.is_sampling,#{userId},IFNULL(a.pac_id,0)" +
            " FROM tb_transition a LEFT JOIN tj_project b ON a.pro_id=b.pro_id  WHERE a.cus_id=#{cusId} AND a.card_id=#{cardId} \n" +
            "\t\t\n" +
            "\tUNION\n" +
            "  \n" +
            "\tSELECT #{orderId},a.parent_pro_id,IFNULL(trim(b.pro_default),null),'0',SYSDATE(),#{userName},b.is_sampling,#{userId},IFNULL(a.pac_id,0) " +
            "\tSELECT #{orderId},a.parent_pro_id,IFNULL(trim(b.pro_default),null),IF(b.need_report<>'Y',1,0),SYSDATE(),#{userName},b.is_sampling,#{userId},IFNULL(a.pac_id,0) " +
            "FROM tb_transition a LEFT JOIN tj_project b ON a.parent_pro_id=b.pro_id  WHERE a.cus_id=#{cusId} AND a.card_id=#{cardId} GROUP BY a.parent_pro_id")
     boolean saveTjOrderDetailsByCusId(@Param("cusId")String cusId,@Param("orderId")String orderId,@Param("userName")String userName,@Param("userId") String userId,@Param("cardId") String cardId);
    boolean saveTjOrderDetailsByCusId(@Param("cusId")String cusId,@Param("orderId")String orderId,@Param("userName")String userName,@Param("userId") String userId,@Param("cardId") String cardId);
    @Insert("\tINSERT INTO tj_order_detail(\n" +