TempCarFeeConfigAttrV1ServiceDaoImplMapper.xml 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <!DOCTYPE mapper
  3. PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
  4. "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  5. <mapper namespace="tempCarFeeConfigAttrV1ServiceDaoImpl">
  6. <!-- 保存临时费用配置信息 add by wuxw 2018-07-03 -->
  7. <insert id="saveTempCarFeeConfigAttrInfo" parameterType="Map">
  8. insert into temp_car_fee_config_attr(
  9. attr_id,config_id,spec_cd,community_id,value
  10. ) values (
  11. #{attrId},#{configId},#{specCd},#{communityId},#{value}
  12. )
  13. </insert>
  14. <!-- 查询临时费用配置信息 add by wuxw 2018-07-03 -->
  15. <select id="getTempCarFeeConfigAttrInfo" parameterType="Map" resultType="Map">
  16. select t.attr_id,t.attr_id attrId,t.config_id,t.config_id configId,t.spec_cd,t.spec_cd specCd,t.status_cd,t.status_cd statusCd,t.community_id,t.community_id communityId,t.value
  17. from temp_car_fee_config_attr t
  18. where 1 =1
  19. <if test="attrId !=null and attrId != ''">
  20. and t.attr_id= #{attrId}
  21. </if>
  22. <if test="configId !=null and configId != ''">
  23. and t.config_id= #{configId}
  24. </if>
  25. <if test="specCd !=null and specCd != ''">
  26. and t.spec_cd= #{specCd}
  27. </if>
  28. <if test="statusCd !=null and statusCd != ''">
  29. and t.status_cd= #{statusCd}
  30. </if>
  31. <if test="communityId !=null and communityId != ''">
  32. and t.community_id= #{communityId}
  33. </if>
  34. <if test="value !=null and value != ''">
  35. and t.value= #{value}
  36. </if>
  37. order by t.create_time desc
  38. <if test="page != -1 and page != null ">
  39. limit #{page}, #{row}
  40. </if>
  41. </select>
  42. <!-- 修改临时费用配置信息 add by wuxw 2018-07-03 -->
  43. <update id="updateTempCarFeeConfigAttrInfo" parameterType="Map">
  44. update temp_car_fee_config_attr t set t.status_cd = #{statusCd}
  45. <if test="newBId != null and newBId != ''">
  46. ,t.b_id = #{newBId}
  47. </if>
  48. <if test="configId !=null and configId != ''">
  49. , t.config_id= #{configId}
  50. </if>
  51. <if test="specCd !=null and specCd != ''">
  52. , t.spec_cd= #{specCd}
  53. </if>
  54. <if test="communityId !=null and communityId != ''">
  55. , t.community_id= #{communityId}
  56. </if>
  57. <if test="value !=null and value != ''">
  58. , t.value= #{value}
  59. </if>
  60. where 1=1 <if test="attrId !=null and attrId != ''">
  61. and t.attr_id= #{attrId}
  62. </if>
  63. </update>
  64. <!-- 查询临时费用配置数量 add by wuxw 2018-07-03 -->
  65. <select id="queryTempCarFeeConfigAttrsCount" parameterType="Map" resultType="Map">
  66. select count(1) count
  67. from temp_car_fee_config_attr t
  68. where 1 =1
  69. <if test="attrId !=null and attrId != ''">
  70. and t.attr_id= #{attrId}
  71. </if>
  72. <if test="configId !=null and configId != ''">
  73. and t.config_id= #{configId}
  74. </if>
  75. <if test="specCd !=null and specCd != ''">
  76. and t.spec_cd= #{specCd}
  77. </if>
  78. <if test="statusCd !=null and statusCd != ''">
  79. and t.status_cd= #{statusCd}
  80. </if>
  81. <if test="communityId !=null and communityId != ''">
  82. and t.community_id= #{communityId}
  83. </if>
  84. <if test="value !=null and value != ''">
  85. and t.value= #{value}
  86. </if>
  87. </select>
  88. </mapper>