后台服务
Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.

30 rader
1.4 KiB

  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.iformall.mapper.WxCUserAuthorityMapper">
  4. <resultMap id="BaseResultMap" type="com.iformall.domain.po.WxCUserAuthority">
  5. <result column="user_name" jdbcType="VARCHAR" property="userName"/>
  6. <result column="type" jdbcType="VARCHAR" property="type"/>
  7. <result column="resource_id" jdbcType="VARCHAR" property="resourceId"/>
  8. <result column="class" jdbcType="VARCHAR" property="classType"/>
  9. <result column="expire_time" jdbcType="VARCHAR" property="expireTime"/>
  10. <result column="current_time" jdbcType="VARCHAR" property="expireTime"/>
  11. </resultMap>
  12. <select id="getAuthorAvatar" resultType="com.iformall.domain.po.WxCUserAuthority">
  13. select wca.user_name,wca.type,wca.resource_id,wca.expire_time,wcav.class
  14. from wx_c_author wca
  15. join wx_c_avatar wcav on wca.resource_id = wcav.id and wca.type = 0
  16. where wca.user_name=#{username} and wca.resource_id = #{resourceId}
  17. </select>
  18. <select id="getAuthorVoice" resultType="com.iformall.domain.po.WxCUserAuthority">
  19. select wca.user_name,wca.type,wca.resource_id,wca.expire_time,wcv.class
  20. from wx_c_author wca
  21. join wx_c_voice wcv on wca.resource_id =wcv.id and wca.type = 1
  22. where wca.user_name=#{username} and wca.resource_id = #{resourceId}
  23. </select>
  24. </mapper>