From 554de444b87aab5f93cb1593a8095612cf9479a7 Mon Sep 17 00:00:00 2001 From: yujian <yujian@163.com> Date: 星期二, 09 六月 2020 17:34:30 +0800 Subject: [PATCH] 订单 --- fanli/src/main/java/com/yeshi/fanli/mapping/ExtractMapper.xml | 40 +++++++++++++++++++++++++++++++++++++++- 1 files changed, 39 insertions(+), 1 deletions(-) diff --git a/fanli/src/main/java/com/yeshi/fanli/mapping/ExtractMapper.xml b/fanli/src/main/java/com/yeshi/fanli/mapping/ExtractMapper.xml index 3ceb70e..997a86d 100644 --- a/fanli/src/main/java/com/yeshi/fanli/mapping/ExtractMapper.xml +++ b/fanli/src/main/java/com/yeshi/fanli/mapping/ExtractMapper.xml @@ -22,8 +22,33 @@ <association property="system" column="sid" select="com.yeshi.fanli.dao.mybatis.BusinessSystemMapper.selectByPrimaryKey"> </association> - </resultMap> + + + <resultMap id="SimplMap" type="com.yeshi.fanli.entity.bus.user.Extract"> + <id column="id" property="id" jdbcType="BIGINT" /> + <result column="account" property="account" jdbcType="VARCHAR" /> + <result column="extractTime" property="extractTime" jdbcType="BIGINT" /> + <result column="receiveTime" property="receiveTime" jdbcType="TIMESTAMP" /> + <result column="ip" property="ip" jdbcType="VARCHAR" /> + <result column="money" property="money" jdbcType="DECIMAL" /> + <result column="name" property="name" jdbcType="VARCHAR" /> + <result column="reason" property="reason" jdbcType="VARCHAR" /> + <result column="state" property="state" jdbcType="INTEGER" /> + <result column="type" property="type" jdbcType="INTEGER" /> + <result column="adminId" property="adminId" jdbcType="BIGINT" /> + + <association column="uid" property="userInfo" javaType="com.yeshi.fanli.entity.bus.user.UserInfo"> + <id column="uid" property="id" jdbcType="BIGINT" /> + </association> + + <association column="sid" property="system" javaType="com.yeshi.fanli.entity.system.BusinessSystem"> + <id column="sid" property="id" jdbcType="BIGINT" /> + </association> + </resultMap> + + + <sql id="Base_Column_List"> id,account,extractTime,ip,money,name,reason,state,type,uid,sid,adminId,receiveTime </sql> @@ -428,4 +453,17 @@ </select> + <select id="getExtractSucceedRecord" resultMap="SimplMap"> + SELECT * FROM yeshi_ec_extract t + WHERE t.`uid` = #{uid} AND t.`state` = 1 + ORDER BY t.`id` DESC + LIMIT #{start},#{count} + </select> + + + <select id="countExtractSucceedRecord" resultType="Long"> + SELECT COUNT(t.`id`) FROM yeshi_ec_extract t + WHERE t.`uid` = #{uid} AND t.`state` = 1 + </select> + </mapper> \ No newline at end of file -- Gitblit v1.8.0