Commit 84f3c9a3 by chenwq

加字段,样式,sop-SOP

1 parent 23e3d09e
...@@ -181,7 +181,7 @@ export default { ...@@ -181,7 +181,7 @@ export default {
} }
], ],
editRule: { editRule: {
sopName: [{ required: true, message: '请输入sop名字', trigger: 'change' }], sopName: [{ required: true, message: '请输入SOP名称', trigger: 'change' }],
eventStartDate: [{ required: true, message: '请选择营销开始日期', trigger: 'change' }], eventStartDate: [{ required: true, message: '请选择营销开始日期', trigger: 'change' }],
eventTime: [{ required: true, message: '请选择营销时间', trigger: 'change' }], eventTime: [{ required: true, message: '请选择营销时间', trigger: 'change' }],
eventEndDate: [{ required: true, message: '请选择营销结束日期', trigger: 'change' }], eventEndDate: [{ required: true, message: '请选择营销结束日期', trigger: 'change' }],
...@@ -192,7 +192,7 @@ export default { ...@@ -192,7 +192,7 @@ export default {
isEdit: true, isEdit: true,
sopNameFormData: [ sopNameFormData: [
{ {
label: 'sop名字', label: 'SOP名称',
name: 'sopName', name: 'sopName',
type: 'showTxt' type: 'showTxt'
} }
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
<p class="box-txt">锁定目标客户群,设置触发时间、场景事件、策略内容和触点,自动触发场景营销SOP推送,完成保养提醒、事故车送修等智能线索推送、新用户培育、客户关怀、激活沉默客户、转化复购等。</p> <p class="box-txt">锁定目标客户群,设置触发时间、场景事件、策略内容和触点,自动触发场景营销SOP推送,完成保养提醒、事故车送修等智能线索推送、新用户培育、客户关怀、激活沉默客户、转化复购等。</p>
<div class="flex-center"> <div class="flex-center">
<p class="step-circle">1</p> <p class="step-circle">1</p>
<p class="step-txt">创建sop</p> <p class="step-txt">创建SOP</p>
<p class="step-line"></p> <p class="step-line"></p>
<p class="step-circle">2</p> <p class="step-circle">2</p>
<p class="step-txt">添加推送客户</p> <p class="step-txt">添加推送客户</p>
...@@ -269,7 +269,7 @@ export default { ...@@ -269,7 +269,7 @@ export default {
position: absolute; position: absolute;
top: 0; top: 0;
left: 0; left: 0;
background: #f4f5fa; background: rgba(244, 244, 252, 0.85);
padding: 28px 0; padding: 28px 0;
.btn-item { .btn-item {
display: block; display: block;
......
...@@ -150,7 +150,7 @@ export default { ...@@ -150,7 +150,7 @@ export default {
let chartDom = document.getElementById('completePie') let chartDom = document.getElementById('completePie')
let myChart = echarts.init(chartDom) let myChart = echarts.init(chartDom)
let option = JSON.parse(JSON.stringify(pieOption)) let option = JSON.parse(JSON.stringify(pieOption))
// console.log(this.sopInfo.sopStatistics.issuedTaskCount)
option.series[0].data = [ option.series[0].data = [
{ {
value: this.sopInfo.sopStatistics.finishTaskCount, value: this.sopInfo.sopStatistics.finishTaskCount,
......
...@@ -21,20 +21,20 @@ ...@@ -21,20 +21,20 @@
客户总数 客户总数
<img src="@/assets/sop/customer-total.png" /> <img src="@/assets/sop/customer-total.png" />
</div> </div>
<p class="analysis-num">{{ sopInfo.customerCount || '-' }}</p> <p class="analysis-num">{{ baseData.sopEventList.length ? sopInfo.customerCount : '-' }}</p>
</div> </div>
<div class="analysis-block"> <div class="analysis-block">
<div class="analysis-title-block m-b-20"> <div class="analysis-title-block m-b-20">
已触达客户数 已触达客户数
<img src="@/assets/sop/touch-customer.png" /> <img src="@/assets/sop/touch-customer.png" />
</div> </div>
<p class="analysis-num">{{ selectedEventInfo.eventStatistics ? selectedEventInfo.eventStatistics.reachCustomerCount : '-' }}</p> <p class="analysis-num">{{ baseData.sopEventList.length ? selectedEventInfo.eventStatistics.reachCustomerCount : '-' }}</p>
</div> </div>
<div class="analysis-block"> <div class="analysis-block">
<div class="analysis-title-block m-b-20"> <div class="analysis-title-block m-b-20">
触达率 触达率
</div> </div>
<p class="analysis-num">{{ sopInfo.touchPercent + '%' }}</p> <p class="analysis-num">{{ sopInfo.touchPercent }}</p>
<div id="completePie" class="chart-pie"></div> <div id="completePie" class="chart-pie"></div>
</div> </div>
</div> </div>
...@@ -103,7 +103,10 @@ export default { ...@@ -103,7 +103,10 @@ export default {
{ {
label: '客户手机号', label: '客户手机号',
prop: 'customerPhone', prop: 'customerPhone',
width: '110' width: '110',
formatter: cellValue => {
return cellValue.customerPhone || '-'
}
}, },
{ {
label: '初次查看事件', label: '初次查看事件',
...@@ -143,7 +146,7 @@ export default { ...@@ -143,7 +146,7 @@ export default {
getBaseInfo() { getBaseInfo() {
this.$apis.sop.getSopBaseInfoApi({ sopId: this.sopId }).then(res => { this.$apis.sop.getSopBaseInfoApi({ sopId: this.sopId }).then(res => {
this.sopInfo = res this.sopInfo = res
this.sopInfo.touchPercent = Math.round((this.selectedEventInfo.eventStatistics.reachCustomerCount / this.sopInfo.customerCount) * 100).toFixed(0) this.sopInfo.touchPercent = this.baseData.sopEventList.length ? Math.round((this.selectedEventInfo.eventStatistics.reachCustomerCount / this.sopInfo.customerCount) * 100).toFixed(0) + '%' : '-'
this.drawPie() this.drawPie()
}) })
}, },
...@@ -163,12 +166,14 @@ export default { ...@@ -163,12 +166,14 @@ export default {
this.$apis.sop.getEventListApi(params).then(res => { this.$apis.sop.getEventListApi(params).then(res => {
this.baseData.sopEventList = res.list this.baseData.sopEventList = res.list
console.log(res) console.log(res)
this.baseData.sopEventList.forEach(item => { if (this.baseData.sopEventList.length) {
item.confName = item.eventStartDate + (item.repeatFlag == 'Y' ? '-' + item.eventEndDate : '') + ' ' + item.eventTime + ' ' + pushChannelTypeList[item.pushChannelType] this.baseData.sopEventList.forEach(item => {
}) item.confName = item.eventStartDate + (item.repeatFlag == 'Y' ? '-' + item.eventEndDate : '') + ' ' + item.eventTime + ' ' + pushChannelTypeList[item.pushChannelType]
this.getOptionsList('searchFormData', false) })
this.searchForm.eventId = this.baseData.sopEventList[0].id this.getOptionsList('searchFormData', false)
this.selectedEventInfo = this.baseData.sopEventList[0] this.searchForm.eventId = this.baseData.sopEventList[0].id
this.selectedEventInfo = this.baseData.sopEventList[0]
}
this.getBaseInfo() this.getBaseInfo()
this.$refs.touchListRef.refreshTable() this.$refs.touchListRef.refreshTable()
}) })
...@@ -261,24 +266,26 @@ export default { ...@@ -261,24 +266,26 @@ export default {
}, },
drawPie() { drawPie() {
let chartDom = document.getElementById('completePie') if (this.baseData.sopEventList.length) {
let myChart = echarts.init(chartDom) let chartDom = document.getElementById('completePie')
let option = JSON.parse(JSON.stringify(pieOption)) let myChart = echarts.init(chartDom)
let option = JSON.parse(JSON.stringify(pieOption))
option.series[0].data = [ option.series[0].data = [
{ {
value: this.selectedEventInfo.eventStatistics.reachCustomerCount, value: this.selectedEventInfo.eventStatistics.reachCustomerCount ? this.selectedEventInfo.eventStatistics.reachCustomerCount : 0,
name: '已触达的客户数' name: '已触达的客户数'
}, },
{ {
value: this.sopInfo.customerCount - this.selectedEventInfo.eventStatistics.reachCustomerCount, value: this.sopInfo.customerCount - this.selectedEventInfo.eventStatistics.reachCustomerCount,
name: '未触达的客户数' name: '未触达的客户数'
} }
] ]
console.log(option) console.log(option)
option && myChart.setOption(option) option && myChart.setOption(option)
}
} }
// handleSearch() { // handleSearch() {
......
...@@ -46,7 +46,7 @@ export default { ...@@ -46,7 +46,7 @@ export default {
// 搜索 // 搜索
searchFormData: [ searchFormData: [
{ {
label: 'sop名称', label: 'SOP名称',
name: 'sopName', name: 'sopName',
type: 'input', type: 'input',
isClear: true, isClear: true,
...@@ -69,7 +69,7 @@ export default { ...@@ -69,7 +69,7 @@ export default {
tableOption: true, tableOption: true,
tableColumns: [ tableColumns: [
{ {
label: 'sop名称', label: 'SOP名称',
prop: 'sopName' prop: 'sopName'
}, },
{ {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!