1234567891011121314151617181920212223242526272829 |
- <?xml version="1.0" encoding="UTF-8" ?>
- <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
- <mapper namespace= "com.juxiao.xchat.module.xbd.mapper.system.FeedbackMapper" >
- <resultMap id="BaseResultMap" type="com.juxiao.xchat.module.xbd.domain.system.Feedback" >
- <id column="uid" property="uid" jdbcType="BIGINT" />
- <result column="erban_no" property="erbanNo" jdbcType="BIGINT" />
- <result column="feedback_desc" property="feedbackDesc" jdbcType="VARCHAR" />
- <result column="img_url" property="imgUrl" jdbcType="VARCHAR" />
- <result column="contact" property="contact" jdbcType="VARCHAR" />
- <result column="create_time" property="createTime" jdbcType="TIMESTAMP" />
- </resultMap>
- <select id="getFeedbackList" resultMap="BaseResultMap" >
- select fb.uid, u.erban_no, fb.feedback_desc, fb.img_url, fb.contact, fb.create_time
- from feedback fb
- INNER JOIN users u on fb.uid = u.uid
- where 1 = 1
- <if test="erbanNo!=null and erbanNo!=''">
- AND u.erban_no=#{erbanNo}
- </if>
- <if test="beginDate!=null and beginDate!=''">
- AND fb.create_time >= #{beginDate}
- </if>
- <if test="endDate!=null and endDate!=''">
- AND fb.create_time <= #{endDate}
- </if>
- ORDER BY fb.create_time desc
- </select>
- </mapper>
|