yujian
2019-08-16 634f742f86ebc78a742f032164cb8b45bb328941
赠送记录
3个文件已添加
99 ■■■■■ 已修改文件
fanli/src/main/java/com/yeshi/fanli/mapping/tlj/UserTaoLiJinGiveRecordMapper.xml 51 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/tlj/UserTaoLiJinGiveRecordServiceImpl.java 32 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/inter/tlj/UserTaoLiJinGiveRecordService.java 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/mapping/tlj/UserTaoLiJinGiveRecordMapper.xml
New file
@@ -0,0 +1,51 @@
<?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.yeshi.fanli.dao.mybatis.tlj.UserTaoLiJinGiveRecordMapper">
  <resultMap id="BaseResultMap" type="com.yeshi.fanli.entity.bus.tlj.UserTaoLiJinGiveRecord">
    <id column="tgr_id" property="id" jdbcType="BIGINT"/>
    <result column="tgr_amount" property="amount" jdbcType="DECIMAL"/>
    <result column="tgr_give_uid" property="giveUid" jdbcType="BIGINT"/>
    <result column="tgr_receive_uid" property="receiveUid" jdbcType="BIGINT"/>
    <result column="tgr_give_time" property="giveTime" jdbcType="TIMESTAMP"/>
    <result column="tgr_receive_time" property="receiveTime" jdbcType="TIMESTAMP"/>
    <result column="tgr_state" property="state" jdbcType="INTEGER"/>
  </resultMap>
  <sql id="Base_Column_List">tgr_id,tgr_amount,tgr_give_uid,tgr_receive_uid,tgr_give_time,tgr_receive_time,tgr_state</sql>
  <select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.Long">select
    <include refid="Base_Column_List"/>from yeshi_ec_user_taolijin_give_record where tgr_id = #{id,jdbcType=BIGINT}
  </select>
  <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">delete from yeshi_ec_user_taolijin_give_record where tgr_id = #{id,jdbcType=BIGINT}</delete>
  <insert id="insert" parameterType="com.yeshi.fanli.entity.bus.tlj.UserTaoLiJinGiveRecord" useGeneratedKeys="true" keyProperty="id">insert into yeshi_ec_user_taolijin_give_record (tgr_id,tgr_amount,tgr_give_uid,tgr_receive_uid,tgr_give_time,tgr_receive_time,tgr_state) values (#{id,jdbcType=BIGINT},#{amount,jdbcType=DECIMAL},#{giveUid,jdbcType=BIGINT},#{receiveUid,jdbcType=BIGINT},#{giveTime,jdbcType=TIMESTAMP},#{receiveTime,jdbcType=TIMESTAMP},#{state,jdbcType=INTEGER})</insert>
  <insert id="insertSelective" parameterType="com.yeshi.fanli.entity.bus.tlj.UserTaoLiJinGiveRecord" useGeneratedKeys="true" keyProperty="id">insert into yeshi_ec_user_taolijin_give_record
    <trim prefix="(" suffix=")" suffixOverrides=",">
      <if test="id != null">tgr_id,</if>
      <if test="amount != null">tgr_amount,</if>
      <if test="giveUid != null">tgr_give_uid,</if>
      <if test="receiveUid != null">tgr_receive_uid,</if>
      <if test="giveTime != null">tgr_give_time,</if>
      <if test="receiveTime != null">tgr_receive_time,</if>
      <if test="state != null">tgr_state,</if>
    </trim>values
    <trim prefix="(" suffix=")" suffixOverrides=",">
      <if test="id != null">#{id,jdbcType=BIGINT},</if>
      <if test="amount != null">#{amount,jdbcType=DECIMAL},</if>
      <if test="giveUid != null">#{giveUid,jdbcType=BIGINT},</if>
      <if test="receiveUid != null">#{receiveUid,jdbcType=BIGINT},</if>
      <if test="giveTime != null">#{giveTime,jdbcType=TIMESTAMP},</if>
      <if test="receiveTime != null">#{receiveTime,jdbcType=TIMESTAMP},</if>
      <if test="state != null">#{state,jdbcType=INTEGER},</if>
    </trim>
  </insert>
  <update id="updateByPrimaryKey" parameterType="com.yeshi.fanli.entity.bus.tlj.UserTaoLiJinGiveRecord">update yeshi_ec_user_taolijin_give_record set tgr_amount = #{amount,jdbcType=DECIMAL},tgr_give_uid = #{giveUid,jdbcType=BIGINT},tgr_receive_uid = #{receiveUid,jdbcType=BIGINT},tgr_give_time = #{giveTime,jdbcType=TIMESTAMP},tgr_receive_time = #{receiveTime,jdbcType=TIMESTAMP},tgr_state = #{state,jdbcType=INTEGER} where tgr_id = #{id,jdbcType=BIGINT}</update>
  <update id="updateByPrimaryKeySelective" parameterType="com.yeshi.fanli.entity.bus.tlj.UserTaoLiJinGiveRecord">update yeshi_ec_user_taolijin_give_record
    <set>
      <if test="amount != null">tgr_amount=#{amount,jdbcType=DECIMAL},</if>
      <if test="giveUid != null">tgr_give_uid=#{giveUid,jdbcType=BIGINT},</if>
      <if test="receiveUid != null">tgr_receive_uid=#{receiveUid,jdbcType=BIGINT},</if>
      <if test="giveTime != null">tgr_give_time=#{giveTime,jdbcType=TIMESTAMP},</if>
      <if test="receiveTime != null">tgr_receive_time=#{receiveTime,jdbcType=TIMESTAMP},</if>
      <if test="state != null">tgr_state=#{state,jdbcType=INTEGER},</if>
    </set> where tgr_id = #{id,jdbcType=BIGINT}
  </update>
</mapper>
fanli/src/main/java/com/yeshi/fanli/service/impl/tlj/UserTaoLiJinGiveRecordServiceImpl.java
New file
@@ -0,0 +1,32 @@
package com.yeshi.fanli.service.impl.tlj;
import javax.annotation.Resource;
import org.springframework.stereotype.Service;
import com.yeshi.fanli.dao.mybatis.tlj.UserTaoLiJinGiveRecordMapper;
import com.yeshi.fanli.entity.bus.tlj.UserTaoLiJinGiveRecord;
import com.yeshi.fanli.service.inter.tlj.UserTaoLiJinGiveRecordService;
@Service
public class UserTaoLiJinGiveRecordServiceImpl implements UserTaoLiJinGiveRecordService {
    @Resource
    private UserTaoLiJinGiveRecordMapper userTaoLiJinGiveRecordMapper;
    @Override
    public void insertSelective(UserTaoLiJinGiveRecord record) {
        userTaoLiJinGiveRecordMapper.insertSelective(record);
    }
    @Override
    public UserTaoLiJinGiveRecord selectByPrimaryKey(Long id) {
        return userTaoLiJinGiveRecordMapper.selectByPrimaryKey(id);
    }
    @Override
    public void updateByPrimaryKeySelective(UserTaoLiJinGiveRecord record) {
        userTaoLiJinGiveRecordMapper.updateByPrimaryKeySelective(record);
    }
}
fanli/src/main/java/com/yeshi/fanli/service/inter/tlj/UserTaoLiJinGiveRecordService.java
New file
@@ -0,0 +1,16 @@
package com.yeshi.fanli.service.inter.tlj;
import com.yeshi.fanli.entity.bus.tlj.UserTaoLiJinGiveRecord;
public interface UserTaoLiJinGiveRecordService {
    public void insertSelective(UserTaoLiJinGiveRecord record);
    public UserTaoLiJinGiveRecord selectByPrimaryKey(Long id);
    public void updateByPrimaryKeySelective(UserTaoLiJinGiveRecord record);
}