1;模版内容

2;单个店铺同步按钮
3;店铺配置 拼好饭 限额默认关闭
This commit is contained in:
wangshuai 2024-07-19 14:18:17 +08:00
parent 43490093fd
commit 0cbccb8c2d
8 changed files with 43 additions and 22 deletions

View File

@ -205,6 +205,7 @@ public class BusStoreInfoController extends BaseController {
content = content.replaceAll("#good",busStoreDayInfo1.getLastPositiveReviewsNum()+"");
content = content.replaceAll("#five",busStoreDayInfo1.getLastFiveStarReviewsNum()+"");
content = content.replaceAll("#score",busStoreDayInfo1.getScore());
content = content.replaceAll("#QRCode","https://youshi.bj.cn/prod-api/profile/upload/2024/07/19/img0_20240719111559A001.jpg");
int a = busStoreDayInfo1.getLastPositiveReviewsNum();//todo 好评-五星
int b = busStoreDayInfo1.getLastReturnVisitNum();
if (a != 0 && b != 0) {

View File

@ -3,6 +3,8 @@ package com.ruoyi.business.controller;
import java.util.List;
import javax.servlet.http.HttpServletResponse;
import com.ruoyi.business.domain.BusTemplateAttrConfig;
import com.ruoyi.business.service.IBusTemplateAttrConfigService;
import com.ruoyi.common.utils.SecurityUtils;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
@ -39,6 +41,9 @@ public class BusTemplateInfoController extends BaseController
@Autowired
private IBusTemplateInfoService busTemplateInfoService;
@Autowired
private IBusTemplateAttrConfigService busTemplateAttrConfigService;
/**
* 查询模版列表
*/
@ -54,6 +59,14 @@ public class BusTemplateInfoController extends BaseController
return getDataTable(list);
}
@GetMapping("/listA")
public AjaxResult listA(BusTemplateAttrConfig busTemplateAttrConfig)
{
busTemplateAttrConfig.setTemplateType("word");
busTemplateAttrConfig.setAttrStatus("1");
List<BusTemplateAttrConfig> list = busTemplateAttrConfigService.selectBusTemplateAttrConfigList(busTemplateAttrConfig);
return AjaxResult.success(list);
}
/**
* 导出模版列表
*/

View File

@ -58,16 +58,6 @@ public class BusTemplateInfo extends BaseEntity
private List<BusTemplateAttrInfo> attrInfoList;
private List<BusTemplateAttrConfig> attrConfigList;
public List<BusTemplateAttrConfig> getAttrConfigList() {
return attrConfigList;
}
public void setAttrConfigList(List<BusTemplateAttrConfig> attrConfigList) {
this.attrConfigList = attrConfigList;
}
public List<BusTemplateAttrInfo> getAttrInfoList() {
return attrInfoList;
}

View File

@ -32,9 +32,6 @@ public class BusTemplateInfoServiceImpl implements IBusTemplateInfoService
@Autowired
private BusTemplateAttrInfoMapper busTemplateAttrInfoMapper;
@Autowired
private BusTemplateAttrConfigMapper busTemplateAttrConfigMapper;
@Autowired
private RuoYiConfig ruoyiConfig;
/**
@ -52,9 +49,7 @@ public class BusTemplateInfoServiceImpl implements IBusTemplateInfoService
List<BusTemplateAttrInfo> list1 = busTemplateAttrInfoMapper.selectBusTemplateAttrInfoList(busTemplateAttrInfo);
BusTemplateAttrConfig busTemplateAttrConfig = new BusTemplateAttrConfig();
busTemplateAttrConfig.setTemplateType("word");
List<BusTemplateAttrConfig> list2 = busTemplateAttrConfigMapper.selectBusTemplateAttrConfigList(busTemplateAttrConfig);
busTemplateInfo.setAttrInfoList(list1);
busTemplateInfo.setAttrConfigList(list2);
return busTemplateInfo;
}

View File

@ -123,6 +123,9 @@ public class MeituanServiceImpl implements IMeituanService {
busStoreDayInfoMapper.insertBusStoreDayInfo(busStoreDayInfo);
BusStoreConfigInfo busStoreConfigInfo = new BusStoreConfigInfo();
busStoreConfigInfo.setStoreCode(valueFromCookie("wmPoiId", cookie.getCookie()));
busStoreConfigInfo.setStoreName(storeInfo.getStoreName());
busStoreConfigInfo.setQuotaStatus("2");
busStoreConfigInfo.setIsSpliceOrder("N");
busStoreConfigInfoMapper.insertBusStoreConfigInfo(busStoreConfigInfo);
} else if (list.size() == 1) {

View File

@ -8,6 +8,13 @@ export function listTemplate(query) {
params: query
})
}
export function listTemplateAttr(query) {
return request({
url: '/business/template/listA',
method: 'get',
params: query
})
}
// 查询模版详细
export function getTemplate(id) {

View File

@ -197,12 +197,12 @@
<el-table-column label="操作" align="center" class-name="small-padding fixed-width" width =120>
<template slot-scope="scope">
<!-- <el-button v-if="userAccount !='admin' "
<el-button v-if="userAccount !='admin' "
size="mini"
type="text"
icon="el-icon-edit"
@click="handleComment(scope.row)"
>同步</el-button> -->
>同步</el-button>
<el-button v-if="userAccount !='admin' "
size="mini"
type="text"
@ -650,6 +650,7 @@ export default {
if(response.data.startTime != null&&response.data.endTime != null){
this.timeRange = [response.data.startTime,response.data.endTime];
}
this.changeQuotaStatus()
this.title = "编辑配置";
}else{
this.form.storeCode = row.storeCode;

View File

@ -93,8 +93,8 @@
<el-form-item label="模版名称" prop="templateName">
<el-input v-model="form.templateName" placeholder="请输入模版名称" />
</el-form-item>
<el-form-item label="内容">
<el-tag v-for="item in form.attrConfigList"
<el-form-item label="选择内容">
<el-tag v-for="item in attrConfigList"
:key="item.id"
size="small"
closable
@ -129,7 +129,7 @@
</template>
<script>
import { listTemplate, getTemplate, delTemplate, addTemplate, updateTemplate } from "@/api/statistics/template";
import { listTemplate, getTemplate, delTemplate, addTemplate, updateTemplate,listTemplateAttr } from "@/api/statistics/template";
export default {
name: "Template",
@ -150,6 +150,7 @@ export default {
total: 0,
//
templateList: [],
attrConfigList: [],
//
title: "",
//
@ -177,6 +178,7 @@ export default {
},
created() {
this.getList();
this.listTemplateAttr();
},
methods: {
/** 查询模版列表 */
@ -281,12 +283,21 @@ export default {
},
clickContent(event,content){
// console.log(event,content)
if(this.form.templateContent == null){
this.form.templateContent = '<p>'+content+'</p>'
}else{
this.form.templateContent += '<p>'+content+'</p>'
}
},
handleClose(content){
content = '<p>'+content+'</p>'
this.form.templateContent = this.form.templateContent.replace(content, '');
}
},
listTemplateAttr(){
listTemplateAttr({}).then(response => {
this.attrConfigList = response.data
});
},
}
};
</script>