Commit f3b52890 by 前端

Merge branch 'xuyl_dev_2.1.0' into 'v2.1.0'

Xuyl dev 2.1.0

See merge request !18
2 parents c66f3130 37864e72
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
"echarts": "^5.2.0", "echarts": "^5.2.0",
"element-ui": "^2.4.5", "element-ui": "^2.4.5",
"glsx-common": "^1.4.6", "glsx-common": "^1.4.6",
"glsx-components": "^1.3.3", "glsx-components": "^1.3.9",
"glsx-table": "^1.1.0", "glsx-table": "^1.1.0",
"jquery": "^3.6.0", "jquery": "^3.6.0",
"sha1": "^1.1.1", "sha1": "^1.1.1",
......
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
</div> </div>
<img src="./assets/logo.png" alt="" srcset="" /> <img src="./assets/logo.png" alt="" srcset="" />
</div> --> </div> -->
<keep-alive exclude="clientDetail,clientGroupDetail,tagsManage,clientDataOverview,guestGroup,guestGroupAdd,guestGroupDetail,group,viewCustomers,crowdDetail,crowdAdd,crowdManage"> <keep-alive exclude="clientDetail,clientGroupDetail,tagsManage,clientDataOverview,guestGroup,guestGroupAdd,guestGroupDetail,group,viewCustomers,crowdDetail,crowdAdd,crowdManage,leadBasicInfo">
<router-view></router-view> <router-view></router-view>
</keep-alive> </keep-alive>
</div> </div>
......
/**
* 新增参数sign 判断接口是否需要sign签名(默认有,不必写)
*/
/**
* 用法 : this.$apis.demo.GETLISTDEVICEFILEUNSTOCK(...)
* @param {*} params
* @returns
*/
import { http, http3 } from '@/main'
// http 对应的域名http://ismv.branch.glsx.com.cn
// 线索管理查询数据
export function getTableList(params) {
params.method = 'scrm.api.wwbench.clue.list'
return http({
// http://192.168.1.144:7231
url: '/rop-scrm-wwbench/router',
method: 'POST',
data: params,
sign: true
})
}
export function getBaseInfo(params) {
params.method = 'scrm.api.wwbench.clue.detail'
return http({
// http://192.168.1.144:7231
url: '/rop-scrm-wwbench/router',
method: 'POST',
data: params,
sign: true
})
}
\ No newline at end of file \ No newline at end of file
import GLCombiForm from './src/index.vue'
// 为组件提供 install 安装方法,供按需引入
GLCombiForm.install = function(Vue) {
Vue.component(GLCombiForm.name, GLCombiForm)
}
// 默认导出组件
export default GLCombiForm
\ No newline at end of file \ No newline at end of file
/**
* 时间控件-限制月份
*/
export const beforeRangePickerOptions = {
disabledDate(date) {
if (date > new Date()) {
return true
}
return false
}
}
export const afterRangePickerOptions = {
disabledDate(date) {
const yesterday = new Date(new Date().setDate(new Date().getDate() - 1))
if (date < yesterday) {
return true
}
return false
}
}
import GLSearch from './src/index.vue'
// 为组件提供 install 安装方法,供按需引入
GLSearch.install = function(Vue) {
Vue.component(GLSearch.name, GLSearch)
}
// 默认导出组件
export default GLSearch
\ No newline at end of file \ No newline at end of file
<!-- <content> -->
<GLSearch @onOk="handleOkFn" @onRest="handleRestFn">
<GLSearchItem>
<div slot="name">我是文本输入框</div>
<el-input size="small" v-model="input" placeholder="请输入内容"></el-input>
</GLSearchItem>
<GLSearchItem>
<div slot="name">我是文本输入框</div>
<el-select v-model="value" size="small" placeholder="请选择">
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
</GLSearchItem>
<GLSearchItem>
<div slot="name">我是文本输入框</div>
<el-date-picker size="small" v-model="value1" type="datetimerange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
</GLSearchItem>
<GLSearchItem>
<el-select v-model="selvalue" placeholder="请选择" size="small" slot="name">
<el-option v-for="item in seloptions" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
<el-input size="small" v-model="input" placeholder="请输入内容"></el-input>
</GLSearchItem>
</GLSearch>
<el-button type="warning" @click="toggleShow(1)">显示代码</el-button>
```js {mixin:true}
{
data() {
return {
demo1: true,
//gl-search数据
input: '',
options: [
{
value: '选项1',
label: '黄金糕'
},
{
value: '选项2',
label: '双皮奶'
},
{
value: '选项3',
label: '蚵仔煎'
},
{
value: '选项4',
label: '龙须面'
},
{
value: '选项5',
label: '北京烤鸭'
}
],
value: '',
value1: [new Date(2000, 10, 10, 10, 10), new Date(2000, 10, 11, 10, 10)],
seloptions: [
{
value: '选项1',
label: '黄金糕'
},
{
value: '选项2',
label: '双皮奶'
},
{
value: '选项3',
label: '蚵仔煎北京烤鸭'
},
{
value: '选项4',
label: '龙须面北京烤鸭'
},
{
value: '选项5',
label: '北京烤鸭北京烤鸭'
}
],
selvalue: ''
}
},
methods:{
toggleShow(num){
// console.log(123)
this['demo' + num] = !this['demo' + num]
},
//gl-search 方法
handleOkFn() {
console.log('您点击了确定')
},
handleRestFn() {
console.log('您点击了取消')
}
}
}
```
# 用来作为 markdown 代码的示例部分
<div v-if="demo1">
```vue
<template>
<GLSearch @onOk="handleOkFn" @onRest="handleRestFn">
<GLSearchItem>
<div slot="name">我是文本输入框</div>
<el-input size="small" v-model="input" placeholder="请输入内容"></el-input>
</GLSearchItem>
<GLSearchItem>
<div slot="name">我是文本输入框</div>
<el-select v-model="value" size="small" placeholder="请选择">
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
</GLSearchItem>
<GLSearchItem>
<div slot="name">我是文本输入框</div>
<el-date-picker size="small" v-model="value1" type="datetimerange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
</GLSearchItem>
<GLSearchItem>
<el-select v-model="selvalue" placeholder="请选择" size="small" slot="name">
<el-option v-for="item in seloptions" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
<el-input size="small" v-model="input" placeholder="请输入内容"></el-input>
</GLSearchItem>
</GLSearch>
</template>
<script>
import {GLSearch, GLSearchItem} from 'glsx-components'
// 全局引入一次css即可
import 'glsx-components/dist/glsx-components.css'
export default {
data() {
return {
//gl-search数据
input: '',
options: [
{
value: '选项1',
label: '黄金糕'
},
{
value: '选项2',
label: '双皮奶'
},
{
value: '选项3',
label: '蚵仔煎'
},
{
value: '选项4',
label: '龙须面'
},
{
value: '选项5',
label: '北京烤鸭'
}
],
value: '',
value1: [new Date(2000, 10, 10, 10, 10), new Date(2000, 10, 11, 10, 10)],
seloptions: [
{
value: '选项1',
label: '黄金糕'
},
{
value: '选项2',
label: '双皮奶'
},
{
value: '选项3',
label: '蚵仔煎北京烤鸭'
},
{
value: '选项4',
label: '龙须面北京烤鸭'
},
{
value: '选项5',
label: '北京烤鸭北京烤鸭'
}
],
selvalue: ''
}
},
methods: {
handleOkFn() {
console.log('您点击了确定')
},
handleRestFn() {
console.log('您点击了取消')
}
}
}
</script>
```
</div>
<!-- </content> -->
<template>
<div class="gl-search" id="gl-search" :class="{ transTo: !expand }">
<div class="search-list">
<!-- 默认插槽 -->
<slot></slot>
<!-- <div class="search-item">
<div class="name">我是文本输入框</div>
<div class="input">
<el-input
size="small"
v-model="input"
placeholder="请输入内容"
></el-input>
</div>
</div> -->
<!-- <div class="search-item">
<div class="name">我是文本输入框</div>
<div class="input">
<el-input
size="small"
v-model="input"
placeholder="请输入内容"
></el-input>
</div>
</div> -->
<!-- <div class="search-item">
<div class="name">我是文本输入框</div>
<div class="input">
<el-input
size="small"
v-model="input"
placeholder="请输入内容"
></el-input>
</div>
</div>
<div class="search-item">
<div class="name">我是文本输入框</div>
<div class="input">
<el-input
size="small"
v-model="input"
placeholder="请输入内容"
></el-input>
</div>
</div> -->
</div>
<div class="gl-operate">
<div class="operate">
<el-button size="small" type="primary" @click="handleOk">查询</el-button>
<el-button size="small" @click="handleRest">重置</el-button>
<el-button type="text" size="small" @click="expandFn" v-if="hasExpand">
<span>{{ !expand ? '展开' : '收起' }}</span>
<i class="expand" :class="classIcon"></i>
</el-button>
<!-- <i class="el-icon-arrow-down expand"></i> -->
<!-- <i class="el-icon-arrow-up"></i> -->
</div>
</div>
</div>
</template>
<script>
export default {
name: 'GLSearch',
props: {},
data() {
return {
// input: '',
expand: false,
itemNum: 0,
time: null,
hasExpand: false
}
},
created() {},
mounted() {
this.getItemNum()
// 判断宽度按,是否显示展开收起
this.getClientWith()
window.addEventListener('resize', this.getClientWith, false)
},
computed: {
classIcon() {
return !this.expand ? 'el-icon-arrow-down' : 'el-icon-arrow-up'
}
},
methods: {
// 展开收起
expandFn() {
this.expand = !this.expand
},
// 获取item 输入框 的个数
getItemNum() {
const items = document.getElementById('gl-search').getElementsByClassName('search-item').length
this.itemNum = items
},
// 判断是否有展开收起标志
ifHasExpand(nowCol) {
if (this.itemNum > nowCol) {
return true
}
return false
},
// 监听函数
getClientWith() {
if (this.time) clearTimeout(this.time)
this.time = setTimeout(() => {
const clientWidth = document.documentElement.clientWidth
// console.log('clientWidth: ', clientWidth)
if (clientWidth <= 800) {
// 1列
this.hasExpand = this.ifHasExpand(1)
} else if (clientWidth <= 1440 && clientWidth > 800) {
// 2列
this.hasExpand = this.ifHasExpand(2)
} else if (clientWidth <= 1720 && clientWidth > 1440) {
// 3列
this.hasExpand = this.ifHasExpand(3)
} else {
// 4列
this.hasExpand = this.ifHasExpand(4)
}
}, 300)
},
handleOk() {
// 点击确定的回调
this.$emit('onOk')
},
handleRest() {
// 点击重置的回调
this.$emit('onRest')
}
},
components: {},
watch: {},
beforeDestroy() {
window.removeEventListener('resize', this.getClientWith, false)
this.time = null
}
}
</script>
<style lang="scss">
.gl-search {
&.transTo {
height: 52px;
}
display: flex;
justify-content: space-between;
overflow: hidden;
// @media screen and (max-width: 1062px) {
// .search-list {
// .search-item {
// width: 100%;
// }
// }
// }
// @media screen and (min-width: 1062px) and (max-width: 1440px) {
// .search-list {
// .search-item {
// width: 100%;
// }
// }
// }
// @media screen and (min-width: 1440px) and (max-width: 1720px) {
// .search-list {
// .search-item {
// width: 100%;
// }
// }
// }
// @media screen and (min-width: 1720px) {
// .search-list {
// .search-item {
// width: 100%;
// }
// }
// }
.search-list {
.search-item {
width: 100%;
}
}
.search-list {
flex: 1;
display: flex;
flex-wrap: wrap;
.search-item {
// flex: 1;
// padding-right: 12px;
margin-bottom: 20px;
min-width: 276px;
display: flex;
align-items: center;
box-sizing: border-box;
.name {
width: 112px;
text-align: right;
font-size: 14px;
font-weight: 400;
color: #666;
}
.input {
flex: 1;
// width:100%;
}
.el-input {
width: 100%;
}
.el-select {
width: 100%;
}
.el-date-editor {
width: 100%;
}
}
}
.gl-operate {
display: flex;
align-items: flex-end;
.operate {
text-align: left;
width: 190px;
margin-bottom: 20px;
.expand {
font-size: 14px;
}
.el-button + .el-button {
margin-left: 8px;
}
}
}
}
</style>
import GLSearchItem from './src/index.vue'
// 为组件提供 install 安装方法,供按需引入
GLSearchItem.install = function(Vue) {
Vue.component(GLSearchItem.name, GLSearchItem)
}
// 默认导出组件
export default GLSearchItem
\ No newline at end of file \ No newline at end of file
<template>
<div :style="{ 'padding-right': spacer + 'px' }" class="search-item">
<div class="name">
<!-- {{ label }} -->
<!-- name 插槽 -->
<slot name="name"></slot>
</div>
<div class="input">
<!-- 默认插槽 -->
<slot></slot>
<!-- <el-input
size="small"
v-model="input"
placeholder="请输入内容"
></el-input> -->
</div>
</div>
</template>
<script>
export default {
name: 'GLSearchItem',
props: {
// 每个项间隙
spacer: {
type: Number,
default: 12
}
},
data () {
return {}
},
created () {},
mounted () {},
computed: {},
methods: {},
components: {},
watch: {}
}
</script>
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
<el-col :span="12" :key="index"> <el-col :span="12" :key="index">
<div class="label-wrap"> <div class="label-wrap">
<label>{{ params.label }}</label> <label>{{ params.label }}</label>
<span>{{ list[params.prop]? list[params.prop]: '--'}}</span> <span>{{ list[params.prop] ? list[params.prop] : '--' }}</span>
</div> </div>
</el-col> </el-col>
</template> </template>
...@@ -47,7 +47,7 @@ export default { ...@@ -47,7 +47,7 @@ export default {
padding: 20px 0; padding: 20px 0;
box-sizing: border-box; box-sizing: border-box;
background: #f5f5f5; background: #f5f5f5;
margin-bottom:10px; margin-bottom: 10px;
.el-row { .el-row {
&:last-child { &:last-child {
margin-bottom: -20px; margin-bottom: -20px;
......
<template>
<div class="square-main" v-loading="loading">
<el-dialog title="选择跟进专员" :visible.sync="dialogVisible" width="50%" :before-close="handleClose">
<el-form :inline="true" :model="tableSearchForm">
<el-form-item size="small" label="员工">
<el-input v-model="tableSearchForm.staffName" placeholder="请输入员工姓名"></el-input>
</el-form-item>
<el-form-item size="small">
<el-button type="primary" @click="handleSearch">查询</el-button>
</el-form-item>
</el-form>
<GLTable v-if="dialogVisible" ref="table" :layout="layout" :tableData="tableData" :tableTotal="tableTotal" :pageConf="pageConf" :tableParams="tableParams" @refreshTable="handleSearch" @selectionTable="selectionTable"></GLTable>
<span slot="footer" class="dialog-footer">
<a class="dialog-jump" @click="jumpUrl">新增专员</a>
<el-button size="small" @click="handleCancel">取 消</el-button>
<el-button size="small" type="primary" @click.native="handleSelect">确 定</el-button>
</span>
</el-dialog>
</div>
</template>
<script>
import { utils } from 'glsx-common'
import util from '@/utils/util'
export default {
name: 'selectEmp',
data() {
return {
loading: false,
dialogVisible: false,
tableSearchForm: {},
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
tableParams: {
listName: 'data',
tableOption: false,
// 行数据的key
mutiSelectUniqueKey: 'id',
// 多选ref的名称
mutiSelectName: 'salelist',
tableColumns: [
{
label: '姓名',
prop: 'staffName'
},
{
label: '部门',
prop: 'departmentName'
},
{
label: '跟进专员类型',
prop: 'followerTypeName'
}
]
},
layout: 'sizes, prev, pager, next, jumper, ->, total',
tableData: [],
tableTotal: 0,
selectItem: [],
selectEmp: []
}
},
methods: {
jumpUrl() {
util.openUrl(location.origin + '/settings/followUp/index')
},
getFollower() {
var params = {
...JSON.parse(JSON.stringify(this.tableSearchForm)),
pageSize: this.$refs.table.page.pageSize,
pageNum: this.$refs.table.page.pageNum
}
this.$apis.channel.getFollower(params).then(res => {
this.tableData = res.data
this.tableTotal = res.count
this.tableData.forEach(item => {
this.selectEmp.forEach((itm, index) => {
if (itm.staffId == item.relationId) {
this.$refs.table.$refs.salelistMutiTable.toggleRowSelection(item)
this.selectEmp.splice(index, 1)
}
})
})
})
},
init(item) {
this.tableSearchForm = {}
this.selectEmp = JSON.parse(JSON.stringify(item))
this.dialogVisible = true
this.$nextTick(() => {
this.$refs.table.page.pageNum = 1
this.getFollower()
})
},
handleSearch() {
this.getFollower()
},
selectionTable(val) {
this.selectItem = val
},
handleClose() {
this.handleCancel()
},
handleCancel: utils.debounce(function() {
this.dialogVisible = false
this.$refs.table.$refs.salelistMutiTable.clearSelection()
}, 300),
handleSelect: utils.debounce(function() {
this.loading = true
let selectEmp = this.selectEmp.map(item => {
return {
relationId: item.staffId,
staffName: item.staffName
}
})
const selectItem = this.selectItem.concat(selectEmp)
if (selectItem.length == 0) {
this.$message.error('请选择员工')
return
}
this.loading = false
this.dialogVisible = false
this.$emit('selectTable', this.selectItem.concat(selectEmp))
this.$refs.table.$refs.salelistMutiTable.clearSelection()
}, 300)
}
}
</script>
<style lang="scss" scoped>
.dialog-jump {
color: #5850ff;
float: left;
line-height: 24px;
text-decoration: underline;
cursor: pointer;
}
.square-main {
/deep/ {
.el-table {
height: 40vh;
overflow-y: auto;
}
.el-table::before {
left: 0;
bottom: 0;
width: 100%;
height: 0px;
}
}
}
</style>
\ No newline at end of file \ No newline at end of file
<template>
<div class="el-descriptions">
<div class="el-descriptions__body">
<table class="el-descriptions__table is-bordered">
<tbody v-for="(item, index) in tableModel" :key="index">
<tr class="el-descriptions-row">
<template v-for="(trTtem, idx) in item.colList">
<th :key="idx" :colspan="trTtem.thColspan" class="el-descriptions-item__cell el-descriptions-item__label is-bordered-label">{{ trTtem.label }}</th>
<td :key="idx" :colspan="trTtem.tdColspan" class="el-descriptions-item__cell el-descriptions-item__content" :style="{ color: trTtem.color }">{{ showData[trTtem.name] }}{{ trTtem.unit }}</td>
</template>
</tr>
</tbody>
</table>
</div>
</div>
</template>
<script>
export default {
name: 'ylDescriptions',
props: {
tableModel: {
type: Array,
default: () => []
},
showData: {
type: Object,
default: () => {}
}
}
}
</script>
<style lang="scss" scoped>
.el-descriptions .is-bordered {
table-layout: auto;
margin: 25px 20px 40px 44px;
}
.el-descriptions__body .el-descriptions__table {
border-collapse: collapse;
table-layout: fixed;
}
.el-descriptions :not(.is-bordered) .el-descriptions-item__cell {
padding-bottom: 12px;
}
.el-descriptions .is-bordered .el-descriptions-item__cell {
border: 1px solid #ebeef5;
padding: 12px 10px;
}
.el-descriptions-item__label.is-bordered-label {
font-weight: 700;
color: #333333;
background: #f4f6fc;
}
.el-descriptions :not(.is-bordered) .el-descriptions-item__cell {
padding-bottom: 12px;
}
.el-descriptions .is-bordered .el-descriptions-item__cell {
border: 1px solid #e8e8ea;
padding: 7px 10px;
}
.el-descriptions__body .el-descriptions__table .el-descriptions-item__cell {
box-sizing: border-box;
text-align: left;
font-weight: 400;
line-height: 1.5;
width: 118px;
vertical-align: middle;
font-size: 14px;
}
.el-descriptions-item__content {
word-break: break-word;
overflow-wrap: break-word;
min-width: 238px;
}
</style>
...@@ -12,25 +12,25 @@ const staticRoutes = Object.freeze([{ ...@@ -12,25 +12,25 @@ const staticRoutes = Object.freeze([{
}, },
{ {
name: 'clientDataOverview', name: 'clientDataOverview',
path: "/clientDataOverview/index", path: '/clientDataOverview/index',
component: resolve => require([`@/views/clientDataOverview/index.vue`], resolve), component: resolve => require([`@/views/clientDataOverview/index.vue`], resolve),
meta: {} meta: {}
}, },
{ {
name: 'clientDataOverview', name: 'clientDataOverview',
path: "/clientDataOverview/group/:id", path: '/clientDataOverview/group/:id',
component: resolve => require([`@/views/clientDataOverview/group.vue`], resolve), component: resolve => require([`@/views/clientDataOverview/group.vue`], resolve),
meta: {} meta: {}
}, },
{ {
name: 'clientManage', name: 'clientManage',
path: "/clientManage/index", path: '/clientManage/index',
component: resolve => require([`@/views/clientManage/index.vue`], resolve), component: resolve => require([`@/views/clientManage/index.vue`], resolve),
meta: {} meta: {}
}, },
{ {
name: 'clientDetail', name: 'clientDetail',
path: "/clientManage/clientDetail", path: '/clientManage/clientDetail',
component: resolve => require([`@/views/clientManage/clientDetail.vue`], resolve), component: resolve => require([`@/views/clientManage/clientDetail.vue`], resolve),
meta: {} meta: {}
}, },
...@@ -42,88 +42,106 @@ const staticRoutes = Object.freeze([{ ...@@ -42,88 +42,106 @@ const staticRoutes = Object.freeze([{
// }, // },
{ {
name: 'clientGroupManage', name: 'clientGroupManage',
path: "/clientGroupManage/index", path: '/clientGroupManage/index',
component: resolve => require([`@/views/clientGroupManage/index.vue`], resolve), component: resolve => require([`@/views/clientGroupManage/index.vue`], resolve),
meta: {} meta: {}
}, },
{ {
name: 'clientGroupDetail', name: 'clientGroupDetail',
path: "/clientGroupManage/clientGroupDetail", path: '/clientGroupManage/clientGroupDetail',
component: resolve => require([`@/views/clientGroupManage/clientGroupDetail.vue`], resolve), component: resolve => require([`@/views/clientGroupManage/clientGroupDetail.vue`], resolve),
meta: {} meta: {}
}, },
{ {
name: 'tagsManage', name: 'tagsManage',
path: "/tagsManage/index", path: '/tagsManage/index',
component: resolve => require([`@/views/tagsManage/index.vue`], resolve), component: resolve => require([`@/views/tagsManage/index.vue`], resolve),
meta: {} meta: {}
}, },
{ {
name: 'viewCustomers', name: 'viewCustomers',
path: "/tagsManage/viewCustomers/:info/:type", path: '/tagsManage/viewCustomers/:info/:type',
component: resolve => require([`@/views/tagsManage/viewCustomers.vue`], resolve), component: resolve => require([`@/views/tagsManage/viewCustomers.vue`], resolve),
meta: {}, meta: {}
}, },
{ {
name: 'expand', name: 'expand',
path: "/expand/index", path: '/expand/index',
component: resolve => require([`@/views/expand/index.vue`], resolve), component: resolve => require([`@/views/expand/index.vue`], resolve),
meta: {} meta: {}
}, },
{ {
name: 'employee', name: 'employee',
path: "/employee/index", path: '/employee/index',
component: resolve => require([`@/views/employee/index.vue`], resolve), component: resolve => require([`@/views/employee/index.vue`], resolve),
meta: {} meta: {}
}, },
{ {
name: 'employee', name: 'employee',
path: "/employee/detail", path: '/employee/detail',
component: resolve => require([`@/views/employee/detail.vue`], resolve), component: resolve => require([`@/views/employee/detail.vue`], resolve),
meta: {} meta: {}
}, },
{ {
name: 'employee', name: 'employee',
path: "/employee/add", path: '/employee/add',
component: resolve => require([`@/views/employee/add.vue`], resolve), component: resolve => require([`@/views/employee/add.vue`], resolve),
meta: {} meta: {}
}, },
{ {
name: 'guestGuest', name: 'guestGuest',
path: "/guestGroup/index", path: '/guestGroup/index',
component: resolve => require([`@/views/guestGroup/index.vue`], resolve), component: resolve => require([`@/views/guestGroup/index.vue`], resolve),
meta: {} meta: {}
}, },
{ {
name: 'guestAdd', name: 'guestAdd',
path: "/guestGroup/add/:id", path: '/guestGroup/add/:id',
component: resolve => require([`@/views/guestGroup/add.vue`], resolve), component: resolve => require([`@/views/guestGroup/add.vue`], resolve),
meta: {} meta: {}
}, },
{ {
name: 'guestDetail', name: 'guestDetail',
path: "/guestGroup/detail/:id", path: '/guestGroup/detail/:id',
component: resolve => require([`@/views/guestGroup/detail.vue`], resolve), component: resolve => require([`@/views/guestGroup/detail.vue`], resolve),
meta: {} meta: {}
}, },
{ {
name: 'crowdManage', name: 'crowdManage',
path: "/crowdManage/index", path: '/crowdManage/index',
component: resolve => require([`@/views/crowdManage/index.vue`], resolve), component: resolve => require([`@/views/crowdManage/index.vue`], resolve),
meta: {} meta: {}
}, },
{ {
name: 'crowdAdd', name: 'crowdAdd',
path: "/crowdManage/crowdAdd", path: '/crowdManage/crowdAdd',
component: resolve => require([`@/views/crowdManage/crowdAdd.vue`], resolve), component: resolve => require([`@/views/crowdManage/crowdAdd.vue`], resolve),
meta: {} meta: {}
}, },
{ {
name: 'crowdDetail', name: 'crowdDetail',
path: "/crowdManage/crowdDetail:id", path: '/crowdManage/crowdDetail:id',
component: resolve => require([`@/views/crowdManage/crowdDetail.vue`], resolve), component: resolve => require([`@/views/crowdManage/crowdDetail.vue`], resolve),
meta: {} meta: {}
}, },
{
name: 'leadManage',
path: '/leadManage/index',
component: resolve => require([`@/views/leadManage/index.vue`], resolve),
meta: {}
},
{
name: 'leadAllocation',
path: '/leadManage/leadAllocation',
component: resolve => require([`@/views/leadManage/leadAllocation.vue`], resolve),
meta: {}
},
{
name: 'leadBasicInfo',
path: '/leadManage/leadBasicInfo/:id/:type',
component: resolve => require([`@/views/leadManage/leadBasicInfo.vue`], resolve),
meta: {}
}
]) ])
export default staticRoutes export default staticRoutes
// { // {
......
...@@ -2,19 +2,26 @@ import Vue from 'vue' ...@@ -2,19 +2,26 @@ import Vue from 'vue'
import { message } from '@/plugins/element.js' import { message } from '@/plugins/element.js'
import { fetchConfig } from '@/config' import { fetchConfig } from '@/config'
import ElementUI from 'element-ui' import ElementUI from 'element-ui'
import { GLButton, GLTable } from 'glsx-components' //权限按钮 (根据权限动态创建) import { GLButton, GLTable, GLFooter } from 'glsx-components' //权限按钮 (根据权限动态创建)
import { getRoutes } from '@/router' import { getRoutes } from '@/router'
import render from './render' import render from './render'
import GLCombiForm from '@/components/GlCombiForm'
import GlSearch from '@/components/GlSearch'
import GlSearchItem from '@/components/GlSearchItem'
Vue.use(GlSearch)
Vue.use(GlSearchItem)
Vue.use(GLCombiForm)
Vue.use(ElementUI) Vue.use(ElementUI)
Vue.use(GLTable) Vue.use(GLTable)
Vue.use(GLFooter)
import 'glsx-components/dist/glsx-components.css' import 'glsx-components/dist/glsx-components.css'
let routes = [] let routes = []
let router = null let router = null
let instance = null let instance = null
// http:调的是新版标签的接口,http2:调的是客户相关接口;http3:企微授权那边的接口 目前导出接口都测试的:http3 // http:调的是新版标签的接口,http2:调的是客户相关接口;http3:企微授权那边的接口 目前导出接口都测试的:http3
export async function bootstrap({ name, id, history, common, messenger, globalState,routerBase }) { export async function bootstrap({ name, id, history, common, messenger, globalState, routerBase }) {
const { response, request,request2,request3, request4,sign, secret, sign_common, request_common } = await fetchConfig(globalState.configSwitch)//globalState.configSwitch const { response, request, request2, request3, request4, sign, secret, sign_common, request_common } = await fetchConfig(globalState.configSwitch) //globalState.configSwitch
Vue.prototype.$history = history Vue.prototype.$history = history
Vue.prototype.$messenger = messenger Vue.prototype.$messenger = messenger
Vue.prototype.$globalState = globalState Vue.prototype.$globalState = globalState
......
<template> <template>
<div class="sub-container"> <div class="sub-container">
<search-form class="searchTop border-shadow" :isHasSyncBtn="true" :isThreeRowShow="true" :showDefaultTime="false" :formModel="searchForm" :formList="clientGroupFormList" @setTableHeightEvent="setTableHeightEvent"> <GLCombiForm class="sub-form-style" :formObj="searchForm" :formData="clientGroupFormList" @handleOk="searchTable" @handleRest="resetTable"></GLCombiForm>
<span class="inline-b" slot="form-slot">
<el-button plain @click="resetTable">重置</el-button>
<el-button type="primary" @click="searchTable">查询</el-button>
<el-button type="primary" @click="handleExport">导出</el-button>
</span>
</search-form>
<!-- :tableId="$route.query.id" 去掉,表格组件也应该去掉 --> <!-- :tableId="$route.query.id" 去掉,表格组件也应该去掉 -->
<div class="leadList">
<div>
<span></span>
</div>
<el-button size="small" @click="handleExport">导出</el-button>
</div>
<GLTable ref="clientGroupDetail" @setTableFinishFun="setTableFinishFun" :hasNum="true" :pageConf="pageConf" :getListApi="getListApi" :beforeSearchFn="beforeSearchFn" :searchForm="searchFormTable" :tableParams="tableParams" :headerStyle="{ height: '54px', background: '#F4F6FC', color: '#333333', fontSize: '14px' }" :noDataImg="url"> <GLTable ref="clientGroupDetail" @setTableFinishFun="setTableFinishFun" :hasNum="true" :pageConf="pageConf" :getListApi="getListApi" :beforeSearchFn="beforeSearchFn" :searchForm="searchFormTable" :tableParams="tableParams" :headerStyle="{ height: '54px', background: '#F4F6FC', color: '#333333', fontSize: '14px' }" :noDataImg="url">
<span slot="customerName" class="flex-center" slot-scope="scope"> <span slot="customerName" class="flex-center" slot-scope="scope">
<el-tooltip effect="dark" :content="scope.scope.customerName" placement="top"> <el-tooltip effect="dark" :content="scope.scope.customerName" placement="top">
<span class="ellipsis-1" style="display: inline-block; max-width: 70px; text-align: left">{{ scope.scope.customerName }}</span> <span class="ellipsis-1" style="display: inline-block; max-width: 70px; text-align: left">{{ scope.scope.customerName }}</span>
</el-tooltip> </el-tooltip>
<span class="pure-blue-text">{{ scope.scope.type == 1 ? '@微信' : scope.scope.type == 2 ? '@企微' : scope.scope.type == null ? '' :''}}</span> <span class="pure-blue-text">{{ scope.scope.type == 1 ? '@微信' : scope.scope.type == 2 ? '@企微' : scope.scope.type == null ? '' : '' }}</span>
<!-- <span class="pure-blue-text">{{ scope.scope.type == 1 ? '@微信' : scope.scope.type == 2 ? '@企微' :''}}</span> --> <!-- <span class="pure-blue-text">{{ scope.scope.type == 1 ? '@微信' : scope.scope.type == 2 ? '@企微' :''}}</span> -->
</span> </span>
<span slot="customerSex" slot-scope="scope"> <span slot="customerSex" slot-scope="scope">
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
</template> </template>
<script> <script>
import { getDetailTableList,clientExportApi } from '@/api/modules/clientGroupManage' import { getDetailTableList, clientExportApi } from '@/api/modules/clientGroupManage'
export default { export default {
props: { props: {
url: { url: {
...@@ -45,9 +45,12 @@ export default { ...@@ -45,9 +45,12 @@ export default {
searchFormTable: {}, searchFormTable: {},
clientGroupFormList: [ clientGroupFormList: [
{ {
type: 'daterange', type: 'datePicker',
prop: 'daterange', name: 'daterange',
label: '入群时间', label: '入群时间',
datePickerAttrs: {
'value-format': 'yyyy-MM-dd'
},
pickerOptions: { pickerOptions: {
disabledDate(time) { disabledDate(time) {
return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime() return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime()
...@@ -56,10 +59,12 @@ export default { ...@@ -56,10 +59,12 @@ export default {
}, },
{ {
type: 'select', type: 'select',
prop: 'customerSex', name: 'customerSex',
label: '性别', label: '性别',
optionLabel: 'label',
optionId: 'value',
placeholder: '请选择性别', placeholder: '请选择性别',
options: [ optionList: [
{ {
label: '全部', label: '全部',
value: null value: null
...@@ -81,14 +86,14 @@ export default { ...@@ -81,14 +86,14 @@ export default {
{ {
type: 'input', type: 'input',
inputType: 'text', inputType: 'text',
prop: 'groupNickName', name: 'groupNickName',
label: '本群昵称', label: '本群昵称',
placeholder: '请输入本群昵称' placeholder: '请输入本群昵称'
}, },
{ {
type: 'input', type: 'input',
inputType: 'text', inputType: 'text',
prop: 'customerName', name: 'customerName',
label: '客户名称', label: '客户名称',
placeholder: '请输入客户名称' placeholder: '请输入客户名称'
} }
...@@ -101,7 +106,7 @@ export default { ...@@ -101,7 +106,7 @@ export default {
{ {
label: '本群昵称', label: '本群昵称',
prop: 'groupNickName', prop: 'groupNickName',
minWidth:120 minWidth: 120
}, },
{ {
label: '客户名称', label: '客户名称',
...@@ -112,7 +117,7 @@ export default { ...@@ -112,7 +117,7 @@ export default {
{ {
label: '手机号码', label: '手机号码',
prop: 'customerPhone', prop: 'customerPhone',
minWidth:120 minWidth: 120
}, },
{ {
label: '性别', label: '性别',
...@@ -123,12 +128,12 @@ export default { ...@@ -123,12 +128,12 @@ export default {
label: '入群方式', label: '入群方式',
prop: 'joinScene', prop: 'joinScene',
addHtml: 'joinScene', addHtml: 'joinScene',
minWidth:120 minWidth: 120
}, },
{ {
label: '邀请人', label: '邀请人',
prop: 'invitorName', prop: 'invitorName',
minWidth:120 minWidth: 120
}, },
{ {
label: '入群时间', label: '入群时间',
...@@ -156,7 +161,7 @@ export default { ...@@ -156,7 +161,7 @@ export default {
} }
}, },
methods: { methods: {
getParams(){ getParams() {
var params = JSON.parse(JSON.stringify(this.searchForm)) var params = JSON.parse(JSON.stringify(this.searchForm))
if (params.daterange) { if (params.daterange) {
params.beginTime = this.searchForm.daterange[0] params.beginTime = this.searchForm.daterange[0]
...@@ -199,7 +204,7 @@ export default { ...@@ -199,7 +204,7 @@ export default {
this.$refs.clientGroupDetail.data.length ? (this.$refs.clientGroupDetail.tableHeightValues = '') : this.$refs.clientGroupDetail.setTableHeightFun() this.$refs.clientGroupDetail.data.length ? (this.$refs.clientGroupDetail.tableHeightValues = '') : this.$refs.clientGroupDetail.setTableHeightFun()
}, },
//导出 //导出
handleExport(){ handleExport() {
var params = this.getParams() var params = this.getParams()
clientExportApi(params).then(res => { clientExportApi(params).then(res => {
this.$Utils.exportFn(res) this.$Utils.exportFn(res)
...@@ -221,9 +226,33 @@ export default { ...@@ -221,9 +226,33 @@ export default {
} }
</script> </script>
<style lang="scss" scope> <style lang="scss" scoped>
.sub-container { .sub-container {
@import '@/styles/variables.scss'; @import '@/styles/variables.scss';
@import '@/styles/resetelement.scss'; @import '@/styles/resetelement.scss';
.leadList {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 8px;
div {
text-align: center;
span:nth-child(1) {
font-weight: 600;
font-size: 16px;
}
}
/deep/ .el-button {
color: #5850ff;
border: 1px solid #5850ff;
}
}
/deep/.sub-form-style {
@media screen and (min-width: 1440px) and (max-width: 1720px) {
.glsx-combi-form .el-form-item--small {
width: 50%;
}
}
}
} }
</style> </style>
<template> <template>
<div class="sub-container"> <div class="sub-container">
<search-form class="searchTop border-shadow" :isHasSyncBtn="true" :isThreeRowShow="true" :showDefaultTime="false" :formModel="searchForm" :formList="clientGroupFormList" @setTableHeightEvent="setTableHeightEvent"> <GLCombiForm class="sub-form-style" :formObj="searchForm" :formData="clientGroupFormList" @handleOk="searchTable" @handleRest="resetTable">
<span class="inline-b" slot="form-slot"> </GLCombiForm>
<el-button plain @click="resetTable">重置</el-button> <div class="leadList">
<el-button type="primary" @click="searchTable">查询</el-button> <div>
<el-button type="primary" @click="handleExport">导出</el-button> <span></span>
</span> </div>
</search-form> <el-button size="small" @click="handleExport">导出</el-button>
</div>
<GLTable ref="clientGroupDetail" @setTableFinishFun="setTableFinishFun" :hasNum="true" :pageConf="pageConf" :getListApi="getListApi" :beforeSearchFn="beforeSearchFn" :searchForm="searchFormTable" :tableParams="tableParams" :headerStyle="{ height: '54px', background: '#F4F6FC', color: '#333333', fontSize: '14px' }" :noDataImg="url"> <GLTable ref="clientGroupDetail" @setTableFinishFun="setTableFinishFun" :hasNum="true" :pageConf="pageConf" :getListApi="getListApi" :beforeSearchFn="beforeSearchFn" :searchForm="searchFormTable" :tableParams="tableParams" :headerStyle="{ height: '54px', background: '#F4F6FC', color: '#333333', fontSize: '14px' }" :noDataImg="url">
<span slot="customerSex" slot-scope="scope"> <span slot="customerSex" slot-scope="scope">
<span>{{ scope.scope.customerSex == 2 ? '女' : scope.scope.customerSex == 1 ? '男' : '未知' }}</span> <span>{{ scope.scope.customerSex == 2 ? '女' : scope.scope.customerSex == 1 ? '男' : '未知' }}</span>
</span> </span>
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
</template> </template>
<script> <script>
import { getDetailStaffTableList,followEmployeeExportApi } from '@/api/modules/clientGroupManage' import { getDetailStaffTableList, followEmployeeExportApi } from '@/api/modules/clientGroupManage'
export default { export default {
props: { props: {
url: { url: {
...@@ -37,9 +37,12 @@ export default { ...@@ -37,9 +37,12 @@ export default {
searchFormTable: {}, searchFormTable: {},
clientGroupFormList: [ clientGroupFormList: [
{ {
type: 'daterange', type: 'datePicker',
prop: 'daterange', name: 'daterange',
label: '入群时间', label: '入群时间',
datePickerAttrs: {
'value-format': 'yyyy-MM-dd'
},
pickerOptions: { pickerOptions: {
disabledDate(time) { disabledDate(time) {
return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime() return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime()
...@@ -48,10 +51,12 @@ export default { ...@@ -48,10 +51,12 @@ export default {
}, },
{ {
type: 'select', type: 'select',
prop: 'customerSex', name: 'customerSex',
label: '性别', label: '性别',
optionLabel: 'label',
optionId: 'value',
placeholder: '请选择性别', placeholder: '请选择性别',
options: [ optionList: [
{ {
label: '全部', label: '全部',
value: null value: null
...@@ -73,14 +78,14 @@ export default { ...@@ -73,14 +78,14 @@ export default {
{ {
type: 'input', type: 'input',
inputType: 'text', inputType: 'text',
prop: 'groupNickName', name: 'groupNickName',
label: '本群昵称', label: '本群昵称',
placeholder: '请输入本群昵称' placeholder: '请输入本群昵称'
}, },
{ {
type: 'input', type: 'input',
inputType: 'text', inputType: 'text',
prop: 'customerName', name: 'customerName',
label: '客户名称', label: '客户名称',
placeholder: '请输入客户名称' placeholder: '请输入客户名称'
} }
...@@ -94,18 +99,17 @@ export default { ...@@ -94,18 +99,17 @@ export default {
{ {
label: '本群昵称', label: '本群昵称',
prop: 'groupNickName', prop: 'groupNickName',
minWidth:120 minWidth: 120
}, },
{ {
label: '员工名称', label: '员工名称',
prop: 'staffName', prop: 'staffName',
minWidth: 150 minWidth: 150
}, },
{ {
label: '手机号码', label: '手机号码',
prop: 'customerPhone', prop: 'customerPhone',
minWidth:120 minWidth: 120
}, },
{ {
label: '性别', label: '性别',
...@@ -116,12 +120,12 @@ export default { ...@@ -116,12 +120,12 @@ export default {
label: '入群方式', label: '入群方式',
prop: 'joinScene', prop: 'joinScene',
addHtml: 'joinScene', addHtml: 'joinScene',
minWidth:120 minWidth: 120
}, },
{ {
label: '邀请人', label: '邀请人',
prop: 'invitorName', prop: 'invitorName',
minWidth:120 minWidth: 120
}, },
{ {
label: '入群时间', label: '入群时间',
...@@ -129,7 +133,6 @@ export default { ...@@ -129,7 +133,6 @@ export default {
width: 140 width: 140
} }
] ]
}, },
getListApi: getDetailStaffTableList, getListApi: getDetailStaffTableList,
clientTableDataNum: 0 clientTableDataNum: 0
...@@ -141,7 +144,7 @@ export default { ...@@ -141,7 +144,7 @@ export default {
} }
}, },
methods: { methods: {
getParams(){ getParams() {
var params = JSON.parse(JSON.stringify(this.searchForm)) var params = JSON.parse(JSON.stringify(this.searchForm))
if (params.daterange) { if (params.daterange) {
params.beginTime = this.searchForm.daterange[0] params.beginTime = this.searchForm.daterange[0]
...@@ -184,7 +187,7 @@ export default { ...@@ -184,7 +187,7 @@ export default {
this.$refs.clientGroupDetail.data.length ? (this.$refs.clientGroupDetail.tableHeightValues = '') : this.$refs.clientGroupDetail.setTableHeightFun() this.$refs.clientGroupDetail.data.length ? (this.$refs.clientGroupDetail.tableHeightValues = '') : this.$refs.clientGroupDetail.setTableHeightFun()
}, },
//导出 //导出
handleExport(){ handleExport() {
var params = this.getParams() var params = this.getParams()
followEmployeeExportApi(params).then(res => { followEmployeeExportApi(params).then(res => {
this.$Utils.exportFn(res) this.$Utils.exportFn(res)
...@@ -206,9 +209,33 @@ export default { ...@@ -206,9 +209,33 @@ export default {
} }
</script> </script>
<style lang="scss" scope> <style lang="scss" scoped>
.sub-container { .sub-container {
@import '@/styles/variables.scss'; @import '@/styles/variables.scss';
@import '@/styles/resetelement.scss'; @import '@/styles/resetelement.scss';
.leadList {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 8px;
div {
text-align: center;
span:nth-child(1) {
font-weight: 600;
font-size: 16px;
}
}
/deep/ .el-button {
color: #5850ff;
border: 1px solid #5850ff;
}
}
/deep/.sub-form-style {
@media screen and (min-width: 1440px) and (max-width: 1720px) {
.glsx-combi-form .el-form-item--small {
width: 50%;
}
}
}
} }
</style> </style>
<template> <template>
<div class="sub-container"> <div class="sub-container">
<search-form class="searchTop border-shadow" :isHasSyncBtn="true" :isThreeRowShow="true" :showDefaultTime="false" :formModel="searchForm" :formList="clientGroupFormList" @setTableHeightEvent="setTableHeightEvent"> <GLCombiForm class="sub-form-style" :formObj="searchForm" :formData="clientGroupFormList" @handleOk="searchTable" @handleRest="resetTable">
<span class="inline-b" slot="form-slot"> </GLCombiForm>
<el-button plain @click="resetTable">重置</el-button> <div class="leadList">
<el-button type="primary" @click="searchTable">查询</el-button> <div>
<el-button type="primary" @click="handleExport">导出</el-button> <span></span>
</span> </div>
</search-form> <el-button size="small" @click="handleExport">导出</el-button>
</div>
<GLTable ref="clientGroupDetail" @setTableFinishFun="setTableFinishFun" :hasNum="true" :pageConf="pageConf" :getListApi="getListApi" :beforeSearchFn="beforeSearchFn" :searchForm="searchFormTable" :tableParams="tableParams" :headerStyle="{ height: '54px', background: '#F4F6FC', color: '#333333', fontSize: '14px' }" :noDataImg="url"> <GLTable ref="clientGroupDetail" @setTableFinishFun="setTableFinishFun" :hasNum="true" :pageConf="pageConf" :getListApi="getListApi" :beforeSearchFn="beforeSearchFn" :searchForm="searchFormTable" :tableParams="tableParams" :headerStyle="{ height: '54px', background: '#F4F6FC', color: '#333333', fontSize: '14px' }" :noDataImg="url">
<span slot="customerName" class="flex-center" slot-scope="scope"> <span slot="customerName" class="flex-center" slot-scope="scope">
<el-tooltip effect="dark" :content="scope.scope.customerName" placement="top"> <el-tooltip effect="dark" :content="scope.scope.customerName" placement="top">
<span class="ellipsis-1" style="display: inline-block; max-width: 70px; text-align: left">{{ scope.scope.customerName }}</span> <span class="ellipsis-1" style="display: inline-block; max-width: 70px; text-align: left">{{ scope.scope.customerName }}</span>
</el-tooltip> </el-tooltip>
<span class="pure-blue-text">{{ scope.scope.type == 1 ? '@微信' : scope.scope.type == 2 ? '@企微' : scope.scope.type == null ? '' :''}} </span> <span class="pure-blue-text">{{ scope.scope.type == 1 ? '@微信' : scope.scope.type == 2 ? '@企微' : scope.scope.type == null ? '' : '' }}</span>
</span> </span>
<span slot="customerSex" slot-scope="scope"> <span slot="customerSex" slot-scope="scope">
<span>{{ scope.scope.customerSex == 2 ? '女' : scope.scope.customerSex == 1 ? '男' : '未知' }}</span> <span>{{ scope.scope.customerSex == 2 ? '女' : scope.scope.customerSex == 1 ? '男' : '未知' }}</span>
...@@ -29,7 +30,7 @@ ...@@ -29,7 +30,7 @@
</template> </template>
<script> <script>
import { getDetailQuitTableList,leaveGroupExportApi } from '@/api/modules/clientGroupManage' import { getDetailQuitTableList, leaveGroupExportApi } from '@/api/modules/clientGroupManage'
export default { export default {
props: { props: {
url: { url: {
...@@ -43,9 +44,12 @@ export default { ...@@ -43,9 +44,12 @@ export default {
searchFormTable: {}, searchFormTable: {},
clientGroupFormList: [ clientGroupFormList: [
{ {
type: 'daterange', type: 'datePicker',
prop: 'daterange', name: 'daterange',
label: '入群时间', label: '入群时间',
datePickerAttrs: {
'value-format': 'yyyy-MM-dd'
},
pickerOptions: { pickerOptions: {
disabledDate(time) { disabledDate(time) {
return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime() return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime()
...@@ -54,10 +58,12 @@ export default { ...@@ -54,10 +58,12 @@ export default {
}, },
{ {
type: 'select', type: 'select',
prop: 'customerSex', name: 'customerSex',
label: '性别', label: '性别',
placeholder: '请选择性别', placeholder: '请选择性别',
options: [ optionLabel: 'label',
optionId: 'value',
optionList: [
{ {
label: '全部', label: '全部',
value: null value: null
...@@ -79,14 +85,14 @@ export default { ...@@ -79,14 +85,14 @@ export default {
{ {
type: 'input', type: 'input',
inputType: 'text', inputType: 'text',
prop: 'groupNickName', name: 'groupNickName',
label: '本群昵称', label: '本群昵称',
placeholder: '请输入本群昵称' placeholder: '请输入本群昵称'
}, },
{ {
type: 'input', type: 'input',
inputType: 'text', inputType: 'text',
prop: 'customerName', name: 'customerName',
label: '客户名称', label: '客户名称',
placeholder: '请输入客户名称' placeholder: '请输入客户名称'
} }
...@@ -98,7 +104,7 @@ export default { ...@@ -98,7 +104,7 @@ export default {
{ {
label: '本群昵称', label: '本群昵称',
prop: 'groupNickName', prop: 'groupNickName',
minWidth:120 minWidth: 120
}, },
{ {
label: '客户名称', label: '客户名称',
...@@ -109,7 +115,7 @@ export default { ...@@ -109,7 +115,7 @@ export default {
{ {
label: '手机号码', label: '手机号码',
prop: 'customerPhone', prop: 'customerPhone',
minWidth:120 minWidth: 120
}, },
{ {
label: '性别', label: '性别',
...@@ -120,12 +126,12 @@ export default { ...@@ -120,12 +126,12 @@ export default {
label: '入群方式', label: '入群方式',
prop: 'joinScene', prop: 'joinScene',
addHtml: 'joinScene', addHtml: 'joinScene',
minWidth:120 minWidth: 120
}, },
{ {
label: '邀请人', label: '邀请人',
prop: 'invitorName', prop: 'invitorName',
minWidth:120 minWidth: 120
}, },
{ {
label: '入群时间', label: '入群时间',
...@@ -153,7 +159,7 @@ export default { ...@@ -153,7 +159,7 @@ export default {
} }
}, },
methods: { methods: {
getParams(){ getParams() {
var params = JSON.parse(JSON.stringify(this.searchForm)) var params = JSON.parse(JSON.stringify(this.searchForm))
if (params.daterange) { if (params.daterange) {
params.beginTime = this.searchForm.daterange[0] params.beginTime = this.searchForm.daterange[0]
...@@ -195,7 +201,7 @@ export default { ...@@ -195,7 +201,7 @@ export default {
this.$refs.clientGroupDetail.data.length ? (this.$refs.clientGroupDetail.tableHeightValues = '') : this.$refs.clientGroupDetail.setTableHeightFun() this.$refs.clientGroupDetail.data.length ? (this.$refs.clientGroupDetail.tableHeightValues = '') : this.$refs.clientGroupDetail.setTableHeightFun()
}, },
//导出 //导出
handleExport(){ handleExport() {
var params = this.getParams() var params = this.getParams()
leaveGroupExportApi(params).then(res => { leaveGroupExportApi(params).then(res => {
this.$Utils.exportFn(res) this.$Utils.exportFn(res)
...@@ -217,9 +223,33 @@ export default { ...@@ -217,9 +223,33 @@ export default {
} }
</script> </script>
<style lang="scss" scope> <style lang="scss" scoped>
.sub-container { .sub-container {
@import '@/styles/variables.scss'; @import '@/styles/variables.scss';
@import '@/styles/resetelement.scss'; @import '@/styles/resetelement.scss';
.leadList {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 8px;
div {
text-align: center;
span:nth-child(1) {
font-weight: 600;
font-size: 16px;
}
}
/deep/ .el-button {
color: #5850ff;
border: 1px solid #5850ff;
}
}
/deep/ .sub-form-style {
@media screen and (min-width: 1440px) and (max-width: 1720px) {
.glsx-combi-form .el-form-item--small {
width: 50%;
}
}
}
} }
</style> </style>
<template> <template>
<div class="sub-container"> <div class="sub-container">
<search-form class="searchTop border-shadow" :isHasSyncBtn="true" :isThreeRowShow="true" :showDefaultTime="false" :formModel="searchForm" :formList="clientGroupFormList" @setTableHeightEvent="setTableHeightEvent"> <GLCombiForm :formObj="searchForm" :formData="clientGroupFormList" @handleOk="searchTable" @handleRest="resetTable">n>
<span class="inline-b" slot="form-slot"> </GLCombiForm>
<el-button plain @click="resetTable">重置</el-button> <div class="leadList">
<el-button type="primary" @click="searchTable">查询</el-button> <div>
<el-button type="primary" @click="handleExport">导出</el-button> <span></span>
</span> </div>
</search-form> <el-button size="small" @click="handleExport">导出</el-button>
</div>
<!-- :tableId="$route.query.id" 去掉,表格组件也应该去掉 --> <!-- :tableId="$route.query.id" 去掉,表格组件也应该去掉 -->
<GLTable ref="clientGroupDetail" @setTableFinishFun="setTableFinishFun" :hasNum="true" :pageConf="pageConf" :getListApi="getListApi" :beforeSearchFn="beforeSearchFn" :searchForm="searchFormTable" :tableParams="tableParams" :headerStyle="{ height: '54px', background: '#F4F6FC', color: '#333333', fontSize: '14px' }" :noDataImg="url"> <GLTable ref="clientGroupDetail" @setTableFinishFun="setTableFinishFun" :hasNum="true" :pageConf="pageConf" :getListApi="getListApi" :beforeSearchFn="beforeSearchFn" :searchForm="searchFormTable" :tableParams="tableParams" :headerStyle="{ height: '54px', background: '#F4F6FC', color: '#333333', fontSize: '14px' }" :noDataImg="url">
<span slot="customerName" class="flex-center" slot-scope="scope"> <span slot="customerName" class="flex-center" slot-scope="scope">
...@@ -14,7 +15,7 @@ ...@@ -14,7 +15,7 @@
<span class="ellipsis-1" style="display: inline-block; max-width: 70px; text-align: left">{{ scope.scope.customerName }}</span> <span class="ellipsis-1" style="display: inline-block; max-width: 70px; text-align: left">{{ scope.scope.customerName }}</span>
</el-tooltip> </el-tooltip>
<span class="pure-blue-text">{{ scope.scope.type == 1 ? '@微信' : scope.scope.type == 2 ? '@企微' : scope.scope.type == null ? '' :''}} </span> <span class="pure-blue-text">{{ scope.scope.type == 1 ? '@微信' : scope.scope.type == 2 ? '@企微' : scope.scope.type == null ? '' : '' }}</span>
</span> </span>
<span slot="customerSex" slot-scope="scope"> <span slot="customerSex" slot-scope="scope">
<span>{{ scope.scope.customerSex == 2 ? '女' : scope.scope.customerSex == 1 ? '男' : '未知' }}</span> <span>{{ scope.scope.customerSex == 2 ? '女' : scope.scope.customerSex == 1 ? '男' : '未知' }}</span>
...@@ -30,7 +31,7 @@ ...@@ -30,7 +31,7 @@
</template> </template>
<script> <script>
import { getDetailPotentialTableList,potentialClientExportApi } from '@/api/modules/clientGroupManage' import { getDetailPotentialTableList, potentialClientExportApi } from '@/api/modules/clientGroupManage'
export default { export default {
props: { props: {
url: { url: {
...@@ -44,9 +45,12 @@ export default { ...@@ -44,9 +45,12 @@ export default {
searchFormTable: {}, searchFormTable: {},
clientGroupFormList: [ clientGroupFormList: [
{ {
type: 'daterange', type: 'datePicker',
prop: 'daterange', name: 'daterange',
label: '入群时间', label: '入群时间',
datePickerAttrs: {
'value-format': 'yyyy-MM-dd'
},
pickerOptions: { pickerOptions: {
disabledDate(time) { disabledDate(time) {
return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime() return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime()
...@@ -80,7 +84,7 @@ export default { ...@@ -80,7 +84,7 @@ export default {
{ {
type: 'input', type: 'input',
inputType: 'text', inputType: 'text',
prop: 'groupNickName', name: 'groupNickName',
label: '本群昵称', label: '本群昵称',
placeholder: '请输入本群昵称' placeholder: '请输入本群昵称'
} }
...@@ -117,7 +121,7 @@ export default { ...@@ -117,7 +121,7 @@ export default {
prop: 'joinTime', prop: 'joinTime',
width: 140 width: 140
} }
], ]
// tableOption: { // tableOption: {
// width: 80, // width: 80,
// btnList: [ // btnList: [
...@@ -138,7 +142,7 @@ export default { ...@@ -138,7 +142,7 @@ export default {
} }
}, },
methods: { methods: {
getParams(){ getParams() {
var params = JSON.parse(JSON.stringify(this.searchForm)) var params = JSON.parse(JSON.stringify(this.searchForm))
if (params.daterange) { if (params.daterange) {
params.beginTime = this.searchForm.daterange[0] params.beginTime = this.searchForm.daterange[0]
...@@ -180,7 +184,7 @@ export default { ...@@ -180,7 +184,7 @@ export default {
this.$refs.clientGroupDetail.data.length ? (this.$refs.clientGroupDetail.tableHeightValues = '') : this.$refs.clientGroupDetail.setTableHeightFun() this.$refs.clientGroupDetail.data.length ? (this.$refs.clientGroupDetail.tableHeightValues = '') : this.$refs.clientGroupDetail.setTableHeightFun()
}, },
//导出 //导出
handleExport(){ handleExport() {
var params = this.getParams() var params = this.getParams()
potentialClientExportApi(params).then(res => { potentialClientExportApi(params).then(res => {
this.$Utils.exportFn(res) this.$Utils.exportFn(res)
...@@ -202,9 +206,26 @@ export default { ...@@ -202,9 +206,26 @@ export default {
} }
</script> </script>
<style lang="scss" scope> <style lang="scss" scoped>
.sub-container { .sub-container {
@import '@/styles/variables.scss'; @import '@/styles/variables.scss';
@import '@/styles/resetelement.scss'; @import '@/styles/resetelement.scss';
.leadList {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 8px;
div {
text-align: center;
span:nth-child(1) {
font-weight: 600;
font-size: 16px;
}
}
/deep/ .el-button {
color: #5850ff;
border: 1px solid #5850ff;
}
}
} }
</style> </style>
...@@ -3,16 +3,13 @@ ...@@ -3,16 +3,13 @@
<div class="scrm-sub-client-container"> <div class="scrm-sub-client-container">
<!-- <p class="pageTitle">客户群管理</p> --> <!-- <p class="pageTitle">客户群管理</p> -->
<div class="pageContent"> <div class="pageContent">
<search-form class="searchTop border-shadow" :isHasSyncBtn="true" :showDefaultTime="false" :merchantModel="merchantModel" :accountLevel="accountLevel" :formModel="searchForm" :formList="clientGroupFormList" @setTableHeightEvent="setTableHeightEvent" @resetTable="resetTable" @searchTable="searchTable" @handleExport="handleExport" @syncClick="syncClick"> <GLCombiForm :formObj="searchForm" :formData="clientGroupFormList" @handleOk="searchTable" @handleRest="resetTable"></GLCombiForm>
<span class="inline-b" slot="form-slot"> <div class="leadList">
<el-button plain @click="resetTable">重置</el-button> <div>
<el-button type="primary" @click="searchTable">查询</el-button> <span></span>
<el-button type="primary" @click="handleExport">导出</el-button> </div>
<!-- v-if="(merchantModel == 1 && accountLevel == 1) || (merchantModel == 2 && accountLevel == 4)"允许所有人同步 --> <el-button size="small" @click="handleExport">导出</el-button>
<!-- <el-button type="primary" @click="syncClick" :loading="sloading">同步数据</el-button> --> </div>
</span>
</search-form>
<GLTable @setTableFinishFun="setTableFinishFun" v-if="isReload" ref="clientGroupManage" :hasNum="true" :getListApi="getListApi" :beforeSearchFn="beforeSearchFn" :noDataImg="url" :pageConf="pageConf" :searchForm="searchFormTable" :tableParams="tableParams"> <GLTable @setTableFinishFun="setTableFinishFun" v-if="isReload" ref="clientGroupManage" :hasNum="true" :getListApi="getListApi" :beforeSearchFn="beforeSearchFn" :noDataImg="url" :pageConf="pageConf" :searchForm="searchFormTable" :tableParams="tableParams">
<span slot="status" slot-scope="scope"> <span slot="status" slot-scope="scope">
<!-- <span class="dot" :class="scope.scope.enableStatus ? DICTSTATUS[scope.scope.enableStatus].split(',')[1] : ''"></span> --> <!-- <span class="dot" :class="scope.scope.enableStatus ? DICTSTATUS[scope.scope.enableStatus].split(',')[1] : ''"></span> -->
...@@ -21,7 +18,7 @@ ...@@ -21,7 +18,7 @@
<template slot="auth-button" slot-scope="scope" :data="scope.scope"> <template slot="auth-button" slot-scope="scope" :data="scope.scope">
<!-- <auth-button :data="scope.scope"></auth-button> --> <!-- <auth-button :data="scope.scope"></auth-button> -->
<span @click="goDetail(scope.scope.id, scope.scope.custGroupName)" class="blue-text"> <span @click="goDetail(scope.scope.id, scope.scope.custGroupName)" class="blue-text">
{{scope.scope.delFlag == '0' ? '详情' : scope.scope.delFlag == '-1' ? '' : ''}} {{ scope.scope.delFlag == '0' ? '详情' : scope.scope.delFlag == '-1' ? '' : '' }}
</span> </span>
<!-- <GLButton @click="goDetail(scope.scope.id, scope.scope.custGroupName)" fn="客户群详情" type="text">详情</GLButton> --> <!-- <GLButton @click="goDetail(scope.scope.id, scope.scope.custGroupName)" fn="客户群详情" type="text">详情</GLButton> -->
</template> </template>
...@@ -42,15 +39,16 @@ export default { ...@@ -42,15 +39,16 @@ export default {
isReload: true, isReload: true,
url: url, url: url,
sloading: false, sloading: false,
searchForm: { searchForm: {},
},
searchFormTable: {}, searchFormTable: {},
clientGroupFormList: [ clientGroupFormList: [
{ {
type: 'daterange', type: 'datePicker',
prop: 'daterange', name: 'daterange',
label: '创建时间', label: '创建时间',
datePickerAttrs: {
'value-format': 'yyyy-MM-dd'
},
pickerOptions: { pickerOptions: {
disabledDate(time) { disabledDate(time) {
return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime() return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime()
...@@ -60,30 +58,32 @@ export default { ...@@ -60,30 +58,32 @@ export default {
{ {
type: 'input', type: 'input',
inputType: 'text', inputType: 'text',
prop: 'custGroupName', name: 'custGroupName',
label: '群聊名称', label: '群聊名称',
placeholder: '请输入群聊名称' placeholder: '请输入群聊名称'
}, },
{ {
type: 'input', type: 'input',
inputType: 'text', inputType: 'text',
prop: 'groupHostName', name: 'groupHostName',
label: '群主', label: '群主',
placeholder: '请输入群主' placeholder: '请输入群主'
}, },
{ {
type: 'input', type: 'input',
inputType: 'text', inputType: 'text',
prop: 'groupAdminName', name: 'groupAdminName',
label: '管理员', label: '管理员',
placeholder: '请输入管理员' placeholder: '请输入管理员'
}, },
{ {
type: 'select', type: 'select',
prop: 'creationMethod', name: 'creationMethod',
label: '创建方式', label: '创建方式',
placeholder: '请选择', placeholder: '请选择',
options: [ optionLabel: 'label',
optionId: 'value',
optionList: [
{ {
label: '全部', label: '全部',
value: null value: null
...@@ -100,10 +100,12 @@ export default { ...@@ -100,10 +100,12 @@ export default {
}, },
{ {
type: 'select', type: 'select',
prop: 'delFlag', name: 'delFlag',
label: '群聊状态', label: '群聊状态',
placeholder: '请选择', placeholder: '请选择',
options: [ optionLabel: 'label',
optionId: 'value',
optionList: [
{ {
label: '全部', label: '全部',
value: null value: null
...@@ -176,7 +178,7 @@ export default { ...@@ -176,7 +178,7 @@ export default {
width: 95, width: 95,
formatter: cellValue => { formatter: cellValue => {
return cellValue.delFlag == 0 ? '正常' : cellValue.delFlag == -1 ? '已解散' : '' return cellValue.delFlag == 0 ? '正常' : cellValue.delFlag == -1 ? '已解散' : ''
}, }
}, },
{ {
label: '创建时间', label: '创建时间',
...@@ -307,7 +309,7 @@ export default { ...@@ -307,7 +309,7 @@ export default {
} else { } else {
if (params.beginTime) delete params.beginTime && delete params.endTime if (params.beginTime) delete params.beginTime && delete params.endTime
} }
console.log('params',params) console.log('params', params)
delete params.daterange delete params.daterange
return params return params
}, },
...@@ -363,6 +365,24 @@ export default { ...@@ -363,6 +365,24 @@ export default {
letter-spacing: 1px; letter-spacing: 1px;
} }
.pageContent { .pageContent {
.leadList {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 8px;
div {
text-align: center;
span:nth-child(1) {
font-weight: 600;
font-size: 16px;
}
}
/deep/ .el-button {
color: #5850ff;
border: 1px solid #5850ff;
}
}
.glsx-table { .glsx-table {
/deep/ .el-table__fixed, /deep/ .el-table__fixed,
/deep/ .el-table__fixed-right { /deep/ .el-table__fixed-right {
......
...@@ -3,25 +3,21 @@ ...@@ -3,25 +3,21 @@
<div class="scrm-sub-client-container"> <div class="scrm-sub-client-container">
<!-- <p class="pageTitle">客户管理</p> --> <!-- <p class="pageTitle">客户管理</p> -->
<div class="pageContent"> <div class="pageContent">
<search-form :ploading="sloading" :isHasSyncBtn="true" :showDefaultTime="false" :merchantModel="merchantModel" :accountLevel="accountLevel" class="searchTop border-shadow" :formModel="searchForm" :formList="clientManageFormList" @resetTable="resetTable" @searchTable="searchTable" @handleExport="handleExport" @syncClick="syncClick"> <GLCombiForm :formObj="searchForm" :formData="clientManageFormList" @handleOk="searchTable" @handleRest="resetTable">
<span class="inline-b" slot="form-slot"> </GLCombiForm>
<el-button plain @click="resetTable">重置</el-button> <div class="leadList">
<el-button type="primary" @click="searchTable">查询</el-button> <div>
<el-button type="primary" @click="handleExport">导出</el-button> <span></span>
<!-- v-if="(merchantModel == 1 && accountLevel == 1) || (merchantModel == 2 && accountLevel == 4)" 不做判定了, 允许所有人同步 --> </div>
<!-- <el-button type="primary" @click="syncClick" :loading="sloading">同步数据</el-button> --> <el-button size="small" @click="handleExport">导出</el-button>
</span> </div>
</search-form>
<GLTable @setTableFinishFun="setTableFinishFun" v-if="isReload" ref="clientManage" :hasNum="true" :getListApi="getListApi" :beforeSearchFn="beforeSearchFn" :searchForm="searchFormTable" :noDataImg="url" :pageConf="pageConf" :tableParams="tableParams"> <GLTable @setTableFinishFun="setTableFinishFun" v-if="isReload" ref="clientManage" :hasNum="true" :getListApi="getListApi" :beforeSearchFn="beforeSearchFn" :searchForm="searchFormTable" :noDataImg="url" :pageConf="pageConf" :tableParams="tableParams">
<span slot="customerName" class="flex-center" slot-scope="scope"> <span slot="customerName" class="flex-center" slot-scope="scope">
<el-tooltip effect="dark" :content="scope.scope.customerName" placement="top"> <el-tooltip effect="dark" :content="scope.scope.customerName" placement="top">
<span class="ellipsis-1" style="display: inline-block; max-width: 70px; text-align: left">{{ scope.scope.customerName }}</span> <span class="ellipsis-1" style="display: inline-block; max-width: 70px; text-align: left">{{ scope.scope.customerName }}</span>
</el-tooltip> </el-tooltip>
<!-- <span class="pure-blue-text">{{ scope.scope.type == 1 ? '@微信' : scope.scope.type == 2 ? '@企微' : '' }}</span> --> <!-- <span style="font-size: 12px" class="pure-blue-text">{{scope.scope.type == 1? '@企微':scope.scope.type == 2 ?'@微信' : '' }}</span> -->
<span style="font-size: 12px" class="pure-blue-text">{{ scope.scope.type == 1 ? '@微信' : scope.scope.type == 2 ? '@企微' : scope.scope.type == null ? '' : '' }}</span>
</span> </span>
<span slot="customerSex" slot-scope="scope"> <span slot="customerSex" slot-scope="scope">
<span>{{ scope.scope.customerSex == 0 ? '未知' : scope.scope.customerSex == 1 ? '男' : scope.scope.customerSex == 2 ? '女' : '' }}</span> <span>{{ scope.scope.customerSex == 0 ? '未知' : scope.scope.customerSex == 1 ? '男' : scope.scope.customerSex == 2 ? '女' : '' }}</span>
...@@ -109,45 +105,54 @@ export default { ...@@ -109,45 +105,54 @@ export default {
url: url, url: url,
sloading: false, sloading: false,
CLIENTSTATUS: this.$Constants.CLIENT_STATUS, CLIENTSTATUS: this.$Constants.CLIENT_STATUS,
searchForm: {}, searchForm: {
},
searchFormTable: {}, searchFormTable: {},
clientManageFormList: [ clientManageFormList: [
{ {
type: 'input', type: 'input',
inputType: 'text', inputType: 'text',
prop: 'customerPhone', // prop: 'customerPhone',
name: 'customerPhone',
label: '联系电话', label: '联系电话',
placeholder: '联系电话' placeholder: '联系电话'
}, },
{ {
type: 'select', type: 'select',
name: 'followStaffList', name: 'followStaff',
prop: 'followStaff', // prop: 'followStaff',
noFilter: false, noFilter: false,
optionLabel: 'label',
optionId: 'value',
label: '跟进员工', label: '跟进员工',
placeholder: '请输入跟进员工', placeholder: '请输入跟进员工',
options: [] optionList: []
}, },
{ {
type: 'input', type: 'input',
inputType: 'text', inputType: 'text',
prop: 'customerName', // prop: 'customerName',
name: 'customerName',
label: '客户名称', label: '客户名称',
placeholder: '请输入客户名称' placeholder: '请输入客户名称'
}, },
{ {
type: 'input', type: 'input',
inputType: 'text', inputType: 'text',
prop: 'nickName', // prop: 'nickName',
name: 'nickName',
label: '企微名称', label: '企微名称',
placeholder: '请输入企微名称' placeholder: '请输入企微名称'
}, },
{ {
type: 'select', type: 'select',
prop: 'isJoin', // prop: 'isJoin',
name: 'isJoin',
label: '是否已加企微', label: '是否已加企微',
placeholder: '请选择', placeholder: '请选择',
options: [ optionLabel: 'label',
optionId: 'value',
optionList: [
{ {
label: '全部', label: '全部',
value: null value: null
...@@ -164,28 +169,35 @@ export default { ...@@ -164,28 +169,35 @@ export default {
}, },
{ {
type: 'select', type: 'select',
prop: 'status', // prop: 'status',
name: 'status',
label: '当前状态', label: '当前状态',
placeholder: '请选择当前状态', placeholder: '请选择当前状态',
options: [ optionLabel: 'optionLabel',
optionId: 'optionId',
optionList: [
{ {
label: '全部', optionLabel: '全部',
value: null optionId: null
}, },
{ {
label: '正常', optionLabel: '正常',
value: 0 optionId: 0
}, },
{ {
label: '删除好友', optionLabel: '删除好友',
value: -1 optionId: -1
} }
] ]
}, },
{ {
type: 'daterange', type: 'datePicker',
prop: 'daterange', // prop: 'daterange',
name: 'daterange',
label: '添加时间', label: '添加时间',
datePickerAttrs: {
'value-format': 'yyyy-MM-dd'
},
pickerOptions: { pickerOptions: {
disabledDate(time) { disabledDate(time) {
return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime() return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime()
...@@ -195,39 +207,42 @@ export default { ...@@ -195,39 +207,42 @@ export default {
{ {
type: 'select', type: 'select',
prop: 'addWay', // prop: 'addWay',
name: 'addWaySource', name: 'addWay',
label: '添加来源', label: '添加来源',
optionLabel: 'label',
optionId: 'value',
placeholder: '请选择当前来源', placeholder: '请选择当前来源',
options: [] //this.$Constants.SOURCE_OPTION optionList: [] //this.$Constants.SOURCE_OPTION
}, },
{ {
type: 'select', type: 'select',
prop: 'customerSex', // prop: 'customerSex',
name: 'customerSex',
label: '性别', label: '性别',
optionLabel: 'label',
optionId: 'value',
placeholder: '请选择性别', placeholder: '请选择性别',
options: this.$Constants.GENDER_OPTION optionList: this.$Constants.GENDER_OPTION
} }
], ],
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'count' }, pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'count' },
tableParams: { tableParams: {
listName: 'data', listName: 'data',
// tableOption: true,
tableOption: false, tableOption: false,
tableColumns: [ tableColumns: [
{ {
label: '客户ID', label: '客户ID',
prop: 'oneId', prop: 'oneId',
minWidth: 150 minWidth:180
//align: 'left'
}, },
{ {
label: '客户名称', label: '客户名称',
prop: 'customerName', prop: 'customerName',
addHtml: 'customerName', addHtml: 'customerName',
minWidth: 130 minWidth:100
//align: 'left'
}, },
{ {
label: '企微名称', label: '企微名称',
...@@ -392,7 +407,7 @@ export default { ...@@ -392,7 +407,7 @@ export default {
} }
// addWaySource // addWaySource
const id = this.clientManageFormList.findIndex(item => { const id = this.clientManageFormList.findIndex(item => {
return item.name == 'addWaySource' return item.name == 'addWay'
}) })
let data = res.map(item => { let data = res.map(item => {
return { return {
...@@ -406,7 +421,7 @@ export default { ...@@ -406,7 +421,7 @@ export default {
if (data && data.length > 0) { if (data && data.length > 0) {
window.localStorage.setItem('sourceList', JSON.stringify(data)) window.localStorage.setItem('sourceList', JSON.stringify(data))
} }
this.$set(this.clientManageFormList[id], 'options', data) this.$set(this.clientManageFormList[id], 'optionList', data)
}) })
}, },
getStaffList(val) { getStaffList(val) {
...@@ -418,7 +433,7 @@ export default { ...@@ -418,7 +433,7 @@ export default {
return '' return ''
} }
const id = this.clientManageFormList.findIndex(item => { const id = this.clientManageFormList.findIndex(item => {
return item.name == 'followStaffList' return item.name == 'followStaff'
}) })
const staff = res.map(item => { const staff = res.map(item => {
return { return {
...@@ -429,7 +444,7 @@ export default { ...@@ -429,7 +444,7 @@ export default {
staff.unshift({ label: '全部', value: '' }) staff.unshift({ label: '全部', value: '' })
this.$nextTick(() => { this.$nextTick(() => {
this.clientManageFormList[id].options = staff this.clientManageFormList[id].optionList = staff
}) })
}) })
}, },
...@@ -453,6 +468,8 @@ export default { ...@@ -453,6 +468,8 @@ export default {
}, },
//搜索表格 //搜索表格
searchTable() { searchTable() {
console.log('进来了1111111111111111111111111')
console.log(this.searchForm)
this.$refs.clientManage.refreshTable() this.$refs.clientManage.refreshTable()
}, },
syncClick() { syncClick() {
...@@ -535,6 +552,24 @@ export default { ...@@ -535,6 +552,24 @@ export default {
letter-spacing: 1px; letter-spacing: 1px;
} }
.pageContent { .pageContent {
.leadList {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 8px;
div {
text-align: center;
span:nth-child(1) {
font-weight: 600;
font-size: 16px;
}
}
/deep/ .el-button {
color: #5850ff;
border: 1px solid #5850ff;
}
}
padding: 6px 20px 30px; padding: 6px 20px 30px;
box-shadow: 0 10px 20px 0 rgba(88, 80, 255, 0.1); box-shadow: 0 10px 20px 0 rgba(88, 80, 255, 0.1);
// min-width: 1300px; // min-width: 1300px;
......
...@@ -11,15 +11,13 @@ ...@@ -11,15 +11,13 @@
<img src="@/assets/guestCustom/chat-logo.png" alt /> <img src="@/assets/guestCustom/chat-logo.png" alt />
</div> </div>
<div class="group-name-info"> <div class="group-name-info">
<div>{{groupInfo.groupName}}</div> <div>{{ groupInfo.groupName }}</div>
<div <div class="group-name-info-count">{{ groupInfo.userList ? groupInfo.userList.length : 0 }}人</div>
class="group-name-info-count"
>{{groupInfo.userList ? groupInfo.userList.length : 0}}人</div>
</div> </div>
</div> </div>
<div class="text-info"> <div class="text-info">
已建群数量: 已建群数量:
<span class="group-number">{{groupInfo.groupCount}}</span> <span class="group-number">{{ groupInfo.groupCount }}</span>
</div> </div>
</div> </div>
</div> </div>
...@@ -40,12 +38,7 @@ ...@@ -40,12 +38,7 @@
<el-popover placement="top" width="600" trigger="hover"> <el-popover placement="top" width="600" trigger="hover">
<span slot="reference">...({{ followList.length }})</span> <span slot="reference">...({{ followList.length }})</span>
<div class="entmicro-hover"> <div class="entmicro-hover">
<el-tag <el-tag type="info" v-for="(i, index) in followList" :key="index" :disable-transitions="false">
type="info"
v-for="(i, index) in followList"
:key="index"
:disable-transitions="false"
>
<i class="el-icon-user-solid"></i> <i class="el-icon-user-solid"></i>
{{ i.staffName }}{{ i.departmentName ? `(${i.departmentName})` : '' }} {{ i.staffName }}{{ i.departmentName ? `(${i.departmentName})` : '' }}
</el-tag> </el-tag>
...@@ -67,12 +60,7 @@ ...@@ -67,12 +60,7 @@
<el-popover placement="top" width="600" trigger="hover"> <el-popover placement="top" width="600" trigger="hover">
<span slot="reference">...({{ memberList.length }})</span> <span slot="reference">...({{ memberList.length }})</span>
<div class="entmicro-hover"> <div class="entmicro-hover">
<el-tag <el-tag type="info" v-for="(i, index) in memberList" :key="index" :disable-transitions="false">
type="info"
v-for="(i, index) in memberList"
:key="index"
:disable-transitions="false"
>
<i class="el-icon-user-solid"></i> <i class="el-icon-user-solid"></i>
{{ i.staffName }}{{ i.departmentName ? `(${i.departmentName})` : '' }} {{ i.staffName }}{{ i.departmentName ? `(${i.departmentName})` : '' }}
</el-tag> </el-tag>
...@@ -92,20 +80,9 @@ ...@@ -92,20 +80,9 @@
<i class="el-icon-refresh"></i> <i class="el-icon-refresh"></i>
更新数据 更新数据
</div> </div>
<div class="text-info">更新于:{{currentTime}}</div> <div class="text-info">更新于:{{ currentTime }}</div>
</div> </div>
<GLTable <GLTable class="table" :searchForm="searchForm" ref="groupDetail" :hasNum="false" :getListApi="getListApi" :beforeSearchFn="beforeSearchFn" :noDataImg="url" :pageConf="pageConf" :tableParams="tableParams" :tableData="tableData">
class="table"
:searchForm="searchForm"
ref="groupDetail"
:hasNum="false"
:getListApi="getListApi"
:beforeSearchFn="beforeSearchFn"
:noDataImg="url"
:pageConf="pageConf"
:tableParams="tableParams"
:tableData="tableData"
>
<span slot="customerName" slot-scope="scope"> <span slot="customerName" slot-scope="scope">
<div class=""> <div class="">
<!-- <div class="customer-img"> <!-- <div class="customer-img">
...@@ -113,9 +90,7 @@ ...@@ -113,9 +90,7 @@
</div>--> </div>-->
<div class="customer-name"> <div class="customer-name">
{{ scope.scope.customerName }} {{ scope.scope.customerName }}
<label <label class="origin">{{ WECHANT_TYPE[scope.scope.type] }}</label>
class="origin"
>{{ WECHANT_TYPE[scope.scope.type]}}</label>
</div> </div>
</div> </div>
</span> </span>
...@@ -135,10 +110,7 @@ ...@@ -135,10 +110,7 @@
class="statusText" class="statusText"
v-if="scope.scope.delFlag == '0'" v-if="scope.scope.delFlag == '0'"
>使用</span> --> >使用</span> -->
<span <span class="statusText" :class="{ 'red-text': scope.scope.delFlag == '-1' }">{{ scope.scope.delFlag == '0' ? '使用' : scope.scope.delFlag == '-1' ? '解散于' : '' }}</span>
class="statusText"
:class="{ 'red-text': scope.scope.delFlag == '-1' }"
>{{ scope.scope.delFlag == '0' ? '使用' : scope.scope.delFlag == '-1' ? '解散于' : '' }}</span>
<span v-if="scope.scope.delFlag == '-1'" class="gray-text">{{ scope.scope.disMiss }}</span> <span v-if="scope.scope.delFlag == '-1'" class="gray-text">{{ scope.scope.disMiss }}</span>
</span> </span>
</GLTable> </GLTable>
...@@ -198,32 +170,32 @@ export default { ...@@ -198,32 +170,32 @@ export default {
{ {
label: '客户', label: '客户',
prop: 'customerName', prop: 'customerName',
addHtml: 'customerName', addHtml: 'customerName'
//align: 'left' //align: 'left'
// width: 200 // width: 200
}, },
{ {
label: '创建时间', label: '创建时间',
prop: 'createdTime', prop: 'createdTime'
//align: 'left' //align: 'left'
// width: 200 // width: 200
}, },
{ {
label: '现群名称', label: '现群名称',
prop: 'chatName', prop: 'chatName'
//align: 'left' //align: 'left'
}, },
{ {
label: '现群主', label: '现群主',
prop: 'createdBy', prop: 'createdBy',
// minWidth: '180px', // minWidth: '180px',
addHtml: 'groupOwner', addHtml: 'groupOwner'
//align: 'left' //align: 'left'
}, },
{ {
label: '状态', label: '状态',
prop: 'status', prop: 'status',
addHtml: 'status', addHtml: 'status'
// width: 250, // width: 250,
//align: 'left' //align: 'left'
} }
...@@ -607,7 +579,6 @@ export default { ...@@ -607,7 +579,6 @@ export default {
height: 100%; height: 100%;
} }
} }
} }
} }
.entmicro { .entmicro {
......
...@@ -9,26 +9,13 @@ ...@@ -9,26 +9,13 @@
</div> </div>
<div class="container"> <div class="container">
<search-form <search-form class="searchTop border-shadow" :formModel="searchForm" :formList="searchFormData" labelWidth="70px">
class="searchTop border-shadow"
:formModel="searchForm"
:formList="searchFormData"
labelWidth="70px"
>
<span class="inline-b" style="float: right" slot="form-slot"> <span class="inline-b" style="float: right" slot="form-slot">
<el-button type="primary" @click="searchTable">查询</el-button> <el-button type="primary" @click="searchTable">查询</el-button>
</span> </span>
</search-form> </search-form>
<!-- 表格区域 开始 --> <!-- 表格区域 开始 -->
<GLTable <GLTable ref="gueastGroup" @setTableFinishFun="setTableFinishFun" :noDataImg="url" :getListApi="getListApi" :searchForm="searchForm" :tableParams="tableParams" :pageConf="pageConf">
ref="gueastGroup"
@setTableFinishFun="setTableFinishFun"
:noDataImg="url"
:getListApi="getListApi"
:searchForm="searchForm"
:tableParams="tableParams"
:pageConf="pageConf"
>
<div slot="entmicro-name" class="entmicro" slot-scope="scope"> <div slot="entmicro-name" class="entmicro" slot-scope="scope">
<!-- <span v-for="(i, index) in scope.scope.userList" :key="index"> <!-- <span v-for="(i, index) in scope.scope.userList" :key="index">
{{ i.staffName }}{{ i.departmentName ? `(${i.departmentName})` : '' }} {{ i.staffName }}{{ i.departmentName ? `(${i.departmentName})` : '' }}
...@@ -42,20 +29,10 @@ ...@@ -42,20 +29,10 @@
{{ tag.staffName }}{{ tag.departmentName ? `(${tag.departmentName})` : '' }} {{ tag.staffName }}{{ tag.departmentName ? `(${tag.departmentName})` : '' }}
</el-tag> </el-tag>
<el-tag type="info" v-if="scope.scope.userList.length > 9 && idx == 9"> <el-tag type="info" v-if="scope.scope.userList.length > 9 && idx == 9">
<el-popover <el-popover placement="top" width="600" trigger="hover" content="这是一段内容,这是一段内容,这是一段内容,这是一段内容。">
placement="top"
width="600"
trigger="hover"
content="这是一段内容,这是一段内容,这是一段内容,这是一段内容。"
>
<span slot="reference">...({{ scope.scope.userList.length }})</span> <span slot="reference">...({{ scope.scope.userList.length }})</span>
<div class="entmicro-hover"> <div class="entmicro-hover">
<el-tag <el-tag type="info" v-for="(i, index) in scope.scope.userList" :key="index" :disable-transitions="false">
type="info"
v-for="(i, index) in scope.scope.userList"
:key="index"
:disable-transitions="false"
>
<i class="el-icon-user-solid"></i> <i class="el-icon-user-solid"></i>
{{ i.staffName }}{{ i.departmentName ? `(${i.departmentName})` : '' }} {{ i.staffName }}{{ i.departmentName ? `(${i.departmentName})` : '' }}
</el-tag> </el-tag>
...@@ -65,20 +42,13 @@ ...@@ -65,20 +42,13 @@
</div> </div>
</div> </div>
<span slot="status" slot-scope="scope"> <span slot="status" slot-scope="scope">
<span <span class="statusText" :class="{ 'red-text': scope.scope.status === '2', 'green-text': scope.scope.status === '1' }">{{ scope.scope.status == '1' ? '启用' : '停用' }}</span>
class="statusText"
:class="{ 'red-text': scope.scope.status === '2', 'green-text': scope.scope.status === '1' }"
>{{ scope.scope.status == '1' ? '启用' : '停用' }}</span>
</span> </span>
<div class="table-btns" slot="optionBtns" slot-scope="scope"> <div class="table-btns" slot="optionBtns" slot-scope="scope">
<!-- <el-button type="text" @click="btnClick('edit', scope.scope)">修改</el-button> <!-- <el-button type="text" @click="btnClick('edit', scope.scope)">修改</el-button>
<el-button type="text" @click="btnClick('detail', scope.scope)">查看详情</el-button>--> <el-button type="text" @click="btnClick('detail', scope.scope)">查看详情</el-button>-->
<GLButton type="text" @click="btnClick('edit', scope.scope)" fn="修改群组">修改</GLButton> <GLButton type="text" @click="btnClick('edit', scope.scope)" fn="修改群组">修改</GLButton>
<GLButton <GLButton type="text" @click="btnClick('status', scope.scope)" fn="启用禁用">{{ scope.scope.status == 1 ? '停用' : '启用' }}</GLButton>
type="text"
@click="btnClick('status', scope.scope)"
fn="启用禁用"
>{{ scope.scope.status == 1 ? '停用' : '启用' }}</GLButton>
<GLButton type="text" @click="btnClick('detail', scope.scope)" fn="客户群详情">查看详情</GLButton> <GLButton type="text" @click="btnClick('detail', scope.scope)" fn="客户群详情">查看详情</GLButton>
<!-- <el-button <!-- <el-button
type="text" type="text"
...@@ -343,6 +313,34 @@ export default { ...@@ -343,6 +313,34 @@ export default {
<style lang="scss" scoped> <style lang="scss" scoped>
@import '@/styles/variables.scss'; @import '@/styles/variables.scss';
@import '@/styles/resetelement.scss'; @import '@/styles/resetelement.scss';
.searchTop {
/deep/ .el-form-item:nth-child(2) {
position: static !important;
.el-form-item__content {
margin-left: 15px !important;
}
}
}
/deep/.search-form {
.itemWidth {
display: flex;
.el-form-item {
display: flex;
}
}
.el-form-item__content {
width: auto;
display: inline-block;
margin-left: 0px !important;
.el-input {
width: 415px;
.el-input__inner {
width: 415px;
}
}
}
}
.btn-header { .btn-header {
margin-bottom: 20px; margin-bottom: 20px;
} }
...@@ -417,8 +415,5 @@ export default { ...@@ -417,8 +415,5 @@ export default {
.search-form .el-form-item:last-child { .search-form .el-form-item:last-child {
float: right; float: right;
} }
.search-form .el-form-item__content {
width: 215px;
}
} }
</style> </style>
<template>
<div>
<div class="scrm-sub-client-container">
<div class="pageContent">
<GLCombiForm :formObj="searchForm" :formData="leadManageFormList" @handleOk="searchTable" @handleRest="resetTable"></GLCombiForm>
<!-- 线索分配 -->
<div class="leadList">
<div>
<span>线索列表</span>
<span @click="handleToggle()">功能介绍</span>
</div>
<el-button size="small" @click="goAllocation">线索分配</el-button>
</div>
<GLTable :hasNum="true" @setTableFinishFun="setTableFinishFun" ref="leadManage" :getListApi="getListApi" :searchForm="searchForm" :pageConf="pageConf" :noDataImg="url" :tableParams="tableParams" :headerStyle="{ height: '54px', background: '#F4F6FC', color: '#333333', fontSize: '14px' }">
<!-- 线索类型 -->
<template slot="type" slot-scope="scope">
<span>{{ switchStaff(scope.scope.type) }}</span>
</template>
<!-- 线索状态 -->
<template slot="status" slot-scope="scope">
<span>
{{ scope.scope.status == 1 ? '跟进中' : scope.scope.customerSex == 2 ? '已完成' : '' }}
</span>
</template>
<!-- 跟进员工 -->
<template slot="userName" slot-scope="scope">
<el-tag type="info" :disable-transitions="false" v-if="scope.scope.userName !== null">
<i class="el-icon-user-solid"></i>
{{ scope.scope.userName }}
</el-tag>
</template>
<template slot="options" slot-scope="scope">
<!-- <GLButton class="blue-text leftDistance" type="text" fn="查看" @click="goBasicInfo">查看</GLButton> -->
<el-button type="primary" size="small" @click="goBasicInfo(scope.scope)">查看</el-button>
</template>
</GLTable>
</div>
</div>
<!-- 功能介绍 -->
<el-dialog title="功能介绍" :visible.sync="showFuncIntro" width="55%" :before-close="handleClose">
<div class="dialogEncircle ">
<span class="funcText">线索管理模块可查看客户在小程序端留存的售前售后线索,通过配置跟进员工,使线索展示在员工企微任务栏并推送消息提醒,员工跟进线索并输入跟进记录后完成线索跟进</span>
<div class="funcIro">
<div>
<div>
<img src="@/assets/leadManage/newInquiry.png" alt="" />
</div>
<p>客户在小程序留存售前售后线索</p>
</div>
<div>
<div>
<img src="@/assets/leadManage/group.png" alt="" />
</div>
<p>SCRM后台配置线索跟进员工</p>
</div>
<div>
<div>
<img src="@/assets/leadManage/myTodo.png" alt="" />
</div>
<p>线索展示在员工企微任务栏并推送消息提醒</p>
</div>
<div>
<div>
<img src="@/assets/leadManage/addRecord.png" alt="" />
</div>
<p>员工跟进线索并输入跟进记录</p>
</div>
</div>
</div>
<span slot="footer" class="dialog-footer">
<el-button type="primary" size="small" @click="showFuncIntro = false">关闭</el-button>
</span>
</el-dialog>
</div>
</template>
<script>
import { getTableList } from '@/api/modules/leadManage'
import url from '@/assets/clientDataOverview/nodata.png'
export default {
name: 'leadManage',
data() {
return {
url: url,
searchForm: {},
leadManageFormList: [
{
type: 'input',
inputType: 'text',
name: 'keyword',
label: '关键字'
},
{
type: 'select',
name: 'status',
label: '线索状态',
optionLabel: 'label',
optionId: 'value',
optionList: [
{
label: '全部',
value: null
},
{
label: '跟进中',
value: 1
},
{
label: '已完成',
value: 2
}
]
},
{
type: 'input',
inputType: 'text',
name: 'userName',
label: '跟进人'
},
{
type: 'select',
name: 'type',
label: '线索类型',
optionLabel: 'label',
optionId: 'value',
optionList: [
{
label: '全部',
value: null
},
// {
// label: '客户意见',
// value: 1
// },
// {
// label: '卖车询价',
// value: 2
// },
{
label: '救援服务',
value: 3
},
{
label: '新车询价',
value: 4
},
{
label: '试驾预约',
value: 5
},
{
label: '维保预约',
value: 6
}
]
}
],
getListApi: getTableList,
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'count' },
tableParams: {
listName: 'list',
tableColumns: [
{
label: '单号',
prop: 'orderNo',
minWidth: 90
},
{
label: '客户名称',
prop: 'name'
},
{
label: '手机号',
prop: 'phone'
},
{
label: '线索类型',
prop: 'type',
addHtml: 'type'
},
{
label: '线索状态',
prop: 'status',
addHtml: 'status'
},
{
label: '跟进人',
prop: 'userName',
addHtml: 'userName'
},
{
label: '创建时间',
prop: 'createdDate',
minWidth: 100
},
{
label: '操作',
prop: 'options',
fixed: 'right',
addHtml: 'options',
width: 180
}
]
},
showFuncIntro: true //功能介绍的显示与隐藏
}
},
created() {
if (window.__POWERED_BY_QIANKUN__) {
//运行在qiankun容器中
this.merchantModel = this.$globalState.session.merchantModel
this.accountLevel = this.$globalState.session.accountLevel
}
},
methods: {
goAllocation() {
this.$router.push('./leadAllocation')
},
goBasicInfo(row) {
let id = row.id
let type = row.type
this.$router.push({
path: `/leadManage/leadBasicInfo/${id}/${type}`
})
},
handleToggle() {
this.showFuncIntro = !this.showFuncIntro
},
// 搜索表格
searchTable() {
console.log(this.searchForm)
this.$refs.leadManage.refreshTable()
},
//重置表格
resetTable() {
this.searchForm = {}
this.$refs.leadManage.refreshTable()
},
// 跟进转换
switchStaff(num) {
switch (num) {
case '3':
return '救援服务'
case '4':
return '新车询价'
case '5':
return '试驾预约'
case '6':
return '维保预约'
default:
break
}
}
}
}
</script>
<style lang="scss" scoped>
.scrm-sub-client-container {
.pageContent {
padding: 6px 20px 30px;
box-shadow: 0 10px 20px 0 rgba(88, 80, 255, 0.1);
// min-width: 1300px;
background-color: #fff;
/deep/ .el-icon-user-solid {
color: #75acff;
margin-right: 3px;
font-size: 14px;
}
.leadList {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 8px;
div {
text-align: center;
span:nth-child(1) {
font-weight: 600;
font-size: 16px;
}
span:nth-child(2) {
font-size: 14px;
margin-left: 8px;
color: #5850ff;
border-bottom: 1px solid #5850ff;
cursor: pointer;
}
}
/deep/ .el-button {
color: #5850ff;
border: 1px solid #5850ff;
}
}
}
}
/deep/.el-dialog__body {
padding: 30px 70px;
.dialogEncircle {
// width: 100%;
.funcText {
color: #333;
font-weight: 600;
font-size: 14px;
}
.funcIro {
margin-top: 15px;
display: flex;
justify-content: space-between;
> div {
width: 23%;
div {
height: calc(100% - 65px);
display: flex;
align-items: center;
img {
width: 100%;
}
}
p {
margin-left: 5px;
margin-top: 22px;
color: #333;
font-size: 14px;
}
}
}
}
}
</style>
<template>
<div>
<div class="scrm-sub-client-container">
<div class="pageContent" :style="{ height: clientHeight + 'px' }">
<div class="drainage-form-item" v-for="(item, index) in followStaffList" :key="index">
<label>
售前线索跟进员工
<el-popover placement="top" width="400" trigger="hover" content="请在首页-跟进专员模块里创建售前专员,并选择员工来跟进新车询价、试驾预约线索。">
<img src="@/assets/leadManage/question.png" slot="reference" class="count-item-question" />
</el-popover>
:
</label>
<div style="position: relative">
<el-button size="small" @click="handleAddEmp">
<i class="el-icon-plus"></i>
选择跟进专员
</el-button>
<span class="drainage-coutom-count">
只能选择
<span class="count">1</span>
个
</span>
<div class="el-input-tag input-tag-wrapper" v-if="dracImFollowStaffResponses.length == 1">
<el-tag effect="plain" type="info" v-for="(tag, idx) in dracImFollowStaffResponses" :key="idx" :disable-transitions="false">
<i class="el-icon-user-solid"></i>
{{ tag.staffName }}
</el-tag>
</div>
</div>
</div>
</div>
</div>
<select-emp ref="selectEmpForm" @selectTable="selectTable"></select-emp>
<GLFooter class="gl-footer">
<el-button @click="goback()">取消</el-button>
<el-button type="primary" @click="comEmployee()">确定</el-button>
</GLFooter>
</div>
</template>
<script>
import selectEmp from '@/components/selectEmp'
export default {
name: 'leadAllocation',
components: { selectEmp },
data() {
return {
followStaffList: ['1', '2'],
followStaffVal: '',
clientHeight: '',
dracImFollowStaffResponses: [
{
staffName: 'nihao',
id: 212
}
]
}
},
mounted() {
this.clientHeight = document.documentElement.clientHeight - 180
},
methods: {
// 删除标签
handleTagClose(tag) {
// console.log(tag)
this.allocationList.splice(this.allocationList.indexOf(tag), 1)
},
goback() {
this.$router.push({ path: '/leadManage/index' })
},
comEmployee() {
console.log('1111')
},
//选择跟进员工
handleAddEmp() {
this.$refs.selectEmpForm.init(this.dracImFollowStaffResponses)
},
selectTable(item) {
this.dracImFollowStaffResponses = item.map(item => {
return {
staffId: item.relationId,
staffName: item.staffName
}
})
}
}
}
</script>
<style lang="scss" scoped>
.scrm-sub-client-container {
.pageContent {
padding: 6px 20px 30px;
box-shadow: 0 10px 20px 0 rgba(88, 80, 255, 0.1);
// min-width: 1300px;
background-color: #fff;
.drainage-form-item {
display: flex;
margin-top: 20px;
/deep/ {
.el-input__inner {
width: 448px;
}
}
label {
color: #333;
text-align: right;
margin-right: 10px;
height: 36px;
line-height: 36px;
font-size: 14px;
img {
width: 16px;
height: 16px;
vertical-align: middle;
// margin-left: 5px;
}
}
.input-tag-wrapper {
position: relative;
font-size: 14px;
background-color: #fff;
background-image: none;
border-radius: 4px;
border: 1px solid #dcdfe6;
box-sizing: border-box;
color: #666;
display: inline-block;
outline: none;
padding: 5px 5px 0px 5px;
max-height: 68px;
overflow: auto;
flex-wrap: wrap;
transition: border-color 0.2s cubic-bezier(0.645, 0.045, 0.355, 1);
width: 567px;
display: flex;
// align-items: center;
margin-top: 6px;
font-size: 14px;
height: 46px;
i {
color: #75acff;
margin-right: 3px;
font-size: 14px;
}
}
.drainage-coutom-count {
color: #999;
font-size: 14px;
.count {
color: #5850ff;
}
}
/deep/ .el-button--small {
height: 36px;
}
}
}
}
</style>
<template>
<div>
<div class="scrm-sub-client-container">
<div class="pageContent" :style="{ 'min-height': clientHeight + 'px' }">
<!-- 基本信息 -->
<div class="baseTitle">
<p class="title">基本信息</p>
<hr />
<!-- 救援服务 -->
<yl-descriptions v-if="leadType == 3" ref="ylDeacriptions" :tableModel="rescueDescriModel" :showData="leadBaseList" />
<!-- 新车询价 -->
<yl-descriptions v-if="leadType == 4" ref="ylDeacriptions" :tableModel="newcarDescriModel" :showData="leadBaseList" />
<!-- 试驾预约和维保预约 -->
<yl-descriptions v-if="leadType == 5 || leadType == 6" ref="ylDeacriptions" :tableModel="orderDescriModel" :showData="leadBaseList" />
</div>
<!-- 跟进记录 -->
<div class="baseTitle">
<p class="title">跟进记录</p>
<hr />
<div class="timestamp">
<el-timeline>
<el-timeline-item v-for="(item, index) in leadFollowRecord" :key="index" :timestamp="item.followDate" placement="top" :color="index === 0 ? '#5850FF' : ''">
<p class="conductor">处理人:{{ item.userName }}</p>
<p class="remark">{{ item.remark }}</p>
</el-timeline-item>
</el-timeline>
</div>
</div>
</div>
</div>
<GLFooter class="gl-footer">
<el-button @click="goback()" type="primary" size="small">返回</el-button>
</GLFooter>
</div>
</template>
<script>
import { getBaseInfo } from '@/api/modules/leadManage'
import ylDescriptions from '@/components/ylDescriptions'
export default {
name: 'leadBasicInfo',
components: { ylDescriptions },
data() {
return {
followRecord: [],
clientHeight: '',
leadId: '', //线索id
leadType: '', //线索类型
leadBaseList: {}, //线索详情基本信息
leadFollowRecord: [], //线索详情跟进记录
theSameDescri: [
{
colList: [
{ thColspan: 1, tdColspan: 2, label: '客户名称', name: 'name' },
{ thColspan: 1, tdColspan: 2, label: '客户手机号', name: 'phone' }
]
},
{
colList: [
{ thColspan: 1, tdColspan: 2, label: '单号', name: 'orderNo' },
{ thColspan: 1, tdColspan: 2, label: '线索类型', name: 'type' }
]
},
{
colList: [
{ thColspan: 1, tdColspan: 2, label: '线索状态', name: 'status', color: '#5850FF' },
{ thColspan: 1, tdColspan: 2, label: '创建时间', name: 'createdDate' }
]
},
{
colList: [{ thColspan: 1, tdColspan: 5, label: '跟进时长', name: 'followTime' }]
}
],
// 救援服务
rescueDescri: [
{
colList: [{ thColspan: 1, tdColspan: 5, label: '救援内容', name: 'rescueType' }]
},
{
colList: [{ thColspan: 1, tdColspan: 5, label: '救援地点', name: 'rescueAddress' }]
},
{
colList: [{ thColspan: 1, tdColspan: 5, label: '门店', name: 'merchantName' }]
}
],
// 新车询价
newcarDescri: [
{
colList: [{ thColspan: 1, tdColspan: 5, label: '车型', name: 'vehicleShapeName' }]
},
{
colList: [{ thColspan: 1, tdColspan: 5, label: '询价描述', name: 'comment' }]
},
{
colList: [{ thColspan: 1, tdColspan: 5, label: '门店', name: 'merchantName' }]
}
],
// 维保预约
orderDescri: [
{
colList: [
{ thColspan: 1, tdColspan: 2, label: '车牌号', name: 'plateNum' },
{ thColspan: 1, tdColspan: 2, label: '里程数', name: 'mileage' }
]
},
{
colList: [{ thColspan: 1, tdColspan: 5, label: '门店', name: 'merchantName' }]
}
]
}
},
created() {
this.leadId = this.$route.params.id ? this.$route.params.id : ''
this.leadType = this.$route.params.type ? this.$route.params.type : ''
this.getBaseDetail()
},
mounted() {
this.clientHeight = document.documentElement.clientHeight - 140
},
computed: {
// 救援服务
rescueDescriModel() {
return this.theSameDescri.concat(this.rescueDescri)
},
// 新车询价
newcarDescriModel() {
return this.theSameDescri.concat(this.newcarDescri)
},
// 维保预约
orderDescriModel() {
return this.theSameDescri.concat(this.orderDescri)
}
},
methods: {
goback() {
this.$router.push('/leadManage/index')
},
getBaseDetail() {
let params = { id: this.leadId }
getBaseInfo(params).then(res => {
let dataObj = res
// 转换线索类型
if (dataObj['type']) {
switch (dataObj['type']) {
case '3':
dataObj['type'] = '救援服务'
break
case '4':
dataObj['type'] = '新车询价'
break
case '5':
dataObj['type'] = '试驾预约'
break
case '6':
dataObj['type'] = '维保预约'
}
}
// 转换线索状态
if (dataObj['status']) {
switch (dataObj['status']) {
case '0':
dataObj['status'] = '待跟进'
break
case '1':
dataObj['status'] = '跟进中'
break
case '2':
dataObj['status'] = '已完成'
}
}
// 转换救援内容
if (dataObj['rescueType']) {
switch (dataObj['rescueType']) {
case '0':
dataObj['rescueType'] = '紧急脱困'
break
case '1':
dataObj['rescueType'] = '拖车'
break
case '2':
dataObj['rescueType'] = '换胎'
break
case '3':
dataObj['rescueType'] = '送油'
break
case '4':
dataObj['rescueType'] = '搭电'
break
case '5':
dataObj['rescueType'] = '事故救援'
}
}
this.leadBaseList = dataObj
this.leadFollowRecord = res.followList
console.log(res)
})
}
}
}
</script>
<style lang="scss" scoped>
.scrm-sub-client-container {
.pageContent {
// padding: 6px 0px 30px;
box-shadow: 0 10px 20px 0 rgba(88, 80, 255, 0.1);
// min-width: 1300px;
background-color: #fff;
margin-bottom: 75px;
.leadAllocation {
width: 700px;
display: flex;
justify-content: space-between;
}
.baseTitle {
.title {
padding: 15px 30px 0px 20px;
font-size: 16px;
color: #333333;
font-weight: 600;
}
.timestamp {
margin: 25px 20px 30px 44px;
/deep/ .el-timeline-item__timestamp.is-top {
margin-bottom: 3px !important;
}
/deep/ .el-timeline-item__timestamp {
color: #1d2129;
font-size: 14px;
}
/deep/ .el-timeline-item {
padding-bottom: 30px;
}
/deep/ .el-timeline-item__content {
p {
padding: 4px 0;
}
.conductor {
font-size: 14px;
}
.remark {
font-size: 12px;
color: #999999;
}
}
}
}
}
}
</style>
...@@ -30,14 +30,13 @@ ...@@ -30,14 +30,13 @@
</div> </div>
<div class="pageContent"> <div class="pageContent">
<!-- @setTableHeightEvent="setTableHeightEvent" --> <!-- <search-form class="searchTop border-shadow" :formModel="searchForm" :formList="tagsPartFormList" @setTableHeightEvent="setTableHeightEvent" labelWidth="54px">
<search-form class="searchTop border-shadow" :formModel="searchForm" :formList="tagsPartFormList" @setTableHeightEvent="setTableHeightEvent" labelWidth="54px">
<span class="inline-b" slot="form-slot"> <span class="inline-b" slot="form-slot">
<el-button @click="resetTable" plain>重置</el-button> <el-button @click="resetTable" plain>重置</el-button>
<!-- :id="tableParams.btnId" -->
<el-button type="primary" @click="searchTable">查询</el-button> <el-button type="primary" @click="searchTable">查询</el-button>
</span> </span>
</search-form> </search-form> -->
<GLCombiForm :formObj="searchForm" :formData="tagsPartFormList" @handleOk="searchTable" @handleRest="resetTable"></GLCombiForm>
<!-- noDataText="你当前还没有添加的标签" --> <!-- noDataText="你当前还没有添加的标签" -->
<GLTable @setTableFinishFun="setTableFinishFun" v-if="isReload" ref="tagsManage" :hasNum="false" :getListApi="getListApi" :searchForm="searchForm" :pageConf="pageConf" :noDataImg="url" :tableParams="tableParams" :headerStyle="{ height: '54px', background: '#F4F6FC', color: '#333333', fontSize: '14px' }"> <GLTable @setTableFinishFun="setTableFinishFun" v-if="isReload" ref="tagsManage" :hasNum="false" :getListApi="getListApi" :searchForm="searchForm" :pageConf="pageConf" :noDataImg="url" :tableParams="tableParams" :headerStyle="{ height: '54px', background: '#F4F6FC', color: '#333333', fontSize: '14px' }">
<span slot="labelGroup" slot-scope="scope"> <span slot="labelGroup" slot-scope="scope">
...@@ -67,8 +66,8 @@ ...@@ -67,8 +66,8 @@
<template slot="xxx" slot-scope="scope"> <template slot="xxx" slot-scope="scope">
<!-- //这版关掉自店标签 1.0.1允许集团的门店打字店标签,也可以编辑--> <!-- //这版关掉自店标签 1.0.1允许集团的门店打字店标签,也可以编辑-->
<!-- v-if="scope.scope.labelType != '系统标签' && isShowEditBtn(scope.scope)" --> <!-- v-if="scope.scope.labelType != '系统标签' && isShowEditBtn(scope.scope)" -->
<span @click="btnClick('edit', scope.scope)" v-if="scope.scope.labelType != '系统标签' && isShowEditBtn(scope.scope)" class="blue-text" >编辑标签组</span> <span @click="btnClick('edit', scope.scope)" v-if="scope.scope.labelType != '系统标签' && isShowEditBtn(scope.scope)" class="blue-text">编辑标签组</span>
<GLButton class="blue-text leftDistance" type="text" fn="查看客户" v-if="userType!==2" @click="toViewCustomer(scope.scope)" >查看客户</GLButton> <GLButton class="blue-text leftDistance" type="text" fn="查看客户" v-if="userType !== 2" @click="toViewCustomer(scope.scope)">查看客户</GLButton>
</template> </template>
</GLTable> </GLTable>
</div> </div>
...@@ -197,15 +196,17 @@ export default { ...@@ -197,15 +196,17 @@ export default {
tagsPartFormList: [ tagsPartFormList: [
{ {
type: 'select', type: 'select',
prop: 'labelTreeReq.labelTypesStr', name: 'labelTreeReq.labelTypesStr',
label: '标签组', label: '标签组',
optionLabel: 'label',
optionId: 'value',
placeholder: '请选择标签组类型', placeholder: '请选择标签组类型',
options: this.$Constants.LABEL_OPTION optionList: this.$Constants.LABEL_OPTION
}, },
{ {
type: 'input', type: 'input',
inputType: 'text', inputType: 'text',
prop: 'labelTreeReq.labelGroupName', name: 'labelTreeReq.labelGroupName',
label: '搜索', label: '搜索',
placeholder: '请输入标签组或标签名称', placeholder: '请输入标签组或标签名称',
clearable: true clearable: true
...@@ -220,7 +221,7 @@ export default { ...@@ -220,7 +221,7 @@ export default {
label: '标签组', label: '标签组',
prop: 'labelGroup', prop: 'labelGroup',
addHtml: 'labelGroup', addHtml: 'labelGroup',
width: 230, width: 230
}, },
{ {
label: '标签组类型', label: '标签组类型',
...@@ -263,7 +264,7 @@ export default { ...@@ -263,7 +264,7 @@ export default {
// maxlength: 30, // maxlength: 30,
// showWordLimit: true, // showWordLimit: true,
disabled: false, disabled: false,
clickFunc:this.watchInput clickFunc: this.watchInput
}, },
{ {
label: '标签组类型', label: '标签组类型',
...@@ -282,7 +283,7 @@ export default { ...@@ -282,7 +283,7 @@ export default {
], ],
tagRules: { tagRules: {
tagsName: [ tagsName: [
{ required: true, message: '请输入名称', trigger: 'blur' }, { required: true, message: '请输入名称', trigger: 'blur' }
// { // {
// validator: checkName, // validator: checkName,
// trigger: 'change' // trigger: 'change'
...@@ -366,10 +367,10 @@ export default { ...@@ -366,10 +367,10 @@ export default {
const type = info.labelType const type = info.labelType
this.$router.push({ this.$router.push({
// path:`/tagsManage/viewCustomers/530` // path:`/tagsManage/viewCustomers/530`
path:`/tagsManage/viewCustomers/${id}/${type}` path: `/tagsManage/viewCustomers/${id}/${type}`
}) })
}, },
watchInput(){ watchInput() {
console.log('点击标签组名称输入框') console.log('点击标签组名称输入框')
}, },
showTagArray(list) { showTagArray(list) {
...@@ -387,7 +388,6 @@ export default { ...@@ -387,7 +388,6 @@ export default {
return e return e
} }
return this.$Utils.cutMaxCharStr(e) return this.$Utils.cutMaxCharStr(e)
}, },
isShowEditBtn(row) { isShowEditBtn(row) {
//集团模式下,只有集团能可以编辑企业,自店,其他只能编辑自店 //集团模式下,只有集团能可以编辑企业,自店,其他只能编辑自店
...@@ -718,7 +718,7 @@ export default { ...@@ -718,7 +718,7 @@ export default {
<style lang="scss" scoped> <style lang="scss" scoped>
@import '@/styles/variables.scss'; @import '@/styles/variables.scss';
@import '@/styles/resetelement.scss'; @import '@/styles/resetelement.scss';
.leftDistance{ .leftDistance {
margin-left: 10px; margin-left: 10px;
} }
.scrm-sub-client-container { .scrm-sub-client-container {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!