| | |
| | | public List<TjProject> selectTjOrderDetailListByFlowingWaterIdIsNotNull(String orderId); |
| | | |
| | | /** |
| | | * 查询已缴费项目 |
| | | */ |
| | | @Select("SELECT * FROM tj_project p WHERE p.pro_parent_id =0 AND p.pro_id IN (\n" + |
| | | " SELECT a.pro_id FROM tj_order_detail a WHERE !ISNULL(flowing_water_id) AND order_id=#{orderId} and a.deleted=0 and a.jxbz = #{jxbz} )") |
| | | public List<TjProject> selectTjOrderDetailListByFlowingWaterIdIsNotNullN(@Param("orderId") String orderId,@Param("jxbz") String jxbz); |
| | | |
| | | @Select("SELECT * FROM tj_project p WHERE p.pro_parent_id =0 AND p.pro_id IN (\n" + |
| | | " SELECT a.pro_id FROM tj_order_detail a WHERE !ISNULL(flowing_water_id) AND order_id=#{orderId} and a.deleted=0 and a.jxbz is null )") |
| | | List<TjProject> selectTjOrderDetailListByFlowingWaterIdIsNotNullAndJxbzIsNull(String orderId); |
| | | |
| | | /** |
| | | * 查询未缴费项目 |
| | | */ |
| | | @Select("SELECT * FROM tj_project p WHERE p.pro_parent_id =0 AND p.pro_id IN (\n" + |
| | | " SELECT a.pro_id FROM tj_order_detail a WHERE ISNULL(flowing_water_id) AND order_id=#{orderId} and a.deleted=0 )") |
| | | public List<TjProject> selectTjOrderDetailListByFlowingWaterIdIsNull(String orderId); |
| | | |
| | | /** |
| | | * 查询未缴费项目 |
| | | */ |
| | | @Select("SELECT * FROM tj_project p WHERE p.pro_parent_id =0 AND p.pro_id IN (\n" + |
| | | " SELECT a.pro_id FROM tj_order_detail a WHERE ISNULL(flowing_water_id) AND order_id=#{orderId} and a.deleted=0 and a.jxbz = #{jxbz} )") |
| | | public List<TjProject> selectTjOrderDetailListByFlowingWaterIdIsNullN(@Param("orderId") String orderId,@Param("jxbz") String jxbz); |
| | | |
| | | @Select("SELECT * FROM tj_project p WHERE p.pro_parent_id =0 AND p.pro_id IN (\n" + |
| | | " SELECT a.pro_id FROM tj_order_detail a WHERE ISNULL(flowing_water_id) AND order_id=#{orderId} and a.deleted=0 and a.jxbz is null )") |
| | | List<TjProject> selectTjOrderDetailListByFlowingWaterIdIsNullAndJxbzIsNull(String orderId); |
| | | |
| | | |
| | | @Select("SELECT * FROM tj_order_detail WHERE order_id=#{orderId} AND !ISNULL(flowing_water_id) AND deleted='0'") |
| | |
| | | " create_id,\n" + |
| | | " pro_type) \n" + |
| | | " \n" + |
| | | " SELECT #{orderId},a.pro_id,IFNULL(b.pro_default,''),'0',SYSDATE(),#{userName},b.is_sampling,#{userId},IFNULL(a.pac_id,0)" + |
| | | " SELECT #{orderId},a.pro_id,IFNULL(trim(b.pro_default),null),'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(b.pro_default,''),'0',SYSDATE(),#{userName},b.is_sampling,#{userId},IFNULL(a.pac_id,0) " + |
| | | "\tSELECT #{orderId},a.parent_pro_id,IFNULL(trim(b.pro_default),null),'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); |
| | | |
| | |
| | | " pro_type," + |
| | | "flowing_water_id) \n" + |
| | | " \n" + |
| | | " SELECT #{orderId},a.pro_id,IFNULL(b.pro_default,''),'1',SYSDATE(),#{userName},b.is_sampling,#{userId},IFNULL(a.pac_id,0) ,#{sl}" + |
| | | " SELECT #{orderId},a.pro_id,IFNULL(trim(b.pro_default),null),'1',SYSDATE(),#{userName},b.is_sampling,#{userId},IFNULL(a.pac_id,0) ,#{sl}" + |
| | | "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(b.pro_default,''),'0',SYSDATE(),#{userName},b.is_sampling,#{userId},IFNULL(a.pac_id,0) ,#{sl}" + |
| | | "\tSELECT #{orderId},a.parent_pro_id,IFNULL(trim(b.pro_default),null),'0',SYSDATE(),#{userName},b.is_sampling,#{userId},IFNULL(a.pac_id,0) ,#{sl}" + |
| | | " 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 saveJSYTjOrderDetailsByCusId(@Param("cusId")String cusId,@Param("orderId")String orderId,@Param("userName")String userName,@Param("userId") String userId, |
| | | @Param("cardId") String cardId,@Param("sl") String sl); |