加盟意向

This commit is contained in:
guohb
2024-03-22 14:58:52 +08:00
parent 2f005d64cc
commit 75efae07d5
7 changed files with 225 additions and 0 deletions

View File

@@ -0,0 +1,11 @@
package com.cool.store.mapper;
import com.cool.store.request.JoinIntentionRequest;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
@Mapper
public interface JoinIntentionMapper {
boolean insert(@Param("request") JoinIntentionRequest request);
}

View File

@@ -0,0 +1,69 @@
<?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.cool.store.mapper.JoinIntentionMapper">
<resultMap id="BaseResultMap" type="com.cool.store.entity.PartnerBaseInfoDO">
<id column="id" jdbcType="BIGINT" property="id" />
<result column="partner_id" jdbcType="VARCHAR" property="partnerId" />
<result column="line_id" jdbcType="BIGINT" property="lineId"/>
<result column="join_type" jdbcType="TINYINT" property="joinType"/>
<result column="mobile" jdbcType="VARCHAR" property="mobile" />
<result column="sex" jdbcType="TINYINT" property="sex" />
<result column="username" jdbcType="VARCHAR" property="username" />
<result column="want_shop_area" jdbcType="VARCHAR" property="wantShopArea" />
<result column="area_code" jdbcType="VARCHAR" property="areaCode" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="live_area" jdbcType="VARCHAR" property="liveArea"/>
<result column="live_address" jdbcType="VARCHAR" property="liveAddress"/>
<result column="joining_questionnaire" jdbcType="VARCHAR" property="joiningQuestionnaire"/>
<result column="deleted" jdbcType="TINYINT" property="deleted"/>
</resultMap>
<sql id="Base_Column_List">
id,
partner_id,
line_id,
join_type,
mobile,
sex,
username,
want_shop_area,
area_code,
create_time,
update_time,
live_area,
live_address,
joining_questionnaire,
deleted
</sql>
<insert id="insert" parameterType="com.cool.store.request.JoinIntentionRequest" useGeneratedKeys="true" keyProperty="id">
insert into xfsg_partner_base_info
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="request.lineId != null">line_id,</if>
<if test="request.partnerId != null">partner_id,</if>
<if test="request.joinType != null">join_type,</if>
<if test="request.userName != null">username,</if>
<if test="request.mobile != null">mobile,</if>
<if test="request.sex != null">sex,</if>
<if test="request.wantShopArea != null">want_shop_area,</if>
<if test="request.areaCode != null">area_code,</if>
<if test="request.liveArea != null">live_area,</if>
<if test="request.liveAddress != null">live_address,</if>
<if test="request.joiningQuestionnaire != null">joining_questionnaire,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="request.lineId != null">#{request.lineId},</if>
<if test="request.partnerId != null">#{request.partnerId},</if>
<if test="request.joinType != null">#{request.joinType},</if>
<if test="request.userName != null">#{request.userName},</if>
<if test="request.mobile != null">#{request.mobile},</if>
<if test="request.sex != null">#{request.sex},</if>
<if test="request.wantShopArea != null">#{request.wantShopArea},</if>
<if test="request.areaCode != null">#{request.areaCode},</if>
<if test="request.liveArea != null">#{request.liveArea},</if>
<if test="request.liveAddress != null">#{request.liveAddress},</if>
<if test="request.joiningQuestionnaire != null">#{request.joiningQuestionnaire},</if>
</trim>
</insert>
</mapper>