意向加盟逻辑&DB更改

This commit is contained in:
guohb
2024-03-27 15:04:12 +08:00
parent 5b0f864d61
commit ea2227ead7
10 changed files with 587 additions and 74 deletions

View File

@@ -30,8 +30,207 @@
<result column="update_user_id" jdbcType="VARCHAR" property="updateUserId" />
<result column="deleted" jdbcType="BIT" property="deleted" />
</resultMap>
<insert id="insertOrUpdate" parameterType="com.cool.store.entity.LineInfoDO" useGeneratedKeys="true" keyProperty="id">
INSERT INTO xfsg_line_info
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="param.id != null and param.id != ''">
id,
</if>
<if test="param.partnerId != null and param.partnerId != ''">
partner_id,
</if>
<if test="param.regionId != null">
region_id,
</if>
<if test="param.mobile != null and param.mobile != ''">
mobile,
</if>
<if test="param.username != null and param.username != ''">
username,
</if>
<if test="param.sex != null and param.sex != ''">
sex,
</if>
<if test="param.wantShopAreaId != null">
want_shop_area_id,
</if>
<if test="param.liveAddress != null and param.liveAddress != ''">
live_address,
</if>
<if test="param.workflowStage != null">
workflow_stage,
</if>
<if test="param.workflowSubStage != null">
workflow_sub_stage,
</if>
<if test="param.workflowSubStageStatus != null">
workflow_sub_stage_status,
</if>
<if test="param.selectSiteNum != null">
select_site_num,
</if>
<if test="param.prepareShopNum != null">
prepare_shop_num,
</if>
<if test="param.openShopNum != null">
open_shop_num,
</if>
<if test="param.lineSource != null">
line_source,
</if>
<if test="param.investmentManager != null and param.investmentManager != ''">
investment_manager,
</if>
<if test="param.developmentManager != null and param.developmentManager != ''">
development_manager,
</if>
<if test="param.firstInterviewer != null and param.firstInterviewer != ''">
first_interviewer,
</if>
<if test="param.secondInterviewer != null and param.secondInterviewer != ''">
second_interviewer,
</if>
<if test="param.userPortrait != null and param.userPortrait != ''">
user_portrait,
</if>
<if test="param.isJoin != null">
is_join,
</if>
<if test="param.lineStatus != null">
line_status,
</if>
<if test="param.createTime != null">
create_time,
</if>
<if test="param.updateTime != null">
update_time,
</if>
<if test="param.createUserId != null and param.createUserId != ''">
create_user_id,
</if>
<if test="param.updateUserId != null and param.updateUserId != ''">
update_user_id,
</if>
<if test="param.deleted != null">
deleted
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="param.id != null and param.id != ''">
#{param.id},
</if>
<if test="param.partnerId != null and param.partnerId != ''">
#{param.partnerId},
</if>
<if test="param.regionId != null">
#{param.regionId},
</if>
<if test="param.mobile != null and param.mobile != ''">
#{param.mobile},
</if>
<if test="param.username != null and param.username != ''">
#{param.username},
</if>
<if test="param.sex != null and param.sex != ''">
#{param.sex},
</if>
<if test="param.wantShopAreaId != null">
#{param.wantShopAreaId},
</if>
<if test="param.liveAddress != null and param.liveAddress != ''">
#{param.liveAddress},
</if>
<if test="param.workflowStage != null">
#{param.workflowStage},
</if>
<if test="param.workflowSubStage != null">
#{param.workflowSubStage},
</if>
<if test="param.workflowSubStageStatus != null">
#{param.workflowSubStageStatus},
</if>
<if test="param.selectSiteNum != null">
#{param.selectSiteNum},
</if>
<if test="param.prepareShopNum != null">
#{param.prepareShopNum},
</if>
<if test="param.openShopNum != null">
#{param.openShopNum},
</if>
<if test="param.lineSource != null">
#{param.lineSource},
</if>
<if test="param.investmentManager != null and param.investmentManager != ''">
#{param.investmentManager},
</if>
<if test="param.developmentManager != null and param.developmentManager != ''">
#{param.developmentManager},
</if>
<if test="param.firstInterviewer != null and param.firstInterviewer != ''">
#{param.firstInterviewer},
</if>
<if test="param.secondInterviewer != null and param.secondInterviewer != ''">
#{param.secondInterviewer},
</if>
<if test="param.userPortrait != null and param.userPortrait != ''">
#{param.userPortrait},
</if>
<if test="param.isJoin != null">
#{param.isJoin},
</if>
<if test="param.lineStatus != null">
#{param.lineStatus},
</if>
<if test="param.createTime != null">
#{param.createTime},
</if>
<if test="param.updateTime != null">
#{param.updateTime},
</if>
<if test="param.createUserId != null and param.createUserId != ''">
#{param.createUserId},
</if>
<if test="param.updateUserId != null and param.updateUserId != ''">
#{param.updateUserId},
</if>
<if test="param.deleted != null">
#{param.deleted}
</if>
</trim>
ON DUPLICATE KEY UPDATE
<trim suffixOverrides=",">
<if test="param.partnerId != null and param.partnerId != ''">
partner_id = #{param.partnerId},
</if>
<if test="param.regionId != null">
region_id = #{param.regionId},
</if>
<if test="param.mobile != null and param.mobile != ''">
mobile = #{param.mobile},
</if>
<if test="param.username != null and param.username != ''">
username = #{param.username},
</if>
<if test="param.sex != null and param.sex != ''">
sex = #{param.sex},
</if>
<if test="param.wantShopAreaId != null">
want_shop_area_id = #{param.wantShopAreaId},
</if>
<if test="param.liveAddress != null and param.liveAddress != ''">
live_address = #{param.liveAddress},
</if>
<if test="param.workflowStage != null">
workflow_stage = #{param.workflowStage},
</if>
<if test="param.workflowSubStage != null">
workflow_sub_stage = #{param.workflowSubStage}
</if>
</trim>
</insert>
<select id="getByPartnerId" resultMap="BaseResultMap">
<select id="getByPartnerId" resultMap="BaseResultMap">
select * from xfsg_line_info where partner_id = #{partnerId} and deleted = 0
</select>
<select id="getByLineId" resultType="com.cool.store.entity.LineInfoDO">