Commit 4a7b173d by 杨明

fixed

1 parent c3848470
...@@ -57,5 +57,16 @@ export default { ...@@ -57,5 +57,16 @@ export default {
padding: 20px 0; padding: 20px 0;
line-height: 36px; line-height: 36px;
} }
#app {
background: #f4f5fa;
padding: 0px 20px 20px 20px;
position: absolute;
box-sizing: border-box;
width: 100%;
top: 0px;
left: 0px;
overflow-y: auto;
height: 100%;
}
</style> </style>
> >
...@@ -121,3 +121,14 @@ export function clientManageExportApi(params) { ...@@ -121,3 +121,14 @@ export function clientManageExportApi(params) {
sign: true sign: true
}) })
} }
//根据userId完善客户手机号
export function perfectCustomerPhone(params) {
params.method = `entmicro.api.customer.perfectCustomerPhone`
return http3({
url: 'http://192.168.3.193:8395/rop-scrm-entmicro/router',
method: 'GET',
data: params,
sign: true
})
}
...@@ -15,7 +15,7 @@ import '@/assets/css/public.scss' ...@@ -15,7 +15,7 @@ import '@/assets/css/public.scss'
// import 'glsx-components/dist/glsx-components.css' // import 'glsx-components/dist/glsx-components.css'
import './styles/index.scss' import './styles/index.scss'
import { start } from '@/setup' import { start } from '@/setup'
import glsxTable from 'glsx-table'; import glsxTable from 'glsx-table'
import { message } from './plugins/element.js' import { message } from './plugins/element.js'
import filters from '@/utils/filters' import filters from '@/utils/filters'
import * as echarts from 'echarts' import * as echarts from 'echarts'
...@@ -27,7 +27,7 @@ Vue.use(VueAnimateNumber) ...@@ -27,7 +27,7 @@ Vue.use(VueAnimateNumber)
Vue.config.productionTip = false Vue.config.productionTip = false
Vue.prototype.$apis = apis Vue.prototype.$apis = apis
Vue.use(glsxTable); Vue.use(glsxTable)
Vue.prototype.$message = message Vue.prototype.$message = message
Vue.prototype.size = 'small' Vue.prototype.size = 'small'
// Vue.prototype.btn_size = 'mini' // Vue.prototype.btn_size = 'mini'
...@@ -39,7 +39,6 @@ Vue.prototype.$echarts = echarts ...@@ -39,7 +39,6 @@ Vue.prototype.$echarts = echarts
Object.keys(filters).forEach(key => { Object.keys(filters).forEach(key => {
Vue.filter(key, filters[key]) Vue.filter(key, filters[key])
}) })
start()
export { bootstrap, mount, unmount } from '@/setup' export { bootstrap, mount, unmount } from '@/setup'
export const http = params => Vue.prototype.$http(params) export const http = params => Vue.prototype.$http(params)
export const http2 = params => Vue.prototype.$http2(params) export const http2 = params => Vue.prototype.$http2(params)
......
...@@ -144,14 +144,18 @@ export default { ...@@ -144,14 +144,18 @@ export default {
pageSize: this.$refs.viewCustomers.page.pageSize, pageSize: this.$refs.viewCustomers.page.pageSize,
pageNum: this.$refs.viewCustomers.page.pageNum pageNum: this.$refs.viewCustomers.page.pageNum
} }
getCustomersList(params).then(res => { getCustomersList(params)
this.userLoading = false .then(res => {
this.tableData = res.data this.userLoading = false
this.tableTotal = res.count this.tableData = res.data
if (this.tableTotal == 0) { this.tableTotal = res.count
this.$refs.viewCustomers.setTableHeightFun() if (this.tableTotal == 0) {
} this.$refs.viewCustomers.setTableHeightFun()
}) }
})
.catch(err => {
this.userLoading = false
})
}, },
//创建人群 //创建人群
groupConfirmDialog() { groupConfirmDialog() {
......
@import './variables.scss'; @import "./variables.scss";
@import './common.scss'; @import "./common.scss";
@import './resetelement.scss'; @import "./resetelement.scss";
body, body,
html { html {
width: 100%; width: 100%;
...@@ -34,10 +34,10 @@ button { ...@@ -34,10 +34,10 @@ button {
// 子系统不设外边距 // 子系统不设外边距
.scrm-sub-client-container { .scrm-sub-client-container {
padding: 0 20px 20px 40px; // padding: 0 20px 20px 40px;
box-sizing: border-box; box-sizing: border-box;
} }
.el-table .cell { .el-table .cell {
// line-height: 20px!important; // line-height: 20px!important;
}
\ No newline at end of file \ No newline at end of file
}
//过滤器 //过滤器
/* eslint-disable */ /* eslint-disable */
const overThousandFilter = (val) => { import Vue from 'vue'
if(typeof(val)!='number'){ const overThousandFilter = val => {
return false; if (typeof val != 'number') {
} return false
if (val < 1000) return val; }
let a = val + ""; if (val < 1000) return val
let b = a.split(""); let a = val + ''
b.splice(-3, 0, ","); let b = a.split('')
return b.join(""); b.splice(-3, 0, ',')
}; return b.join('')
//来源 value值转为对应label(来源) }
const toLabel=(value)=> { //来源 value值转为对应label(来源)
if (value!==0 && !value) { const toLabel = value => {
return if (value !== 0 && !value) {
} return
let sourceList=JSON.parse(window.localStorage.getItem('sourceList')); }
let curElement =sourceList.find(item => { let sourceList = JSON.parse(window.localStorage.getItem('sourceList'))
return item.value === value let curElement = sourceList.find(item => {
}) return item.value === value
})
return curElement.label
} return curElement.label
}
const tagType = value => {
let type = ''
if (JSON.parse(sessionStorage.getItem('SCRM_BASE_SESSION')).merchantModel == 1) {
type = '集团'
} else {
type = '企业'
}
return type
}
export default { export default {
overThousandFilter, overThousandFilter,
toLabel toLabel,
}; tagType
}
...@@ -76,16 +76,6 @@ export default { ...@@ -76,16 +76,6 @@ export default {
}, },
tagsPartFormList: [ tagsPartFormList: [
{ {
type: 'input',
name: 'carNumber',
label: '车牌号'
},
{
type: 'input',
name: 'audi',
label: '车系'
},
{
type: 'select', type: 'select',
name: 'followStaff', name: 'followStaff',
optionId: 'value', optionId: 'value',
...@@ -125,12 +115,6 @@ export default { ...@@ -125,12 +115,6 @@ export default {
label: '否' label: '否'
} }
] ]
},
{
type: 'datePicker',
name: 'createTime',
label: '购车时间',
isClear: true
} }
], ],
crowdForm: {}, crowdForm: {},
......
<template> <template>
<div class="scrm-sub-client-container"> <div class="scrm-sub-client-container">
<div class="container"> <div class="container" v-loading="loading">
<div class="leftWrap"> <div class="leftWrap">
<div class="avatorStyle"> <div class="avatorStyle">
<div class="avator"> <div class="avator">
...@@ -279,7 +279,7 @@ ...@@ -279,7 +279,7 @@
</template> </template>
<script> <script>
import { getAllTagTree, getSingleClientTag, addSingleClientTag, getTableDetail } from '@/api/modules/clientManage' import { getAllTagTree, getSingleClientTag, addSingleClientTag, getTableDetail, perfectCustomerPhone } from '@/api/modules/clientManage'
import tipPanel from '@/components/tipPanel/index.vue' import tipPanel from '@/components/tipPanel/index.vue'
import url from '@/assets/clientDetail/noDataBox.png' import url from '@/assets/clientDetail/noDataBox.png'
export default { export default {
...@@ -294,6 +294,7 @@ export default { ...@@ -294,6 +294,7 @@ export default {
isShowTooltip: false, isShowTooltip: false,
remark: '', remark: '',
sloading: false, sloading: false,
loading: false,
expande: false, //车辆 expande: false, //车辆
deviceExpande: false, //设备 deviceExpande: false, //设备
guaranteeExpande: false, //保单 guaranteeExpande: false, //保单
...@@ -699,8 +700,9 @@ export default { ...@@ -699,8 +700,9 @@ export default {
}) })
}, },
async getPageDetail(id = this.$route.query.id) { async getPageDetail(id = this.$route.query.id) {
this.loading = true
const res = await getTableDetail({ oneId: id }) const res = await getTableDetail({ oneId: id })
this.loading = false
if (!res) { if (!res) {
return false return false
} }
...@@ -799,9 +801,21 @@ export default { ...@@ -799,9 +801,21 @@ export default {
return return
} }
if (!/^1[3456789]\d{9}$/.test(this.contactPhone)) { if (!/^1[3456789]\d{9}$/.test(this.contactPhone)) {
this.$message.error('联系号码格式错误') this.$message.error('联系电话不符合要求')
return return
} }
let param = {
pageSize: 1,
pageNum: 1,
customerPhone: this.contactPhone,
userId: this.nickNameList[0].userId
}
perfectCustomerPhone(param).then(res => {
if (res) {
this.getPageDetail()
this.$message.success('设置成功')
}
})
this.phoneVisible = false this.phoneVisible = false
}, },
handleConfirm() { handleConfirm() {
......
...@@ -5,10 +5,10 @@ ...@@ -5,10 +5,10 @@
<span @click="resetTree">重置</span> <span @click="resetTree">重置</span>
</div> </div>
<el-tree @check="checkChange" class="tag-tree" ref="tagTree" :data="labelTree" :props="defaultProps" show-checkbox node-key="id" default-expand-all :expand-on-click-node="false" :filter-node-method="filterNode"> <el-tree @check="checkChange" class="tag-tree" ref="tagTree" :data="labelTree" :props="defaultProps" @node-click="nodeClick" show-checkbox node-key="id" default-expand-all :expand-on-click-node="false" :filter-node-method="filterNode">
<div class="custom-tree-node" slot-scope="{ node, data }"> <div class="custom-tree-node" slot-scope="{ node, data }">
<span :class="['tree-node', `node_${data.id}`]">{{ node.label }}</span> <span :class="['tree-node', `node_${data.id}`]">{{ node.label }}</span>
<span v-if="data.labelType && data.labelType != '系统标签' && isShowEditBtn(data.labelDTO)" @click="editTree(data)"> <span v-if="data.labelType && data.labelType != '系统标签' && isShowEditBtn(data.labelDTO)" @click.stop="editTree(data)">
<i class="el-icon-edit-outline"></i> <i class="el-icon-edit-outline"></i>
</span> </span>
</div> </div>
...@@ -55,7 +55,7 @@ export default { ...@@ -55,7 +55,7 @@ export default {
} }
if (accountLevel !== 1) { if (accountLevel !== 1) {
//如果是企业标签不显示 //如果是企业标签不显示
if (row.labelType == '企业标签') { if (row.labelType == '企业标签' || row.labelType == '集团标签') {
return false return false
} }
return true return true
...@@ -63,6 +63,9 @@ export default { ...@@ -63,6 +63,9 @@ export default {
} }
return true //门店版都显示编辑按钮 return true //门店版都显示编辑按钮
}, },
nodeClick(data) {
!data.sort && document.querySelector(`.node_${data.id}`).parentElement.previousElementSibling.click()
},
handleScroll(height) { handleScroll(height) {
document.querySelector('.tag-tree').scrollTop = height document.querySelector('.tag-tree').scrollTop = height
}, },
...@@ -115,18 +118,19 @@ export default { ...@@ -115,18 +118,19 @@ export default {
id: item.labelGroup.id, id: item.labelGroup.id,
name: item.labelGroup.name, name: item.labelGroup.name,
children: item.labelList, children: item.labelList,
labelType: item.labelType, labelType: item.labelType == '企业标签' && this.$globalState.session.merchantModel == 1 ? '集团标签' : item.labelType,
labelDTO: item labelDTO: item
} }
}) })
const labelType = this.$globalState.session.merchantModel == 1 ? '集团标签' : '企业标签'
labelTreeRets.forEach(item => { labelTreeRets.forEach(item => {
const index = this.labelTree.findIndex(ret => ret.name == item.labelType) const index = this.labelTree.findIndex(ret => ret.name == item.labelType)
if (index == -1) { if (index == -1) {
this.labelTree.push({ this.labelTree.push({
id: item.labelType == '系统标签' ? 1 : item.labelType == '企业标签' ? 2 : 3, id: item.labelType == '系统标签' ? 1 : item.labelType == labelType ? 2 : 3,
name: item.labelType, name: item.labelType,
children: [item], children: [item],
sort: item.labelType == '系统标签' ? 1 : item.labelType == '企业标签' ? 2 : 3 sort: item.labelType == '系统标签' ? 1 : item.labelType == labelType ? 2 : 3
}) })
} else { } else {
this.labelTree[index].children.push(item) this.labelTree[index].children.push(item)
...@@ -136,7 +140,6 @@ export default { ...@@ -136,7 +140,6 @@ export default {
this.$nextTick(() => { this.$nextTick(() => {
status && this.updateTreeNode() status && this.updateTreeNode()
}) })
this.loading = false this.loading = false
}) })
} }
......
...@@ -8,13 +8,14 @@ ...@@ -8,13 +8,14 @@
<span> <span>
共有{{ numberObj.groupCount || 0 }}个标签组 共有{{ numberObj.groupCount || 0 }}个标签组
<!-- v-if="!(merchantModel == 1 && accountLevel == 4)" --> <!-- v-if="!(merchantModel == 1 && accountLevel == 4)" -->
<template>,{{ numberObj.bizLabelCount || 0 }}个企业标签</template> <template>,{{ numberObj.bizLabelCount || 0 }}个{{ '企业' | tagType }}标签</template>
<template v-if="!((merchantModel == 2 && accountLevel == 4) || (merchantModel == 1 && accountLevel == 1))">,{{ numberObj.rcLabelCount || 0 }}个自店标签</template> <template v-if="!((merchantModel == 2 && accountLevel == 4) || (merchantModel == 1 && accountLevel == 1))">,{{ numberObj.rcLabelCount || 0 }}个自店标签</template>
<template>,{{ numberObj.traLabelCount || 0 }}个系统标签</template>
</span> </span>
<span class="iconPanelWrap" v-if="!isFirstShow"> <span class="iconPanelWrap" v-if="!isFirstShow">
<el-popover placement="top" width="666" trigger="hover"> <el-popover placement="top" width="666" trigger="hover">
<!-- v-if="!(merchantModel == 1 && accountLevel == 4)" --> <!-- v-if="!(merchantModel == 1 && accountLevel == 4)" -->
<div>企业标签为全局标签,员工可在企微APP端客户详情、客户跟进等模块查看和打标签,最多3000个;</div> <div>{{ '企业' | tagType }}标签为全局标签,员工可在企微APP端客户详情、客户跟进等模块查看和打标签,最多3000个;</div>
<div v-if="!((merchantModel == 2 && accountLevel == 4) || (merchantModel == 1 && accountLevel == 1))">自店标签为企业商户自有标签,员工可在企微APP端客户跟进等模块查看和打标签,最多3000个;</div> <div v-if="!((merchantModel == 2 && accountLevel == 4) || (merchantModel == 1 && accountLevel == 1))">自店标签为企业商户自有标签,员工可在企微APP端客户跟进等模块查看和打标签,最多3000个;</div>
<div>系统标签为通过大数据算法规则生成的标签</div> <div>系统标签为通过大数据算法规则生成的标签</div>
<img src="@/assets/tagsManage/question.png" slot="reference" alt="" /> <img src="@/assets/tagsManage/question.png" slot="reference" alt="" />
...@@ -22,7 +23,7 @@ ...@@ -22,7 +23,7 @@
</span> </span>
</span> </span>
<div class="initPanel" v-if="isFirstShow"> <div class="initPanel" v-if="isFirstShow">
<template>企业标签为全局标签,员工可在企微APP端客户详情、客户跟进等模块查看和打标签,最多3000个;</template> <template>{{ '企业' | tagType }}标签为全局标签,员工可在企微APP端客户详情、客户跟进等模块查看和打标签,最多3000个;</template>
<template v-if="!((merchantModel == 2 && accountLevel == 4) || (merchantModel == 1 && accountLevel == 1))">自店标签为企业商户自有标签,员工可在企微APP端客户跟进等模块查看和打标签,最多3000个;</template> <template v-if="!((merchantModel == 2 && accountLevel == 4) || (merchantModel == 1 && accountLevel == 1))">自店标签为企业商户自有标签,员工可在企微APP端客户跟进等模块查看和打标签,最多3000个;</template>
系统标签为通过大数据算法规则生成的标签 系统标签为通过大数据算法规则生成的标签
<img src="@/assets/tagsManage/Shape.png" alt="" /> <img src="@/assets/tagsManage/Shape.png" alt="" />
...@@ -84,6 +85,7 @@ ...@@ -84,6 +85,7 @@
<el-button <el-button
plain plain
size="small" size="small"
:disabled="tagCheckItem.length == 0"
@click=" @click="
groupVisible = true groupVisible = true
crowdForm = { crowdForm = {
...@@ -165,7 +167,7 @@ ...@@ -165,7 +167,7 @@
</el-select> </el-select>
<!-- id="tagTipMsgRef" --> <!-- id="tagTipMsgRef" -->
<span class="tagTipMsg" v-if="tagDialogTitle == '添加标签组' && !tagForm.initTagsGroup"> <span class="tagTipMsg" v-if="tagDialogTitle == '添加标签组' && !tagForm.initTagsGroup">
<template v-if="!(merchantModel == 1 && (accountLevel == 2 || accountLevel == 3 || accountLevel == 4))">企业标签</template> <template v-if="!(merchantModel == 1 && (accountLevel == 2 || accountLevel == 3 || accountLevel == 4))">{{ '企业' | tagType }}标签</template>
<template v-if="!((merchantModel == 2 && accountLevel == 4) || (merchantModel == 1 && accountLevel == 1))"> <template v-if="!((merchantModel == 2 && accountLevel == 4) || (merchantModel == 1 && accountLevel == 1))">
<template v-if="!(merchantModel == 1 && (accountLevel == 2 || accountLevel == 3 || accountLevel == 4))">和</template> <template v-if="!(merchantModel == 1 && (accountLevel == 2 || accountLevel == 3 || accountLevel == 4))">和</template>
自店标签分别 自店标签分别
...@@ -173,7 +175,7 @@ ...@@ -173,7 +175,7 @@
最多3000个 最多3000个
</span> </span>
<span class="tagTipMsg" v-if="tagDialogTitle == '添加标签组' && tagForm.initTagsGroup == 1"> <span class="tagTipMsg" v-if="tagDialogTitle == '添加标签组' && tagForm.initTagsGroup == 1">
企业标签已创建 {{ '企业' | tagType }}标签已创建
<span class="pure-blue-text">{{ numberObj.bizLabelCount }}</span> <span class="pure-blue-text">{{ numberObj.bizLabelCount }}</span>
个 个
</span> </span>
...@@ -184,7 +186,7 @@ ...@@ -184,7 +186,7 @@
</span> </span>
<span class="tagTipMsg" v-if="tagDialogTitle == '编辑标签组'"> <span class="tagTipMsg" v-if="tagDialogTitle == '编辑标签组'">
{{ tagForm.initTagsGroup == 1 ? '企业标签' : '自店标签' }}最多3000个,已创建 {{ tagForm.initTagsGroup == 1 ? (this.$globalState.session.merchantModel == 1 ? '集团标签' : '企业标签') : '自店标签' }}最多3000个,已创建
<span class="pure-blue-text">{{ tagForm.initTagsGroup == 1 ? numberObj.bizLabelCount : numberObj.rcLabelCount }}</span> <span class="pure-blue-text">{{ tagForm.initTagsGroup == 1 ? numberObj.bizLabelCount : numberObj.rcLabelCount }}</span>
个 个
</span> </span>
...@@ -326,16 +328,6 @@ export default { ...@@ -326,16 +328,6 @@ export default {
}, },
tagsPartFormList: [ tagsPartFormList: [
{ {
type: 'input',
name: 'carNumber',
label: '车牌号'
},
{
type: 'input',
name: 'audi',
label: '车系'
},
{
type: 'select', type: 'select',
name: 'followStaff', name: 'followStaff',
optionId: 'value', optionId: 'value',
...@@ -375,12 +367,6 @@ export default { ...@@ -375,12 +367,6 @@ export default {
label: '否' label: '否'
} }
] ]
},
{
type: 'datePicker',
name: 'createTime',
label: '购车时间',
isClear: true
} }
], ],
layout: 'sizes, prev, pager, next, jumper, ->, total', layout: 'sizes, prev, pager, next, jumper, ->, total',
...@@ -505,7 +491,7 @@ export default { ...@@ -505,7 +491,7 @@ export default {
// tagsList: [{ required: true }] // tagsList: [{ required: true }]
}, },
tagsGroupList: [ tagsGroupList: [
{ id: 1, name: '企业标签' }, { id: 1, name: this.$globalState.session.merchantModel == 1 ? '集团标签' : '企业标签' },
{ id: 2, name: '自店标签' } { id: 2, name: '自店标签' }
], ],
modeList: [{ id: 1, name: '人工' }], modeList: [{ id: 1, name: '人工' }],
...@@ -624,7 +610,7 @@ export default { ...@@ -624,7 +610,7 @@ export default {
} }
if (this.accountLevel !== 1) { if (this.accountLevel !== 1) {
//如果是企业标签不显示 //如果是企业标签不显示
if (row.labelType == '企业标签') { if (row.labelType == '企业标签' || row.labelType == '集团标签') {
return false return false
} }
return true return true
...@@ -714,7 +700,7 @@ export default { ...@@ -714,7 +700,7 @@ export default {
this.tagGroupId = rowData.labelGroup.id //标签组id this.tagGroupId = rowData.labelGroup.id //标签组id
this.tagForm.tagsName = rowData.labelGroup.name //标签组名 this.tagForm.tagsName = rowData.labelGroup.name //标签组名
this.tagForm.initTagsGroup = rowData.labelType == '企业标签' ? 1 : rowData.labelType == '自店标签' ? 2 : '' //标签组类型 this.tagForm.initTagsGroup = rowData.labelType == '企业标签' || rowData.labelType == '集团标签' ? 1 : rowData.labelType == '自店标签' ? 2 : '' //标签组类型
}, },
handleConfirm() { handleConfirm() {
this.$refs.tagForm.$children[0].validate(valid => { this.$refs.tagForm.$children[0].validate(valid => {
...@@ -811,7 +797,7 @@ export default { ...@@ -811,7 +797,7 @@ export default {
// params.staffId = '员工A' // params.staffId = '员工A'
params['labelDTO.labelGroup.name'] = this.tagForm.tagsName params['labelDTO.labelGroup.name'] = this.tagForm.tagsName
params['labelDTO.labelType'] = this.tagForm.initTagsGroup == 1 ? '企业标签' : '自店标签' params['labelDTO.labelType'] = this.tagForm.initTagsGroup == 1 ? (this.$globalState.session.merchantModel == 1 ? '集团标签' : '企业标签') : '自店标签'
params['labelDTO.labelList'] = this.tagForm.tagsList params['labelDTO.labelList'] = this.tagForm.tagsList
params['labelDTO.isAddLabelGroupEnter'] = this.tagDialogTitle == '添加标签组' ? true : false params['labelDTO.isAddLabelGroupEnter'] = this.tagDialogTitle == '添加标签组' ? true : false
...@@ -852,7 +838,7 @@ export default { ...@@ -852,7 +838,7 @@ export default {
param['labelDTO.labelGroup.id'] = this.tagGroupId param['labelDTO.labelGroup.id'] = this.tagGroupId
param['labelDTO.labelGroup.name'] = this.tagForm.tagsName param['labelDTO.labelGroup.name'] = this.tagForm.tagsName
param['labelDTO.labelType'] = this.tagForm.initTagsGroup == 1 ? '企业标签' : '自店标签' param['labelDTO.labelType'] = this.tagForm.initTagsGroup == 1 ? (this.$globalState.session.merchantModel == 1 ? '集团标签' : '企业标签') : '自店标签'
param['labelDTO.shopId'] = this.merchantId param['labelDTO.shopId'] = this.merchantId
let editTagList = this.editTagList.map(item => { let editTagList = this.editTagList.map(item => {
return { return {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!