You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

29 lines
1.2 KiB

5 months ago
5 months ago
5 months ago
4 months ago
5 months ago
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3. <mapper namespace="com.example.demo.mapper.coin.ExportMapper">
  4. <update id="updateExportData">
  5. UPDATE export
  6. <set>
  7. <if test="state != null">state = #{state},</if>
  8. <if test="url != null and url != ''">url = #{url},</if>
  9. <if test="reason != null and reason != ''">reason = #{reason},</if>
  10. <if test="dataNum != null and dataNum != ''">data_num = #{dataNum},</if>
  11. </set>
  12. WHERE id = #{recordId}
  13. </update>
  14. <select id="getExportData" resultType="com.example.demo.domain.vo.coin.ExportVo">
  15. select id,file_name,url,state from export where id=#{recordId}
  16. </select>
  17. <select id="getExportRecord" resultType="com.example.demo.domain.entity.Export">
  18. select * from export
  19. <where>
  20. <if test="account != null">
  21. and account = #{account}
  22. </if>
  23. <if test="type != null">
  24. and type = #{type}
  25. </if>
  26. </where>
  27. order by create_time desc
  28. </select>
  29. </mapper>