1;营销渠道AI/短信(普通,安全)-50%,差短信集成

This commit is contained in:
wangshuai 2024-07-22 16:33:42 +08:00
parent 60b171f166
commit 3b7a5fc95e
8 changed files with 60 additions and 3 deletions

View File

@ -254,10 +254,17 @@ public class BusStoreInfoController extends BaseController {
public AjaxResult getStoreConfig(@PathVariable("storeCode") String storeCode) { public AjaxResult getStoreConfig(@PathVariable("storeCode") String storeCode) {
BusStoreConfigInfo busStoreConfigInfo = new BusStoreConfigInfo(); BusStoreConfigInfo busStoreConfigInfo = new BusStoreConfigInfo();
busStoreConfigInfo.setStoreCode(storeCode); busStoreConfigInfo.setStoreCode(storeCode);
BusStoreInfo busStoreInfo = new BusStoreInfo();
busStoreInfo.setStoreCode(storeCode);
List<BusStoreInfo> busStoreInfoList = busStoreInfoService.selectBusStoreInfoList(busStoreInfo);
if(busStoreInfoList.size()==0){
return error("店铺信息异常!");
}
List<BusStoreConfigInfo> list = iBusStoreConfigInfoService.selectBusStoreConfigInfoList(busStoreConfigInfo); List<BusStoreConfigInfo> list = iBusStoreConfigInfoService.selectBusStoreConfigInfoList(busStoreConfigInfo);
if (list.size() == 0) { if (list.size() == 0) {
return success("新增配置"); return error("请新增配置!");
} else if (list.size() == 1) { } else if (list.size() == 1) {
list.get(0).setMarketingChannels(busStoreInfoList.get(0).getMarketingChannels());
return success(list.get(0)); return success(list.get(0));
} else { } else {
throw new ServiceException("数据重复!"); throw new ServiceException("数据重复!");

View File

@ -80,4 +80,7 @@ public class ReqBusStoreConfigInfo {
@JsonFormat(shape = JsonFormat.Shape.STRING) @JsonFormat(shape = JsonFormat.Shape.STRING)
private Long saleBindId; private Long saleBindId;
/** 备注 */
@ApiModelProperty(name = "渠道")
private String marketingChannels;
} }

View File

@ -84,6 +84,16 @@ public class BusStoreConfigInfo extends BaseEntity
@Excel(name = "备注") @Excel(name = "备注")
private String remark; private String remark;
private String marketingChannels;
public String getMarketingChannels() {
return marketingChannels;
}
public void setMarketingChannels(String marketingChannels) {
this.marketingChannels = marketingChannels;
}
@Excel(name = "归属销售id") @Excel(name = "归属销售id")
private Long saleBindId; private Long saleBindId;

View File

@ -191,6 +191,7 @@ public class BusStoreInfoServiceImpl implements IBusStoreInfoService
busStoreInfo.setSaleBindId(busSaleInfo.getId()); busStoreInfo.setSaleBindId(busSaleInfo.getId());
busStoreInfo.setSaleBindName(busSaleInfo.getSaleName()); busStoreInfo.setSaleBindName(busSaleInfo.getSaleName());
busStoreInfo.setSaleBindTime(new Date()); busStoreInfo.setSaleBindTime(new Date());
busStoreInfo.setMarketingChannels(busStoreConfigInfo.getMarketingChannels());
busStoreInfoMapper.updateBusStoreInfo(busStoreInfo); busStoreInfoMapper.updateBusStoreInfo(busStoreInfo);
}else{ }else{
throw new ServiceException("店铺信息异常!"); throw new ServiceException("店铺信息异常!");

View File

@ -115,6 +115,7 @@ public class MeituanServiceImpl implements IMeituanService {
storeInfo.setGrantStatus("1");//授权登录状态 storeInfo.setGrantStatus("1");//授权登录状态
storeInfo.setReturnVisitStatus("2");// 营销状态 storeInfo.setReturnVisitStatus("2");// 营销状态
storeInfo.setSelfDeliveryStatus("1");// 1 正常 2 自配送 3 删除 storeInfo.setSelfDeliveryStatus("1");// 1 正常 2 自配送 3 删除
storeInfo.setMarketingChannels("AI");// 默认渠道 sysDictDataMapper.selectDictLabel("bus_default_script","default_script")
busStoreInfoService.insertBusStoreInfo(storeInfo); busStoreInfoService.insertBusStoreInfo(storeInfo);
BusStoreDayInfo busStoreDayInfo = new BusStoreDayInfo(); BusStoreDayInfo busStoreDayInfo = new BusStoreDayInfo();
busStoreDayInfo.setStoreId(storeInfo.getId()); busStoreDayInfo.setStoreId(storeInfo.getId());
@ -155,7 +156,8 @@ public class MeituanServiceImpl implements IMeituanService {
storeInfo.setBindTime(date); storeInfo.setBindTime(date);
storeInfo.setGrantStatus("1");//授权登录状态 storeInfo.setGrantStatus("1");//授权登录状态
storeInfo.setReturnVisitStatus("2");// 营销状态 storeInfo.setReturnVisitStatus("2");// 营销状态
storeInfo.setSelfDeliveryStatus("1");// 1 正常 2 自配送 3 删除 storeInfo.setSelfDeliveryStatus("1");// 1 正常 2 自配送 3
storeInfo.setMarketingChannels("AI");
busStoreInfoService.insertBusStoreInfo(storeInfo); busStoreInfoService.insertBusStoreInfo(storeInfo);
BusStoreDayInfo busStoreDayInfo = new BusStoreDayInfo(); BusStoreDayInfo busStoreDayInfo = new BusStoreDayInfo();
busStoreDayInfo.setStoreId(storeInfo.getId()); busStoreDayInfo.setStoreId(storeInfo.getId());

View File

@ -27,10 +27,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="saleBindName" column="sale_bind_name" /> <result property="saleBindName" column="sale_bind_name" />
<result property="saleBindTime" column="sale_bind_time" /> <result property="saleBindTime" column="sale_bind_time" />
<result property="price" column="price" /> <result property="price" column="price" />
<result property="marketingChannels" column="marketing_channels" />
</resultMap> </resultMap>
<sql id="selectBusStoreInfoVo"> <sql id="selectBusStoreInfoVo">
select id, platform_type, store_code, store_name, store_account, store_password, store_cookie, store_belong, grant_status, return_visit_status, bind_id, bind_user, bind_time, update_id, update_user, update_time, self_delivery_status, return_visit_user_range, sale_bind_id, sale_bind_name, sale_bind_time, price from bus_store_info select id, platform_type, store_code, store_name, store_account, store_password, store_cookie, store_belong, grant_status, return_visit_status, bind_id, bind_user, bind_time, update_id, update_user, update_time, self_delivery_status, return_visit_user_range, sale_bind_id, sale_bind_name, sale_bind_time, price,marketing_channels from bus_store_info
</sql> </sql>
<select id="lastUserIntegralNum" parameterType="java.lang.String" resultType="java.lang.Integer"> <select id="lastUserIntegralNum" parameterType="java.lang.String" resultType="java.lang.Integer">
@ -112,6 +113,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="saleBindName != null">sale_bind_name,</if> <if test="saleBindName != null">sale_bind_name,</if>
<if test="saleBindTime != null">sale_bind_time,</if> <if test="saleBindTime != null">sale_bind_time,</if>
<if test="price != null">price,</if> <if test="price != null">price,</if>
<if test="marketingChannels != null">marketing_channels,</if>
</trim> </trim>
<trim prefix="values (" suffix=")" suffixOverrides=","> <trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="platformType != null">#{platformType},</if> <if test="platformType != null">#{platformType},</if>
@ -135,6 +137,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="saleBindName != null">#{saleBindName},</if> <if test="saleBindName != null">#{saleBindName},</if>
<if test="saleBindTime != null">#{saleBindTime},</if> <if test="saleBindTime != null">#{saleBindTime},</if>
<if test="price != null">#{price},</if> <if test="price != null">#{price},</if>
<if test="marketingChannels != null">#{price},</if>
</trim> </trim>
</insert> </insert>
@ -162,6 +165,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="saleBindName != null">sale_bind_name = #{saleBindName},</if> <if test="saleBindName != null">sale_bind_name = #{saleBindName},</if>
<if test="saleBindTime != null">sale_bind_time = #{saleBindTime},</if> <if test="saleBindTime != null">sale_bind_time = #{saleBindTime},</if>
<if test="price != null">price = #{price},</if> <if test="price != null">price = #{price},</if>
<if test="marketingChannels != null">marketing_channels = #{marketingChannels},</if>
</trim> </trim>
where id = #{id} where id = #{id}
</update> </update>

View File

@ -292,6 +292,21 @@
/> />
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="回访渠道" prop="marketing_channels">
<el-select
v-model="form.marketingChannels"
placeholder="回访渠道"
clearable
style="width: 240px"
>
<el-option
v-for="dict in dict.type.bus_marketing_channels"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
</el-select>
</el-form-item>
<el-form-item label="营销用户-下单次数 >=" prop="min_order_num"> <el-form-item label="营销用户-下单次数 >=" prop="min_order_num">
<el-input-number v-model="form.minOrderNum" placeholder="请输入营销下单次数" :min="1"/> <el-input-number v-model="form.minOrderNum" placeholder="请输入营销下单次数" :min="1"/>
</el-form-item> </el-form-item>

View File

@ -336,6 +336,21 @@
<i class="el-tooltip el-icon-question" tabindex="0" ></i> <i class="el-tooltip el-icon-question" tabindex="0" ></i>
</el-tooltip> </el-tooltip>
</el-form-item> </el-form-item>
<el-form-item label="回访渠道" prop="marketing_channels">
<el-select
v-model="form.marketingChannels"
placeholder="回访渠道"
clearable
style="width: 240px"
>
<el-option
v-for="dict in dict.type.bus_marketing_channels"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
</el-select>
</el-form-item>
<el-form-item label="营销用户-下单次数 >=" prop="min_order_num"> <el-form-item label="营销用户-下单次数 >=" prop="min_order_num">
<el-input-number v-model="form.minOrderNum" placeholder="请输入营销下单次数" :min="1"/> <el-input-number v-model="form.minOrderNum" placeholder="请输入营销下单次数" :min="1"/>
</el-form-item> </el-form-item>