Commit 10a12ccd by chenwq

sop分析

1 parent 8d52fa79
...@@ -15,14 +15,26 @@ ...@@ -15,14 +15,26 @@
</div> </div>
<p class="analysis-num">{{ sopInfo.sopStatistics ? sopInfo.sopStatistics.eventCount : '-' }}</p> <p class="analysis-num">{{ sopInfo.sopStatistics ? sopInfo.sopStatistics.eventCount : '-' }}</p>
</div> </div>
<div class="analysis-block"> <div class="analysis-block back-image-green">
<div class="analysis-title-block m-b-20"> <div class="analysis-title-block m-b-20">
已完成事件数 已完成事件数
<img src="@/assets/sop/completed-event.png" /> <img src="@/assets/sop/completed-event.png" />
</div> </div>
<p class="analysis-num">{{ sopInfo.sopStatistics ? sopInfo.sopStatistics.finishEventCount : '-' }}</p> <p class="analysis-num">{{ sopInfo.sopStatistics ? sopInfo.sopStatistics.finishEventCount : '-' }}</p>
</div> </div>
<div class="analysis-block"> <div class="analysis-block back-image-orange">
<div class="analysis-title-block m-b-20">
<div>
失败事件数
<el-popover placement="top" width="200" trigger="hover" content="因企微、短信等限制无法正常执行的事件">
<img slot="reference" class="tips-icon" src="@/assets/icon-tip.png" />
</el-popover>
</div>
<img src="@/assets/sop/completed-event.png" />
</div>
<p class="analysis-num">{{ sopInfo.sopStatistics ? sopInfo.sopStatistics.failEventCount || '-' : '-' }}</p>
</div>
<div class="analysis-block back-image-blue">
<div class="analysis-title-block m-b-20"> <div class="analysis-title-block m-b-20">
完成率 完成率
</div> </div>
...@@ -34,7 +46,13 @@ ...@@ -34,7 +46,13 @@
<p class="m-b-10">日营销事件明细</p> <p class="m-b-10">日营销事件明细</p>
<!-- 表格区域 开始 --> <!-- 表格区域 开始 -->
<GLTable ref="completeListRef" :getListApi="getListApi" :noDataImg="url" :searchForm="searchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun"></GLTable> <GLTable ref="completeListRef" :getListApi="getListApi" :noDataImg="url" :searchForm="searchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun">
<template slot="failEventCount" slot-scope="scope">
<el-popover placement="bottom-end" width="200" trigger="hover" content="因企微、短信等限制无法正常执行的事件">
<span slot="reference">{{ scope.scope.eventStatistics ? scope.scope.eventStatistics.failEventCount : '-' }}</span>
</el-popover>
</template>
</GLTable>
<!-- 表格区域 end --> <!-- 表格区域 end -->
</div> </div>
</div> </div>
...@@ -116,6 +134,15 @@ export default { ...@@ -116,6 +134,15 @@ export default {
formatter: cellValue => { formatter: cellValue => {
return cellValue.eventStatistics ? cellValue.eventStatistics.finishEventCount : '-' return cellValue.eventStatistics ? cellValue.eventStatistics.finishEventCount : '-'
} }
},
{
label: '失败事件数',
prop: 'failEventCount',
width: '140',
addHtml: 'failEventCount'
// formatter: cellValue => {
// return cellValue.eventStatistics ? cellValue.eventStatistics.finishEventCount : '-'
// }
} }
] ]
}, },
...@@ -150,6 +177,7 @@ export default { ...@@ -150,6 +177,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
console.log(this.sopInfo)
this.sopInfo.completedPercent = Math.round((this.sopInfo.sopStatistics.finishEventCount / this.sopInfo.sopStatistics.eventCount) * 100).toFixed(0) + '%' this.sopInfo.completedPercent = Math.round((this.sopInfo.sopStatistics.finishEventCount / this.sopInfo.sopStatistics.eventCount) * 100).toFixed(0) + '%'
this.drawPie() this.drawPie()
}) })
...@@ -197,7 +225,7 @@ export default { ...@@ -197,7 +225,7 @@ export default {
margin-right: 20px; margin-right: 20px;
flex-basis: 0 0 auto; flex-basis: 0 0 auto;
background: #ffffff; background: #ffffff;
background-image: linear-gradient(0deg, #f8f8fc 0%, #f4f4ff 100%); background-image: linear-gradient(0deg, #f8f8fc 0%, #f0f7ff 100%);
box-shadow: 0px 10px 20px 0px rgba(88, 80, 255, 0.1); box-shadow: 0px 10px 20px 0px rgba(88, 80, 255, 0.1);
.analysis-title-block { .analysis-title-block {
display: flex; display: flex;
...@@ -220,6 +248,15 @@ export default { ...@@ -220,6 +248,15 @@ export default {
font-weight: 600; font-weight: 600;
} }
} }
.analysis-block.back-image-green {
background-image: linear-gradient(0deg, #f8f8fc 0%, #f0fffa 100%);
}
.analysis-block.back-image-orange {
background-image: linear-gradient(0deg, #f8f8fc 0%, #fff6f0 100%);
}
.analysis-block.back-image-blue {
background-image: linear-gradient(0deg, #f8f8fc 0%, #f0f0ff 100%);
}
} }
} }
</style> </style>
...@@ -24,14 +24,14 @@ ...@@ -24,14 +24,14 @@
</div> </div>
<p class="analysis-num">{{ baseData.sopEventList.length ? sopInfo.customerCount : '-' }}</p> <p class="analysis-num">{{ baseData.sopEventList.length ? sopInfo.customerCount : '-' }}</p>
</div> </div>
<div class="analysis-block"> <div class="analysis-block back-image-green">
<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">{{ baseData.sopEventList.length ? 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 back-image-blue">
<div class="analysis-title-block m-b-20"> <div class="analysis-title-block m-b-20">
触达率 触达率
</div> </div>
...@@ -107,6 +107,17 @@ export default { ...@@ -107,6 +107,17 @@ export default {
} }
}, },
{ {
label: '推送人',
prop: 'pusherName'
},
{
label: '推送时间',
prop: 'pusherTime',
formatter: cellValue => {
return cellValue.pusherTime ? dayjs(cellValue.pusherTime).format('YYYY-MM-DD HH:mm:ss') : '-'
}
},
{
label: '初次查看事件', label: '初次查看事件',
prop: 'firstViewDate', prop: 'firstViewDate',
formatter: cellValue => { formatter: cellValue => {
...@@ -119,6 +130,10 @@ export default { ...@@ -119,6 +130,10 @@ export default {
formatter: cellValue => { formatter: cellValue => {
return cellValue.viewCount || '-' return cellValue.viewCount || '-'
} }
},
{
label: '查看总时长',
prop: ''
} }
] ]
}, },
...@@ -263,7 +278,7 @@ export default { ...@@ -263,7 +278,7 @@ export default {
margin-right: 20px; margin-right: 20px;
flex-basis: 0 0 auto; flex-basis: 0 0 auto;
background: #ffffff; background: #ffffff;
background-image: linear-gradient(0deg, #f8f8fc 0%, #f4f4ff 100%); background-image: linear-gradient(0deg, #f8f8fc 0%, #f0f7ff 100%);
box-shadow: 0px 10px 20px 0px rgba(88, 80, 255, 0.1); box-shadow: 0px 10px 20px 0px rgba(88, 80, 255, 0.1);
.analysis-title-block { .analysis-title-block {
display: flex; display: flex;
...@@ -286,6 +301,12 @@ export default { ...@@ -286,6 +301,12 @@ export default {
font-weight: 600; font-weight: 600;
} }
} }
.analysis-block.back-image-green {
background-image: linear-gradient(0deg, #f8f8fc 0%, #f0fffa 100%);
}
.analysis-block.back-image-blue {
background-image: linear-gradient(0deg, #f8f8fc 0%, #f0f0ff 100%);
}
} }
} }
</style> </style>
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!