Commit 47e1faf7 by 前端

Merge branch 'xuyl_dev_v2.4.0' into 'v2.4.0'

跳转营销SOP传参

See merge request !95
2 parents e67fdda9 483e8be6
......@@ -26,7 +26,7 @@
</div>
<img src="./assets/logo.png" alt="" srcset="" />
</div> -->
<keep-alive exclude="clientDetail,clientGroupDetail,tagsManage,clientDataOverview,guestGroup,guestGroupAdd,guestGroupDetail,group,viewCustomers,crowdDetail,crowdAdd,crowdManage,leadBasicInfo,leadAllocation,leadManage">
<keep-alive exclude="clientDetail,clientGroupDetail,tagsManage,clientDataOverview,guestGroup,guestGroupAdd,guestGroupDetail,group,viewCustomers,crowdDetail,crowdAdd,crowdManage,leadBasicInfo,leadAllocation,leadManage,marketingPeople">
<router-view></router-view>
</keep-alive>
</div>
......
......@@ -6,62 +6,87 @@
* @param {*} params
* @returns
*/
import { http3 } from '@/main'
import {
http3
} from '@/main'
// const url = 'http://192.168.3.193:8395/rop-scrm-entmicro/router'
//获取数据概览上方的数据 /rop-scrm-datahub
export function getDataOverview(params) {
params.method = 'entmicro.api.Customer.customer.view.data'
params.method = 'entmicro.api.Customer.customer.view.data'
return http3({
url: '/rop-scrm-entmicro/router',
method: 'POST',
data: params,
sign: true
})
return http3({
url: '/rop-scrm-entmicro/router',
method: 'POST',
data: params,
sign: true
})
}
//获取数据概览下方柱状图的数据
export function getDataOverviewBarMap(params) {
params.method = 'entmicro.api.customer.view.chart'
return http3({
url: '/rop-scrm-entmicro/router',
method: 'POST',
data: params,
sign: true
})
params.method = 'entmicro.api.customer.view.chart'
return http3({
url: '/rop-scrm-entmicro/router',
method: 'POST',
data: params,
sign: true
})
}
// 获取数据概览客户列表数据接口
export function getCustomerList(params) {
params.method = 'entmicro.api.customer.cluster.page'
return http3({
url:'/rop-scrm-entmicro/router',
method: 'POST',
data: params,
sign: true
})
params.method = 'entmicro.api.customer.cluster.page'
return http3({
url: '/rop-scrm-entmicro/router',
method: 'POST',
data: params,
sign: true
})
}
// 获取人群管理客户列表数据接口
export function getcrowdManageList(params) {
params.method = 'entmicro.api.customer.crowd.page'
return http3({
url:'/rop-scrm-entmicro/router',
// url:'http://192.168.3.193:8395/rop-scrm-entmicro/router',
method: 'POST',
data: params,
sign: true
})
params.method = 'entmicro.api.customer.crowd.page'
return http3({
url: '/rop-scrm-entmicro/router',
// url:'http://192.168.3.193:8395/rop-scrm-entmicro/router',
method: 'POST',
data: params,
sign: true
})
}
//客户分群列表导出
export function customerClusterListExport(params) {
params.method = 'entmicro.api.customer.customerClusterListExport'
return http3({
url:'/rop-scrm-entmicro/router',
method: 'POST',
data: params,
sign: true
})
params.method = 'entmicro.api.customer.customerClusterListExport'
return http3({
url: '/rop-scrm-entmicro/router',
method: 'POST',
data: params,
sign: true
})
}
//获取客户分群展示
export function customerClusterListShow(params) {
params.method = 'scrm.api.datahub.user.queryCrowdGroupList'
return http3({
url: '/rop-scrm-datahub/router',
method: 'POST',
data: params,
sign: true
})
}
// 通过分群Id查询人群列表详情请求
export function marketingPeopleListShow(params) {
params.method = 'scrm.api.datahub.user.queryCrowdListByCrowdGroupId'
return http3({
// http://192.168.3.226:9636
url: '/rop-scrm-datahub/router',
method: 'POST',
data: params,
sign: true
})
}
\ No newline at end of file
......@@ -24,8 +24,8 @@ const staticRoutes = Object.freeze([{
},
{
name: 'marketingPeople',
path: '/clientDataOverview/GroupOperating/marketingPeople',
component: resolve => require([`@/views/clientDataOverview/GroupOperating/marketingPeople`], resolve),
path: '/clientDataOverview/marketingPeople',
component: resolve => require([`@/views/clientDataOverview/marketingPeople`], resolve),
meta: {}
},
{
......@@ -126,7 +126,7 @@ const staticRoutes = Object.freeze([{
},
{
name: 'crowdDetail',
path: '/crowdManage/crowdDetail/:id/:type',
path: '/crowdManage/crowdDetail:id',
component: resolve => require([`@/views/crowdManage/crowdDetail.vue`], resolve),
meta: {}
},
......
......@@ -4,8 +4,8 @@
<GLCombiForm :formObj="searchForm" :formData="searchFormList" @handleOk="searchTable" @handleRest="resetTable"></GLCombiForm>
<GLTable v-loading="loading" :hasNum="true" @setTableHeightEvent="setTableHeightEvent" @setTableFinishFun="setTableFinishFun" ref="marketingPlan" :getListApi="getListApi" :searchForm="searchForm" :pageConf="pageConf" :noDataImg="url" :tableParams="tableParams">
<template slot="options" slot-scope="scope">
<el-button class="blue-text" type="text" @click="goBasicInfo(scope.scope)">SOP分析</el-button>
<el-button class="blue-text" type="text" @click="goBasicInfo(scope.scope)">编辑</el-button>
<el-button class="blue-text" type="text" @click="goSOPAnalysis(scope.scope.id)">SOP分析</el-button>
<el-button class="blue-text" type="text" @click="goSOPEdit(scope.scope.id)">编辑</el-button>
<el-button class="blue-text" type="text" @click="confirm('delete')">删除</el-button>
<el-button class="blue-text" type="text" @click="confirm(scope.scope)">结束</el-button>
</template>
......@@ -16,6 +16,7 @@
<script>
import { getTableList } from '@/api/modules/clientManage'
import util from '@/utils/util'
export default {
data() {
return {
......@@ -87,9 +88,17 @@ export default {
}, 200)
},
methods: {
// 跳转SOP分析
goSOPAnalysis(){
this.$history.push(`/marketing/sop/sopAnalysisList?fromPage=${encodeURI('/npmph/clientDataOverview/marketingPeople?selectTab=2')}&id=183`)
},
// 跳转SOP编辑页面
goSOPEdit(id) {
this.$history.push(`/marketing/sop/editSop?$title=${encodeURI('编辑SOP')}&fromPage=${encodeURI('/npmph/clientDataOverview/marketingPeople?selectTab=2')}&addOrEdit=edit&id=183`)
},
// 确认删除或结束
confirm(type) {
this.$confirm(`是否确认${type == 'delete' ? '删除' : '结束'}?`, '提示', {
this.$confirm(`是否确认${type == 'delete' ? '删除' : '结束'}?`, '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
......
<template>
<div class="scrm-sub-client-container">
<div class="pageContent">
<GLCombiForm :formObj="searchForm" :formData="searchFormList" @handleOk="searchTable" @handleRest="resetTable"></GLCombiForm>
<GLTable v-loading="loading" :hasNum="true" @setTableHeightEvent="setTableHeightEvent" @setTableFinishFun="setTableFinishFun" ref="marketingPlan" :getListApi="getListApi" :searchForm="searchForm" :pageConf="pageConf" :noDataImg="url" :tableParams="tableParams">
<template slot="options" slot-scope="scope">
<el-button class="blue-text" type="text" @click="goSOPAnalysis(scope.scope.id)">SOP分析</el-button>
<el-button class="blue-text" type="text" @click="goSOPEdit(scope.scope.id)">编辑</el-button>
<el-button class="blue-text" type="text" @click="confirm('delete')">删除</el-button>
<el-button class="blue-text" type="text" @click="confirm(scope.scope)">结束</el-button>
</template>
</GLTable>
</div>
</div>
</template>
<script>
import { getTableList } from '@/api/modules/clientManage'
import util from '@/utils/util'
export default {
data() {
return {
searchForm: {},
searchFormList: [
{
type: 'input',
inputType: 'text',
// name: 'keyword',
label: '人群名称'
},
{
type: 'select',
// name: 'type',
label: '营销状态',
optionLabel: 'label',
optionId: 'value',
optionList: [
{
label: '全部',
value: ''
}
],
placeholder: '请选择'
}
],
getListApi: getTableList,
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
tableParams: {
listName: 'data',
tableColumns: [
{
label: '人群名称',
prop: 'orderNo'
},
{
label: 'SOP名称',
prop: 'name'
},
{
label: '营销时间',
prop: 'phone'
},
{
label: '完成度',
prop: 'dsdasd'
},
{
label: '营销状态',
prop: 'dsdasds'
},
{
label: '操作',
prop: 'options',
addHtml: 'options'
}
]
}
}
},
mounted() {
//没数据的时候要算高度
setTimeout(() => {
if (!this.$refs.marketingPlan.data.length) {
this.loading = true
this.$refs.marketingPlan.setTableHeightFun()
this.loading = false
}
}, 200)
},
methods: {
// 跳转SOP分析
goSOPAnalysis(){
this.$history.push(`/marketing/sop/sopAnalysisList?fromPage=${encodeURI('/npmph/clientDataOverview/marketingPeople?selectTab=2')}&id=183`)
},
// 跳转SOP编辑页面
goSOPEdit(id) {
this.$history.push(`/marketing/sop/editSop?$title=${encodeURI('编辑SOP')}&fromPage=${encodeURI('/npmph/clientDataOverview/marketingPeople?selectTab=2')}&addOrEdit=edit&id=183`)
},
// 确认删除或结束
confirm(type) {
this.$confirm(`是否确认${type == 'delete' ? '删除' : '结束'}?`, '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
})
.then(() => {
this.$message({
type: 'success',
message: '操作成功!'
})
})
.catch(() => {
this.$message({
type: 'info',
message: '已取消操作'
})
})
},
setTableFinishFun() {
this.$refs.marketingPlan.data.length ? (this.$refs.marketingPlan.tableHeightValues = '') : this.$refs.marketingPlan.setTableHeightFun()
},
setTableHeightEvent() {
this.$refs.marketingPlan.setTableHeightFun()
},
// 搜索表格
searchTable() {
console.log(this.searchForm)
this.$refs.marketingPlan.refreshTable()
},
//重置表格
resetTable() {
this.searchForm = {
status: '',
type: ''
}
this.$refs.marketingPlan.refreshTable()
}
}
}
</script>
<style lang="scss" scoped>
.pageContent {
padding: 20px 20px 30px;
box-shadow: 0 10px 20px 0 rgba(88, 80, 255, 0.1);
background-color: #fff;
}
</style>
......@@ -22,7 +22,7 @@
<div>
<el-button size="small" @click="handleExport" class="export">导出</el-button>
<el-button plain size="small">
<el-button plain size="small" @click="createMarketSOP()">
营销SOP
</el-button>
</div>
......@@ -91,7 +91,8 @@ export default {
{
type: 'input',
name: 'customerPhone',
label: '联系电话'
label: '联系电话',
width: 170
},
{
type: 'input',
......@@ -172,7 +173,7 @@ export default {
prop: 'followStaff',
// addHtml: 'followStaff',
width: 170,
line:1
line: 1
},
{
label: '是否加企微', //1. 加入,0.未加入
......@@ -205,7 +206,8 @@ export default {
let { id } = this
this.init(id)
// 针对广汇替换字段
if (this.id == 1 && location.host.includes('cgacar')) {
// cgacar
if ((this.id == 1 || this.id == 2 || this.id == 3) && location.host.includes('cgacar')) {
this.tableParams.tableColumns.splice(
3,
3,
......@@ -234,6 +236,29 @@ export default {
this.getStaffList()
},
methods: {
// 跳转到营销SOP
createMarketSOP() {
let marketQuery
if (this.crowdType == 1 || this.crowdType == 2) {
marketQuery = JSON.parse(this.$route.query.crowdInfo)
}
var params = {
addOrEdit: 'add',
fromPage: '/npmph/clientDataOverview/group',
$title: encodeURI('新建SOP'),
info: {
// 人群
customerOptType: 2,
crowdList: []
}
}
params.info.crowdList.push(marketQuery)
console.log(params)
this.$common.utils.storage.set('sopInfo', params)
this.$history.push({
path: 'marketing/sop/editSop'
})
},
//获取跟进员工
getStaffList() {
getStaffList({}).then(res => {
......@@ -297,7 +322,7 @@ export default {
pageSize: 10,
pageNum: 1
}
if (this.crowdType) params.customCrowd = true
if (this.crowdType == 1 || this.crowdType == 2) params.customCrowd = true
customerClusterListExport(params).then(res => {
this.$Utils.exportFn(res)
})
......
......@@ -15,7 +15,7 @@
</div>
<div class="topmsg">
<span class="normalTitle">客户分层</span>
<div style="display:flex">
<div style="display: flex">
<div class="leftPieEcharts">
<div class="leftIntro">
<span class="title">客户总数</span>
......@@ -61,7 +61,7 @@
</div>
<div class="itembox">
<div style="display:flex;overflow:hidden">
<div style="display: flex; overflow: hidden">
<div class="buy">
<div class="buy-total item" @click="goto(4)" fn="人群客户列表" mode="div">
<div class="buyTitle">
......@@ -292,33 +292,33 @@
</div>
</div>
<div class="itembox">
<template v-for="(item, index) in titles">
<template v-for="(item, index) in customerSegmentation">
<!-- fn="人群客户列表" mode="div" -->
<div class="item" @click="goToGroupOperating()" :key="index">
<div class="item" @click="goToGroupOperating(item.crowdGroupId)" :key="index">
<div class="itemTitle">
<span class="itemName">{{ item.name }}</span>
<el-popover placement="top" trigger="hover" :content="item.subName">
<span class="dataOverPopover">{{ item.subName }}</span>
<span class="itemName">{{ item.crowdGroupName }}</span>
<el-popover placement="top" trigger="hover" :content="item.crowdGroupDesc">
<span class="dataOverPopover">{{ item.crowdGroupDesc }}</span>
<img class="questionImg" src="@/assets/clientDataOverview/grayquestion.png" slot="reference" />
</el-popover>
</div>
<div class="itemBottom">
<p class="totalNum">
{{ item.num | overThousandFilter }}
{{ item.total | overThousandFilter }}
<span class="enum">人</span>
</p>
<div class="middlemsg-qiwei-total">
<div class="qiwei-describe">
<div class="inWechat">已加企微</div>
<div class="num">
{{ (item.add(topDataObj) || 0) | overThousandFilter }}
{{ (item.wechatTotal || 0) | overThousandFilter }}
<span class="person-text">人</span>
</div>
</div>
<div class="qiwei-describe">
<div class="inWechat">未加企微</div>
<div class="num">
{{ (item.noAdd(topDataObj) || 0) | overThousandFilter }}
{{ (item.notWechatTotal || 0) | overThousandFilter }}
<span class="person-text">人</span>
</div>
</div>
......@@ -373,7 +373,7 @@
<script>
import $ from 'jquery'
import { rwdImageMaps } from './jquery.rwdImageMaps.js'
import { getDataOverview, getDataOverviewBarMap } from '@/api/modules/clientDataOverview'
import { getDataOverview, getDataOverviewBarMap, customerClusterListShow } from '@/api/modules/clientDataOverview'
import { getLoginCount } from '@/api/modules/loginCount'
import pieEchart from '@/components/echarts/pieEchart'
// import pieEchartCopy from '@/components/echarts/pieEchartCopy'
......@@ -410,56 +410,57 @@ export default {
burseholderCustomerCount: 0,
silenceCustomerCount: 0
},
titles: [
{
name: '新车客户数',
subName: '购车时间3个月的客户',
num: 0,
add: obj => {
return obj.newCarCustomerAddCount
},
noAdd: obj => {
return obj.newCarCustomerNAddCount
},
id: 7
},
{
name: '车险待续保客户数',
subName: '近一个月内车险即将到期的客户',
num: 0,
add: obj => {
return obj.needRenewalCustomerAddCount
},
noAdd: obj => {
return obj.needRenewalCustomerNAddCount
},
id: 8
},
{
name: '新车待首保客户数',
subName: '购车时间5~7个月内,且无保养记录的客户',
num: 0,
add: obj => {
return obj.burseholderCustomerAddCount
},
noAdd: obj => {
return obj.burseholderCustomerNAddCount
},
id: 9
},
{
name: '沉默客户数',
subName: '超过180天未到店的客户',
num: 0,
add: obj => {
return obj.silenceCustomerAddCount
},
noAdd: obj => {
return obj.silenceCustomerNAddCount
},
id: 10
}
],
customerSegmentation: [], //客户分群展示列表
// titles: [
// {
// name: '新车客户数',
// subName: '购车时间3个月的客户',
// num: 0,
// add: obj => {
// return obj.newCarCustomerAddCount
// },
// noAdd: obj => {
// return obj.newCarCustomerNAddCount
// },
// id: 7
// },
// {
// name: '车险待续保客户数',
// subName: '近一个月内车险即将到期的客户',
// num: 0,
// add: obj => {
// return obj.needRenewalCustomerAddCount
// },
// noAdd: obj => {
// return obj.needRenewalCustomerNAddCount
// },
// id: 8
// },
// {
// name: '新车待首保客户数',
// subName: '购车时间5~7个月内,且无保养记录的客户',
// num: 0,
// add: obj => {
// return obj.burseholderCustomerAddCount
// },
// noAdd: obj => {
// return obj.burseholderCustomerNAddCount
// },
// id: 9
// },
// {
// name: '沉默客户数',
// subName: '超过180天未到店的客户',
// num: 0,
// add: obj => {
// return obj.silenceCustomerAddCount
// },
// noAdd: obj => {
// return obj.silenceCustomerNAddCount
// },
// id: 10
// }
// ],
isNoBuyUp: 0, //默认环比为增
isBuyUp: 0,
bottomDataObj: {},
......@@ -516,6 +517,7 @@ export default {
//运行在qiankun容器中
this.accountLevel = this.$globalState.session.accountLevel
this.userType = this.$globalState.session.userType
this.merchantId = this.$globalState.session.merchantId
}
// 掉两个数据接口
......@@ -524,10 +526,20 @@ export default {
//先看登录次数,首次进来为true,不管客户总数是否为0,都显示banner;
//不是首次进来,登录次数为2,客户总数大于0,不显示banner,小于0,继续显示banner;
this.getDataOverviewBarMapFun()
this.customerListShow()
},
methods: {
goToGroupOperating() {
this.$router.push('/clientDataOverview/GroupOperating/marketingPeople')
customerListShow() {
let param = {
'req.merchantId': this.merchantId
}
customerClusterListShow(param).then(res => {
this.customerSegmentation = res.crowdGroupUnitList
console.log(this.customerSegmentation)
})
},
goToGroupOperating(id) {
this.$router.push(`/clientDataOverview/marketingPeople?crowdId=${id}`)
},
goNextPage() {
// window.open('https://www.baidu.com', '_blank')
......@@ -634,8 +646,6 @@ export default {
// this.titles[1].num = res.needRenewalCustomerCount
// this.titles[2].num = res.burseholderCustomerCount
// this.titles[4].num = res.silenceCustomerCount
console.log(res, '这是上面数据')
this.isNoBuyUp = res.purposeUp
this.isBuyUp = res.purchaseUp
//先看登录次数,首次进来为true,不管客户总数是否为0,都显示banner;
......@@ -671,10 +681,10 @@ export default {
// })
// }
console.log(this.isHasCustomerCountBanner, 'true/fasle')
this.$set(this.titles[0], 'num', res.newCarCustomerCount)
this.$set(this.titles[1], 'num', res.needRenewalCustomerCount)
this.$set(this.titles[2], 'num', res.burseholderCustomerCount)
this.$set(this.titles[3], 'num', res.silenceCustomerCount)
// this.$set(this.titles[0], 'num', res.newCarCustomerCount)
// this.$set(this.titles[1], 'num', res.needRenewalCustomerCount)
// this.$set(this.titles[2], 'num', res.burseholderCustomerCount)
// this.$set(this.titles[3], 'num', res.silenceCustomerCount)
})
// .catch(err => {
// console.log('错误信息:', err)
......
......@@ -8,7 +8,6 @@
<!-- 切换导航栏 -->
<el-tabs v-model="activeName" @tab-click="handleClick">
<el-tab-pane label="营销人群" name="first">
<!-- v-if="activeName == 'first'" -->
<div class="pageContent">
<div class="markPeople">
<span>营销人群</span>
......@@ -26,13 +25,13 @@
<div class="bigMarketItem" v-if="closeFlag">
<div v-for="(item, idx) in itemArr" :key="idx" :class="[{ active: isActive == idx }, 'marketItem']" @click="choickItem(idx)">
<template v-if="idx < displayNum">
<p class="peopleName">人群名称</p>
<p class="peopleName">{{ item.crowdName }}</p>
<div class="itemBox">
<p class="peopleNum">
{{ item.num }}
{{ item.total }}
<span>人</span>
</p>
<p class="peopledesc">{{ item.desc }}</p>
<p class="peopledesc">{{ item.crowdDesc }}</p>
<el-button class="createSOP" @click.stop="createMarketSOP()" :disabled="item.type">创建营销SOP</el-button>
</div>
</template>
......@@ -43,13 +42,13 @@
<div class="swiper-wrapper">
<div v-for="(item, idx) in itemArr" :key="idx" :class="[{ active: isActive == idx }, 'marketItem', 'swiper-slide']" @click="choickItem(idx, item.title)">
<div class="marketItem-border">
<p class="peopleName">{{ item.title }}</p>
<p class="peopleName">{{ item.crowdName }}</p>
<div class="itemBox">
<p class="peopleNum">
{{ item.num }}
{{ item.total }}
<span>人</span>
</p>
<p class="peopledesc">{{ item.desc }}</p>
<p class="peopledesc">{{ item.crowdDesc }}</p>
<el-button class="createSOP" @click.stop="createMarketSOP(item.id)" :disabled="item.type">创建营销SOP</el-button>
</div>
</div>
......@@ -82,15 +81,16 @@
</template>
<script>
import { marketingPeopleListShow } from '@/api/modules/clientDataOverview'
import marketingPlan from './components/marketingPlan.vue'
import Swiper from 'swiper'
import util from '@/utils/util'
import 'swiper/dist/css/swiper.min.css'
export default {
name: 'marketPeople',
name: 'marketingPeople',
components: { marketingPlan },
data() {
return {
crowdGroupId: '',
activeName: 'first',
searchForm: {},
isActive: -1,
......@@ -98,16 +98,15 @@ export default {
closeFlag: false, //展开收起
showTitle: '', // 展示的标题
itemArr: [
// 后台传一个状态回来
{ title: 'N-23待定保客户', num: 323, desc: '我顶着大太阳,只想为你撑伞', id: 1, type: 'false' },
{ title: 'N-45待定保客户', num: 1312, desc: '你专心在画睫毛,我专心在等你笑', id: 2 },
{ title: 'N-33待定保客户', num: 43133, desc: '气球在我手上,牵着你瞎逛' },
{ title: 'N-1待定保客户', num: 123213, desc: '城堡为爱守着秘密,而我为你守着爱情' },
{ title: 'N-2待定保客户', num: 1233, desc: '喜欢在人潮中,你只属于我的那画面' },
{ title: 'N-7待定保客户', num: 43133, desc: '但偏偏,风渐渐,把距离吹的好远' },
{ title: 'N-6待定保客户', num: 123213, desc: '最美的不是下雨天,是曾与你躲过雨的屋檐' },
{ title: 'N-5待定保客户', num: 1233, desc: '美人鱼的眼泪' },
{ title: 'N-4待定保客户', num: 1233, desc: '我一路向北,离开有你的季节' }
// { title: 'N-23待定保客户', num: 323, desc: '我顶着大太阳,只想为你撑伞', id: 1, type: 'false' },
// { title: 'N-45待定保客户', num: 1312, desc: '你专心在画睫毛,我专心在等你笑', id: 2 },
// { title: 'N-33待定保客户', num: 43133, desc: '气球在我手上,牵着你瞎逛' },
// { title: 'N-1待定保客户', num: 123213, desc: '城堡为爱守着秘密,而我为你守着爱情' },
// { title: 'N-2待定保客户', num: 1233, desc: '喜欢在人潮中,你只属于我的那画面' },
// { title: 'N-7待定保客户', num: 43133, desc: '但偏偏,风渐渐,把距离吹的好远' },
// { title: 'N-6待定保客户', num: 123213, desc: '最美的不是下雨天,是曾与你躲过雨的屋檐' },
// { title: 'N-5待定保客户', num: 1233, desc: '美人鱼的眼泪' },
// { title: 'N-4待定保客户', num: 1233, desc: '我一路向北,离开有你的季节' }
],
marketPeopleFormList: [
{
......@@ -227,23 +226,54 @@ export default {
minWidth: 120
},
{
label: '性别',
label: '联系电话',
prop: 'customerSex',
addHtml: 'customerSex'
addHtml: 'customerSex',
width: 150
},
{
label: '入群方式',
label: '车架号',
prop: 'joinScene',
addHtml: 'joinScene',
minWidth: 140
},
{
label: '邀请人',
label: '车牌号',
prop: 'invitorName',
minWidth: 120
},
{
label: '入群时间',
label: '车系',
prop: 'joinTime',
width: 170
},
{
label: '车险开始时间',
prop: 'joinTime',
width: 170
},
{
label: '车险到期时间',
prop: 'joinTime',
width: 170
},
{
label: '跟进员工',
prop: 'joinTime',
width: 170
},
{
label: '是否加企微',
prop: 'joinTime',
width: 170
},
{
label: '购车时间',
prop: 'joinTime',
width: 170
},
{
label: '添加时间',
prop: 'joinTime',
width: 170
}
......@@ -261,7 +291,11 @@ export default {
// getListApi: getDetailQuitTableList,
}
},
created() {
// this.$route.query || this.$route.query.selectTab == 1 ? (this.activeName = 'first') : (this.activeName = 'second')
this.crowdGroupId = this.$route.query.crowdId
this.getMarketingPeople()
},
mounted() {
new Swiper('.swiper-container', {
// paginationClickable: true,
......@@ -276,6 +310,17 @@ export default {
})
},
methods: {
// 获取营销人群展示
getMarketingPeople() {
let params = {
'req.crowdGroupId': this.crowdGroupId
}
marketingPeopleListShow(params).then(res => {
console.log(res)
this.itemArr = res.crowdUnitList
console.log(this.itemArr)
})
},
// 搜索表格
searchTable() {
console.log(this.searchForm)
......@@ -288,7 +333,7 @@ export default {
},
// 跳转到营销SOP
createMarketSOP(id) {
util.openUrl(location.origin + `/marketing/sop/editSop?addOrEdit=add&fromPage=sopList&corwedId=${id}`)
this.$history.push(`/marketing/sop/editSop?$title=${encodeURI('新建SOP')}&fromPage=${encodeURI('/npmph/clientDataOverview/marketingPeople?selectTab=1')}&addOrEdit=add&id=183`)
},
expandClick(val) {
if (val == 'expand') {
......
......@@ -254,11 +254,12 @@ export default {
tableOption: false,
// mutiSelectName: 'employeeList',
// mutiSelectUniqueKey: 'id',
tableColumns: [
{
label: '客户ID',
prop: 'oneId',
width:140,
width: 140,
line: 1
},
{
......@@ -266,7 +267,7 @@ export default {
prop: 'customerName',
addHtml: 'customerName',
width: 120,
line:1
line: 1
},
{
label: '企微名称',
......@@ -323,30 +324,30 @@ export default {
label: '车系',
prop: 'audi',
width: 120,
line:1
line: 1
},
{
label: '车架号',
prop: 'carVin',
width: 180,
line:1
line: 1
},
{
label: '车牌号',
prop: 'carNumber',
width: 140,
line:1
line: 1
},
{
label: '购车时间',
prop: 'buyDate',
width: 170,
line:1
line: 1
},
{
label: '操作',
prop: 'optionBtns',
width: '65px',
width: '66px',
addHtml: 'optionBtns',
fixed: 'right'
}
......
......@@ -107,7 +107,7 @@ export default {
crowdDesc: ''
},
crowdId: this.$route.params.id ? this.$route.params.id : '',
crowdPage: this.$route.params.crowdType ? this.$route.params.crowdType : '',
crowdPage: this.$route.query.crowdType ? this.$route.query.crowdType : '',
tableTotal: '',
isShowCloseBtn: true,
dialogRuleVisible: false,
......@@ -152,7 +152,7 @@ export default {
this.getCrowdDetails()
},
mounted() {
console.log(this.$route.params)
console.log(this.$route.query.crowdPage)
},
methods: {
goBack() {
......
......@@ -28,7 +28,7 @@
<GLButton type="text" @click="btnClick('detail', scope.scope)" class="blue-text" fn="查看详情">查看详情</GLButton>
<!-- <span style="margin-left: 20px" @click="btnClick('view', scope.scope)" class="blue-text">查看客户</span> -->
<GLButton class="blue-text leftDistance" type="text" fn="客户列表" v-if="userType !== 2" @click="btnClick('view', scope.scope)">查看客户</GLButton>
<el-button type="text" class="blue-text" >营销SOP</el-button>
<el-button type="text" class="blue-text" @click="createMarketSOP(scope.scope)">营销SOP</el-button>
</template>
</GLTable>
</div>
......@@ -108,21 +108,50 @@ export default {
// this.activeName = 'second'
// // window.history.pushState(null, null, location.origin + location.pathname)
// }
// console.log(this.$route.query)
if (this.$route.query.selectTab) {
this.$route.query.selectTab == 1 ? (this.activeName = 'first') : (this.activeName = 'second')
}
},
mounted() {
console.log(this.$route.params)
},
mounted() {},
methods: {
createMarketSOP(crowd) {
var params = {
addOrEdit: 'add',
fromPage: '/npmph/crowdManage/index',
$title: encodeURI('新建SOP'),
info: {
// 人群
customerOptType: 2,
crowdList: []
// 标签
// customerOptType: 3,
// labelList: [
// {
// id: 10,
// labelGroupId: '79009',
// labelGroupName: 'sop专用标签组1',
// labelGroupType: '自店标签',
// labelId: '37418',
// labelName: 'group1_A'
// }
// ]
}
}
params.info.crowdList.push(crowd)
this.$common.utils.storage.set('sopInfo', params)
this.$history.push({
path: 'marketing/sop/editSop'
})
},
btnClick(type, data) {
const crowdType = this.activeName == 'first' ? 1 : 2
const transData = JSON.stringify(data)
if (type == 'detail') {
this.$router.push(`/crowdManage/crowdDetail/${data.crowdId}/${crowdType}`)
this.$router.push(`/crowdManage/crowdDetail/${data.crowdId}?crowdType=${crowdType}`)
}
if (type == 'view') {
this.$router.push(`/clientDataOverview/group/${data.crowdId}/${crowdType}`)
this.$router.push(`/clientDataOverview/group/${data.crowdId}/${crowdType}?crowdInfo=${transData}`)
}
},
addClick() {
......
......@@ -95,10 +95,7 @@
>
保存为人群
</el-button>
<el-button
plain
size="small"
>
<el-button plain size="small" @click="createMarketSOP()">
营销SOP
</el-button>
</div>
......@@ -582,6 +579,31 @@ export default {
// toViewCustomer(info) {
// this.$router.push('/tagsManage/viewCustomers')
// },
// 跳转到营销SOP
createMarketSOP() {
let getDatas = JSON.parse(
JSON.stringify(this.allListParams)
.replace(/groupId/g, 'labelGroupId')
.replace(/groupName/g, 'labelGroupName')
.replace(/groupType/g, 'labelGroupType')
)
console.log(getDatas)
var params = {
addOrEdit: 'add',
fromPage: '/npmph/tagsManage/index',
$title: encodeURI('新建SOP'),
info: {
// 标签
customerOptType: 3,
labelList: [...getDatas]
}
}
console.log(params)
this.$common.utils.storage.set('sopInfo', params)
this.$history.push({
path: 'marketing/sop/editSop'
})
},
toViewCustomer(info) {
console.log(info)
const id = info.labelGroup.id
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!