| | |
| | | <=
|
| | | ]]>
|
| | | (SELECT d.`umd_createtime` FROM yeshi_ec_user_money_detail d WHERE
|
| | | d.`umd_id`=#{id}) and d.umd_uid=#{uid} and d.umd_show=1 order by d.`umd_createtime`
|
| | | d.`umd_id`=#{id}) and d.umd_uid=#{uid} and d.umd_show=1 |
| | | <if test="type == 1">and d.umd_money<![CDATA[>]]>0</if>
|
| | | <if test="type == 2">and d.umd_money<![CDATA[<=]]>0</if>
|
| | | order by d.`umd_createtime`
|
| | | desc,d.umd_id desc limit #{count}
|
| | | </select>
|
| | | <select id="selectCountByUid" resultType="java.lang.Long"
|
| | | parameterType="java.lang.Long">SELECT count(umd_id) FROM yeshi_ec_user_money_detail
|
| | | where umd_uid=#{uid} and umd_show=1 </select>
|
| | | where umd_uid=#{uid} and umd_show=1 |
| | | <if test="type == 1">and umd_money<![CDATA[>]]>0</if>
|
| | | <if test="type == 2">and umd_money<![CDATA[<=]]>0</if>
|
| | | </select>
|
| | | <select id="selectByMaxCreateTime" resultMap="BaseResultMap">
|
| | | SELECT
|
| | | <include refid="Base_Column_List" />
|
| | | FROM yeshi_ec_user_money_detail d WHERE d.umd_uid=#{uid} and d.umd_show=1 and
|
| | | d.`umd_createtime`<![CDATA[
|
| | | <=
|
| | | ]]>
|
| | | #{date} order by d.`umd_createtime` desc,d.umd_id desc limit #{count}
|
| | | FROM yeshi_ec_user_money_detail d WHERE d.umd_uid=#{uid} and d.umd_show=1 and d.`umd_createtime`<![CDATA[<=]]>#{date} |
| | | <if test="type == 1">and d.umd_money<![CDATA[>]]>0</if>
|
| | | <if test="type == 2">and d.umd_money<![CDATA[<=]]>0</if>
|
| | | order by d.`umd_createtime` desc,d.umd_id desc limit ${count}
|
| | | </select>
|
| | | <select id="selectCountByUidAndMaxCreateTime" resultType="java.lang.Long">SELECT
|
| | | count(umd_id) FROM yeshi_ec_user_money_detail where umd_uid=#{uid} and umd_show=1 and
|
| | | `umd_createtime`<![CDATA[
|
| | | <=
|
| | | ]]>
|
| | | #{date}
|
| | | `umd_createtime`<![CDATA[<=]]>#{date}
|
| | | <if test="type == 1">and umd_money<![CDATA[>]]>0</if>
|
| | | <if test="type == 2">and umd_money<![CDATA[<=]]>0</if>
|
| | | </select>
|
| | | <select id="selectMonthCountByUid" resultType="java.lang.Integer">SELECT
|
| | | COUNT(*) FROM (SELECT * FROM yeshi_ec_user_money_detail d WHERE
|
| | | d.`umd_uid`=#{uid} and d.umd_show=1 and d.`umd_createtime` <![CDATA[<=]]>
|
| | | #{date} group by DATE_FORMAT(d.`umd_createtime`,'%y-%m')) a
|
| | | #{date} |
| | | <if test="type == 1">and d.umd_money<![CDATA[>]]>0</if>
|
| | | <if test="type == 2">and d.umd_money<![CDATA[<=]]>0</if>
|
| | | group by DATE_FORMAT(d.`umd_createtime`,'%y-%m')) a
|
| | | </select>
|
| | | <select id="selectMonthMoneyByUid" resultMap="UserMonthMoneyMap">
|
| | | <foreach collection="dateFormat" index="index" item="item"
|