PayAgenttransactionMapper.xml 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  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.bz.smart_city.dao.pay.PayAgenttransactionMapper">
  4. <select id="findList" resultType="com.bz.smart_city.dto.pay.PayAgenttransactionDto">
  5. select
  6. a.accountnumber as "accountnumber",
  7. a.accountname as "accountname",
  8. a.agentbranch_id as "agentbranchId",
  9. a.agent_name as "agentName",
  10. a.agent_code as "agentCode",
  11. a.amount as "amount",
  12. a.state as "state",
  13. a.transtime as "transtime",
  14. a.payseriesno as "payseriesno",
  15. a.order_no as "orderNo",
  16. a.id as "id",
  17. a.site_id as "siteId",
  18. a.customer_id as "customerId",
  19. a.create_date as "createDate",
  20. a.create_by as "createBy",
  21. a.update_date as "updateDate",
  22. a.update_by as "updateBy",
  23. a.remarks as "remarks",
  24. a.del_flag as "delFlag"
  25. from pay_pay_agenttransaction a
  26. where a.site_id = '' and customer_id = ''
  27. and a.accountname = '' and a.accountnumber = '' and a.order_no = ''
  28. and a.transtime &lt;= '' and a.transtime >=''
  29. and a.state = ''
  30. </select>
  31. <update id="cancelByPayseriesno">
  32. update pay_pay_agenttransaction set state=4 where payseriesno = #{payseriesno}and site_id= #{siteId} and customer_id= #{customerId}
  33. </update>
  34. <update id="cancelCheckAgentPayseriesno">
  35. update pay_pay_checkbalance set state=4
  36. where out_trade_no =(select order_no from pay_pay_agenttransaction where payseriesno=#{payseriesno} and site_id= #{siteId} and customer_id= #{customerId})
  37. </update>
  38. </mapper>