Commit 9f1213b5 by yangming

new

1 parent c88f6ee5
...@@ -132,7 +132,7 @@ const customerViewExport = params => { ...@@ -132,7 +132,7 @@ const customerViewExport = params => {
//当日新增群客户数 //当日新增群客户数
const customerCustPage = params => { const customerCustPage = params => {
params.method = 'entmicro.api.customer.base.cust.page' params.method = 'entmicro.api.customer.base.page'
return http({ return http({
url: '/rop-scrm-entmicro/router', url: '/rop-scrm-entmicro/router',
method: 'POST', method: 'POST',
...@@ -150,6 +150,46 @@ const customerBaseCustListExport = params => { ...@@ -150,6 +150,46 @@ const customerBaseCustListExport = params => {
sign: true sign: true
}) })
} }
//获取权益营销概览页权益提单统计数据
const equityOrderStatistical = params => {
params.method = 'scrm.api.equity.service.order.statistical.marketing.effect'
return http({
url: '/rop-scrm-equity/router',
method: 'POST',
data: params,
sign: true
})
}
//获取权益营销概览页营销效果统计数据
const equityStatistical = params => {
params.method = 'scrm.api.equity.statistical.marketing.effect'
return http({
url: '/rop-scrm-equity/router',
method: 'POST',
data: params,
sign: true
})
}
//获取权益列表
const equityInfo = params => {
params.method = 'scrm.api.equity.package.info.list.with.page'
return http({
url: '/rop-scrm-equity/router',
method: 'POST',
data: params,
sign: true
})
}
//导出权益列表
const equityExport = params => {
params.method = 'scrm.api.equity.merchant.order.market.effect.export'
return http({
url: '/rop-scrm-equity/router',
method: 'POST',
data: params,
sign: true
})
}
export default { export default {
getChart, getChart,
...@@ -165,5 +205,9 @@ export default { ...@@ -165,5 +205,9 @@ export default {
merchantRank, merchantRank,
customerViewExport, customerViewExport,
customerCustPage, customerCustPage,
customerBaseCustListExport customerBaseCustListExport,
equityOrderStatistical,
equityStatistical,
equityExport,
equityInfo
} }
\ No newline at end of file \ No newline at end of file
...@@ -21,7 +21,7 @@ export async function bootstrap({ name, id, history, common, messenger, globalSt ...@@ -21,7 +21,7 @@ export async function bootstrap({ name, id, history, common, messenger, globalSt
Vue.prototype.$messenger = messenger Vue.prototype.$messenger = messenger
Vue.prototype.$globalState = globalState Vue.prototype.$globalState = globalState
Vue.prototype.$common = common Vue.prototype.$common = common
Vue.prototype.$http = new common.Http({ response, request, sign, secret, alert: ElementUI.Message.error, headers: { token: 'mini-c83c7ddf-e786-4a79-bf30-19fa091229e7-rop' } }) Vue.prototype.$http = new common.Http({ response, request, sign, secret, alert: ElementUI.Message.error, headers: { token: 'mini-617412ec-bb97-45a9-98d2-cc985017c4e3-rop' } })
// Vue.prototype.$setGlobalState = globalState.actions.setGlobalState // Vue.prototype.$setGlobalState = globalState.actions.setGlobalState
const routesData = common.utils.deepClone(globalState.routers) const routesData = common.utils.deepClone(globalState.routers)
routes = getRoutes(routesData) routes = getRoutes(routesData)
......
...@@ -17,41 +17,41 @@ const render = (base, routes) => { ...@@ -17,41 +17,41 @@ const render = (base, routes) => {
routes, routes,
mode: 'history' mode: 'history'
}) })
router.beforeEach((to, from, next) => { // router.beforeEach((to, from, next) => {
let modelStatus = false; // let modelStatus = false;
let menuStatus = false; // let menuStatus = false;
const menu = JSON.parse(sessionStorage['SCRM_BASE_MENULIST']) // const menu = JSON.parse(sessionStorage['SCRM_BASE_MENULIST'])
menu.forEach(item => { // menu.forEach(item => {
if (!item.children) { // if (!item.children) {
return // return
} // }
item.children.forEach(itm => { // item.children.forEach(itm => {
if (itm.path == '/enterpriseWechat/index') { // if (itm.path == '/enterpriseWechat/index') {
menuStatus = true; // menuStatus = true;
} // }
}) // })
}) // })
if (menuStatus && Vue.prototype.$globalState.session.merchantModel == 1 && Vue.prototype.$globalState.session.accountLevel == 1) { // if (menuStatus && Vue.prototype.$globalState.session.merchantModel == 1 && Vue.prototype.$globalState.session.accountLevel == 1) {
modelStatus = true; // modelStatus = true;
} // }
if (menuStatus && Vue.prototype.$globalState.session.merchantModel == 2 && Vue.prototype.$globalState.session.accountLevel == 4) { // if (menuStatus && Vue.prototype.$globalState.session.merchantModel == 2 && Vue.prototype.$globalState.session.accountLevel == 4) {
modelStatus = true; // modelStatus = true;
} // }
if (!sessionStorage.getItem('wxStatus') && (to.path == '/home/index' || to.path == '/ehome/index') && modelStatus) { // if (!sessionStorage.getItem('wxStatus') && (to.path == '/home/index' || to.path == '/ehome/index') && modelStatus) {
Vue.prototype.$apis.ww.getStatus({}).then((res) => { // Vue.prototype.$apis.ww.getStatus({}).then((res) => {
if (res.status != 'SUCCESS') { // if (res.status != 'SUCCESS') {
Vue.prototype.$history.push('/settings/enterpriseWechat/index') // Vue.prototype.$history.push('/settings/enterpriseWechat/index')
sessionStorage.setItem('wxStatus', 1) // sessionStorage.setItem('wxStatus', 1)
} else { // } else {
sessionStorage.setItem('wxAcess', 1) // sessionStorage.setItem('wxAcess', 1)
next() // next()
} // }
}) // })
} else { // } else {
next(); // next();
} // }
}) // })
const vm = new Vue({ const vm = new Vue({
router, router,
store, store,
......
...@@ -18,6 +18,18 @@ util.getBeforeDate = function (sign = '-') { ...@@ -18,6 +18,18 @@ util.getBeforeDate = function (sign = '-') {
var s = day.getFullYear() + sign + month + sign + date; var s = day.getFullYear() + sign + month + sign + date;
return s; return s;
} }
util.getBetweenDate = function (day, num, str = '-') {
var today = new Date(day);
var nowTime = today.getTime();
var ms = 24 * 3600 * 1000 * num;
today.setTime(parseInt(nowTime - ms));
var oYear = today.getFullYear();
var oMoth = (today.getMonth() + 1).toString();
if (oMoth.length <= 1) oMoth = '0' + oMoth;
var oDay = today.getDate().toString();
if (oDay.length <= 1) oDay = '0' + oDay;
return oYear + str + oMoth + str + oDay;
}
util.getBeforeMonth = function (days) { util.getBeforeMonth = function (days) {
let month = new Date().getMonth() + 1; let month = new Date().getMonth() + 1;
let year = new Date().getFullYear(); let year = new Date().getFullYear();
...@@ -33,6 +45,7 @@ util.getBeforeMonth = function (days) { ...@@ -33,6 +45,7 @@ util.getBeforeMonth = function (days) {
} }
return arr; return arr;
} }
util.getCurrentMonthLast = function (date) { util.getCurrentMonthLast = function (date) {
var endDate = new Date(date); var endDate = new Date(date);
var month = endDate.getMonth(); var month = endDate.getMonth();
...@@ -40,7 +53,7 @@ util.getCurrentMonthLast = function (date) { ...@@ -40,7 +53,7 @@ util.getCurrentMonthLast = function (date) {
var nextMonthFirstDay = new Date(endDate.getFullYear(), nextMonth, 1); var nextMonthFirstDay = new Date(endDate.getFullYear(), nextMonth, 1);
var oneDay = 1000 * 60 * 60 * 24; var oneDay = 1000 * 60 * 60 * 24;
var dateString = new Date(nextMonthFirstDay - oneDay); var dateString = new Date(nextMonthFirstDay - oneDay);
return dateString.toLocaleDateString().replace(new RegExp('/','g'),"-"); //toLocaleDateString() 返回 如:2018/8/31 return dateString.toLocaleDateString().replace(new RegExp('/', 'g'), "-"); //toLocaleDateString() 返回 如:2018/8/31
} }
util.openUrl = function (url) { util.openUrl = function (url) {
......
<template>
<div class="square-main" v-loading="loading">
<el-dialog title="客户列表" :visible.sync="dialogVisible" width="70%" :before-close="handleClose">
<el-form :inline="true" :model="tableSearchForm" class="emp-form">
<el-form-item size="small" label="客户名称">
<el-input v-model="tableSearchForm.customerName" placeholder="请输入客户名称"></el-input>
</el-form-item>
<el-form-item size="small" label="状态">
<el-select v-model="tableSearchForm.status" placeholder="请选择">
<el-option v-for="item in optionstatus" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
</el-form-item>
<el-form-item size="small" label="员工">
<el-input v-model="tableSearchForm.followStaff" placeholder="请输入客户名称"></el-input>
</el-form-item>
<el-form-item size="small" style="float: right; margin-right: 0px">
<el-button @click="handleSearch">重置</el-button>
<el-button type="primary" @click="handleSearch">查询</el-button>
<el-button type="primary" @click="handleExport">导出</el-button>
</el-form-item>
</el-form>
<GLTable v-loading="loading" ref="tableEmp" :layout="layout" :tableData="tableData" :tableTotal="tableTotal" :pageConf="pageConf" :tableParams="tableParams" @refreshTable="handleSearch" @selectionTable="selectionTable">
<span slot="addWay" slot-scope="scope">
<el-tooltip effect="dark" :content="toLabel(scope.scope.addWay)" placement="top">
<span style="display: inline-block; max-width: 120px; text-align: left">{{ toLabel(scope.scope.addWay) }}</span>
</el-tooltip>
</span>
<span slot="isJoin" slot-scope="scope">
<span>{{ scope.scope.isJoin ? '是' : '否' }}</span>
</span>
<template slot="status" slot-scope="scope">
<div class="status-form" v-if="scope.scope.status" style="color: #eb4e4e">删除好友</div>
<div class="status-form" v-else style="color: #00a854">正常</div>
</template>
<template slot="customerName" slot-scope="scope">
<div class="form-row">
{{ scope.scope.customerName }}
<span style="color: #5850ff">{{ scope.scope.type == 1 ? '@微信' : '@企微' }}</span>
</div>
</template>
<span slot="customerSex" slot-scope="scope">
<span>{{ scope.scope.customerSex == 0 ? '未知' : scope.scope.customerSex == 1 ? '男' : '女' }}</span>
</span>
<div slot="followStaff" class="entmicro" slot-scope="scope">
<div class="entmicro-tag" v-for="(tag, idx) in followList(scope.scope.followStaff)" :key="idx">
<el-tooltip effect="dark" :content="tag" placement="top">
<el-tag type="info" class="ellipsis-1" v-if="idx < 3" :disable-transitions="false">
<i class="el-icon-user-solid"></i>
{{ tag }}
</el-tag>
</el-tooltip>
<el-tag type="info" v-if="followList(scope.scope.followStaff).length > 3 && idx == 3">
<el-popover placement="top" width="600" trigger="hover" content="这是一段内容,这是一段内容,这是一段内容,这是一段内容。">
<div slot="reference">...({{ followList(scope.scope.followStaff).length }})</div>
<div class="entmicro-hover">
<el-tag type="info" style="margin-right: 10px; margin-bottom: 10px" v-for="(i, index) in followList(scope.scope.followStaff)" :key="index" :disable-transitions="false">
<i class="el-icon-user-solid" style="color: #75acff"></i>
<!-- {{ i.staffName }}{{ i.departmentName ? `(${i.departmentName})` : '' }} -->
{{ i }}
</el-tag>
</div>
</el-popover>
</el-tag>
</div>
</div>
</GLTable>
<span slot="footer" class="dialog-footer">
<el-button size="small" @click="handleCancel" type="primary">关闭</el-button>
</span>
</el-dialog>
</div>
</template>
<script>
import { utils } from 'glsx-common'
import util from '@/utils/util'
export default {
name: 'customDetail',
data() {
return {
loading: false,
dialogVisible: false,
status: '',
createTime: [],
optionstatus: [
{
value: '',
label: '全部'
},
{
value: '0',
label: '正常'
},
{
value: '-1',
label: '删除好友'
}
],
optionsRule: [
{
value: '',
label: '全部'
},
{
value: '0',
label: '不显示存量客户'
},
{
value: '-1',
label: '显示存量客户'
}
],
tableSearchForm: {},
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
tableParams: {
listName: 'data',
tableOption: false,
tableColumns: [
{
label: '客户名称',
prop: 'customerName',
addHtml: 'customerName'
},
{
label: '手机号',
prop: 'followStaff'
},
{
label: '跟进员工',
prop: 'followStaff',
addHtml: 'followStaff',
minWidth: 120
},
{
label: '来源',
prop: 'addWay',
addHtml: 'addWay',
minWidth: 100
},
{
label: '是否加企微', //1. 加入,0.未加入
prop: 'isJoin',
addHtml: 'isJoin',
width: 100
},
{
label: '当前状态',
prop: 'status',
addHtml: 'status',
minWidth: 100
},
{
label: '添加时间',
prop: 'addTime',
width: 98
}
]
},
layout: 'sizes, prev, pager, next, jumper, ->, total',
tableData: [],
staffName: [],
tableTotal: 0,
selectItem: [],
selectEmp: [],
pStatus: null,
staffIds: null,
staffId: null,
beginTime: null,
endTime: null,
deleteTime: null,
isJoin: 0
}
},
methods: {
//来源 value值转为对应label
toLabel(value) {
// if (value !== 0 && !value) {
// return
// }
// let curElement = this.sourceList.find(item => {
// return item.value === value
// })
// return curElement.label
},
followList(str) {
if (!str) {
return []
}
return str.split(',')
},
jumpUrl() {
this.$history.push('/home/followUp/index')
},
getFollower() {
var params = {
...JSON.parse(JSON.stringify(this.tableSearchForm)),
pageSize: this.$refs.tableEmp.page.pageSize,
pageNum: this.$refs.tableEmp.page.pageNum,
isJoin: this.isJoin,
beginTime: this.beginTime,
endTime: this.endTime,
deleteTime: this.deleteTime
}
this.loading = true
this.$apis.home.getCustomer(params).then(res => {
this.loading = false
this.tableData = res.data
this.tableTotal = res.count
})
},
init(day1, day2, status,day3) {
this.beginTime = day1
this.endTime = day2
this.deleteTime = day3
this.isJoin = status
this.dialogVisible = true
this.$nextTick(() => {
this.$refs.tableEmp.page.pageNum = 1
this.getFollower()
})
},
handleExport() {
var params = {
...JSON.parse(JSON.stringify(this.tableSearchForm)),
isJoin: this.isJoin,
beginTime: this.beginTime,
endTime: this.endTime,
deleteTime: this.deleteTime
}
this.$apis.home.customerViewExport(params).then(res => {
util.openUrl(res)
})
},
handleSearch() {
this.getFollower()
},
selectionTable(val) {
this.selectItem = val
},
handleClose() {
this.handleCancel()
},
handleDetail(scope) {
this.$history.push('/custom/clientManage/clientDetail?id=' + scope.oneId)
},
handleCancel: utils.debounce(function () {
this.dialogVisible = false
}, 300)
}
}
</script>
<style lang="scss" scoped>
.dialog-jump {
color: #5850ff;
float: left;
line-height: 24px;
text-decoration: underline;
cursor: pointer;
}
.emp-form {
/deep/ {
.el-date-editor,
.el-input {
width: 215px;
}
}
}
.square-main {
/deep/ {
.el-table {
height: 35vh;
overflow-y: auto;
}
.el-form-item {
margin-right: 20px;
}
.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="square-main" v-loading="loading">
<el-dialog title="客户列表" :visible.sync="dialogVisible" width="70%" :before-close="handleClose">
<el-form :inline="true" :model="tableSearchForm" class="emp-form">
<el-form-item size="small" label="群主">
<el-input v-model="tableSearchForm.groupHostName" placeholder="请输入客户名称"></el-input>
</el-form-item>
<el-form-item size="small" label="群聊昵称" v-if="!pStatus">
<el-input v-model="tableSearchForm.custGroupName" placeholder="请输入客户名称"></el-input>
</el-form-item>
<el-form-item size="small" label="管理员" v-if="!pStatus">
<el-input v-model="tableSearchForm.groupAdminName" placeholder="请输入客户名称"></el-input>
</el-form-item>
<el-form-item size="small" style="float: right; margin-right: 0px">
<el-button type="primary" @click="handleSearch">查询</el-button>
<el-button type="primary" @click="handleExport">导出</el-button>
</el-form-item>
</el-form>
<GLTable v-loading="loading" ref="tableEmp" :layout="layout" :tableData="tableData" :tableTotal="tableTotal" :pageConf="pageConf" :tableParams="tableParams" @refreshTable="handleSearch" @selectionTable="selectionTable">
<div class="table-btns" slot="optionBtns" slot-scope="scope">
<el-button type="text" @click="handleDetail(scope.scope)">详情</el-button>
</div>
<template slot="status" slot-scope="scope">
<div class="status-form" v-if="scope.scope.status" style="color: #eb4e4e">删除好友</div>
<div class="status-form" v-else style="color: #00a854">正常</div>
</template>
<template slot="customerName" slot-scope="scope">
<div class="form-row">
{{ scope.scope.customerName }}
<span style="color: #5850ff">{{ scope.scope.type == 1 ? '@微信' : '@企微' }}</span>
</div>
</template>
</GLTable>
<span slot="footer" class="dialog-footer">
<el-button size="small" @click="handleCancel" type="primary">关闭</el-button>
</span>
</el-dialog>
</div>
</template>
<script>
import { utils } from 'glsx-common'
import util from '@/utils/util'
export default {
name: 'customDetail',
data() {
return {
loading: false,
dialogVisible: false,
status: '',
createTime: [],
optionstatus: [
{
value: '',
label: '全部'
},
{
value: '0',
label: '正常'
},
{
value: '-1',
label: '删除好友'
}
],
tableSearchForm: {},
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
tableParams: {
listName: 'data',
tableOption: false,
tableColumns: [
{
label: '群聊名称',
prop: 'custGroupName',
minWidth: 160
},
{
label: '当前成员总数',
prop: 'allMembers',
minWidth: 110
},
{
label: '当前客户数',
prop: 'totalCount',
minWidth: 90
},
{
label: '当日新增入群客户数',
prop: 'newCustomerCount',
minWidth: 150
},
{
label: '当日新增退群客户数',
prop: 'delCustomerCount',
minWidth: 150
},
{
label: '当前跟进员工数',
prop: 'staffs',
minWidth: 130
},
{
label: '群主',
prop: 'groupHostName'
},
{
label: '管理员',
prop: 'groupAdminName'
},
{
label: '创建时间',
prop: 'addTime',
width: 140
}
]
},
layout: 'sizes, prev, pager, next, jumper, ->, total',
tableData: [],
staffName: [],
tableTotal: 0,
selectItem: [],
selectEmp: [],
pStatus: null,
staffIds: null,
staffId: null,
endTime: null,
beginTime: null
}
},
methods: {
jumpUrl() {
this.$history.push('/home/followUp/index')
},
getFollower() {
var params = {
...JSON.parse(JSON.stringify(this.tableSearchForm)),
pageSize: this.$refs.tableEmp.page.pageSize,
pageNum: this.$refs.tableEmp.page.pageNum,
beginTime: this.beginTime,
endTime: this.endTime
}
this.loading = true
this.$apis.home.customerCustPage(params).then(res => {
this.loading = false
this.tableData = res.data
this.tableTotal = res.count
})
},
init(day) {
console.log(day)
this.beginTime = day
this.endTime = day
this.dialogVisible = true
this.$nextTick(() => {
this.$refs.tableEmp.page.pageNum = 1
this.getFollower()
})
},
handleSearch() {
this.getFollower()
},
handleExport() {
var params = {
...JSON.parse(JSON.stringify(this.tableSearchForm)),
beginTime: this.beginTime,
endTime: this.endTime
}
this.$apis.home.customerBaseCustListExport(params).then(res => {
util.openUrl(res)
})
},
selectionTable(val) {
this.selectItem = val
},
handleClose() {
this.handleCancel()
},
handleDetail(scope) {
this.$history.push('/custom/clientManage/clientDetail?id=' + scope.oneId)
},
handleCancel: utils.debounce(function () {
this.dialogVisible = false
}, 300)
}
}
</script>
<style lang="scss" scoped>
.dialog-jump {
color: #5850ff;
float: left;
line-height: 24px;
text-decoration: underline;
cursor: pointer;
}
.emp-form {
/deep/ {
.el-date-editor,
.el-input {
width: 215px;
}
}
}
.square-main {
/deep/ {
.el-table {
height: 35vh;
overflow-y: auto;
}
.el-form-item {
margin-right: 20px;
}
.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="square-main" v-loading="loading">
<el-dialog title="客户列表" :visible.sync="dialogVisible" width="70%" :before-close="handleClose">
<el-form :inline="true" :model="tableSearchForm" class="emp-form">
<el-form-item size="small" label="客户名称">
<el-input v-model="tableSearchForm.customerName" placeholder="请输入客户名称"></el-input>
</el-form-item>
<el-form-item size="small" label="状态" v-if="!pStatus">
<el-select v-model="tableSearchForm.status" placeholder="请选择">
<el-option v-for="item in optionstatus" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
</el-form-item>
<el-form-item size="small" label="跟进员工" v-if="!staffIds">
<el-select v-model="staffId" placeholder="请选择">
<el-option v-for="item in staffName" :key="item.staffId" :label="item.staffName" :value="item.staffId"></el-option>
</el-select>
</el-form-item>
<el-form-item size="small" label="添加时间" v-if="timeStatus">
<el-date-picker :picker-options="pickerOptions" value-format="yyyy-MM-dd" v-model="createTime" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
</el-form-item>
<el-form-item size="small" style="float: right; margin-right: 0px">
<el-button type="primary" @click="handleSearch">查询</el-button>
</el-form-item>
</el-form>
<GLTable v-loading="loading" ref="tableEmp" :layout="layout" :tableData="tableData" :tableTotal="tableTotal" :pageConf="pageConf" :tableParams="tableParams" @refreshTable="handleSearch" @selectionTable="selectionTable">
<div class="table-btns" slot="optionBtns" slot-scope="scope">
<el-button type="text" @click="handleDetail(scope.scope)">详情</el-button>
</div>
<template slot="status" slot-scope="scope">
<div class="status-form" v-if="scope.scope.status" style="color: #eb4e4e">删除好友</div>
<div class="status-form" v-else style="color: #00a854">正常</div>
</template>
<template slot="customerName" slot-scope="scope">
<div class="form-row">
{{ scope.scope.customerName }}
<span style="color: #5850ff">{{ scope.scope.type == 1 ? '@微信' : '@企微' }}</span>
</div>
</template>
</GLTable>
<span slot="footer" class="dialog-footer">
<el-button size="small" @click="handleCancel" type="primary">关闭</el-button>
</span>
</el-dialog>
</div>
</template>
<script>
import { utils } from 'glsx-common'
import util from '@/utils/util'
const stateList = [
{
confId: 0,
confName: '待上架'
},
{
confId: 1,
confName: '在售中'
},
{
confId: 2,
confName: '已下架'
}
]
export default {
name: 'customDetail',
data() {
return {
loading: false,
dialogVisible: false,
status: '',
createTime: [],
optionstatus: [
{
value: '',
label: '全部'
},
{
value: '0',
label: '正常'
},
{
value: '-1',
label: '删除好友'
}
],
tableSearchForm: {},
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
tableParams: {
listName: 'data',
tableOption: false,
tableColumns: [
{
label: '套餐名称',
prop: 'packageName',
width: '180'
},
{
label: '套餐售价',
prop: 'packagePrice',
line: 1
},
{
label: '套餐总价',
prop: 'referencePrice'
},
{
label: '套餐内容',
prop: 'list',
addHtml: 'list'
},
{
label: '说明',
prop: 'notes',
width: 160,
line: 4
},
{
label: '状态',
prop: 'state',
width: '80',
formatter: cellValue => {
return this.baseDataList.stateList.find(item => item.confId == cellValue.state).confName
}
}
]
},
baseDataList: {
stateList: stateList
},
layout: 'sizes, prev, pager, next, jumper, ->, total',
tableData: [],
staffName: [],
tableTotal: 0,
selectItem: [],
selectEmp: [],
pStatus: null,
staffIds: null,
staffId: null
}
},
methods: {
jumpUrl() {
this.$history.push('/home/followUp/index')
},
getFollower() {
var params = {
...JSON.parse(JSON.stringify(this.tableSearchForm)),
pageSize: this.$refs.tableEmp.page.pageSize,
pageNum: this.$refs.tableEmp.page.pageNum
}
this.loading = true
this.$apis.home.getCustomer(params).then(res => {
this.loading = false
this.tableData = res.data
this.tableTotal = res.count
})
},
init() {
this.dialogVisible = true
this.$nextTick(() => {
this.$refs.tableEmp.page.pageNum = 1
this.getFollower()
})
},
handleSearch() {
this.getFollower()
},
selectionTable(val) {
this.selectItem = val
},
handleClose() {
this.handleCancel()
},
handleDetail(scope) {
this.$history.push('/custom/clientManage/clientDetail?id=' + scope.oneId)
},
handleCancel: utils.debounce(function () {
this.dialogVisible = false
}, 300)
}
}
</script>
<style lang="scss" scoped>
.dialog-jump {
color: #5850ff;
float: left;
line-height: 24px;
text-decoration: underline;
cursor: pointer;
}
.emp-form {
/deep/ {
.el-date-editor,
.el-input {
width: 215px;
}
}
}
.square-main {
/deep/ {
.el-table {
height: 35vh;
overflow-y: auto;
}
.el-form-item {
margin-right: 20px;
}
.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="square-main" v-loading="loading">
<el-dialog title="客户列表" :visible.sync="dialogVisible" width="70%" :before-close="handleClose">
<el-form :inline="true" :model="tableSearchForm" class="emp-form">
<el-form-item size="small" label="客户名称">
<el-input v-model="tableSearchForm.customerName" placeholder="请输入客户名称"></el-input>
</el-form-item>
<el-form-item size="small" label="状态" v-if="!pStatus">
<el-select v-model="tableSearchForm.status" placeholder="请选择">
<el-option v-for="item in optionstatus" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
</el-form-item>
<el-form-item size="small" label="跟进员工" v-if="!staffIds">
<el-select v-model="staffId" placeholder="请选择">
<el-option v-for="item in staffName" :key="item.staffId" :label="item.staffName" :value="item.staffId"></el-option>
</el-select>
</el-form-item>
<el-form-item size="small" label="添加时间" v-if="timeStatus">
<el-date-picker :picker-options="pickerOptions" value-format="yyyy-MM-dd" v-model="createTime" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
</el-form-item>
<el-form-item size="small" style="float: right; margin-right: 0px">
<el-button type="primary" @click="handleSearch">查询</el-button>
</el-form-item>
</el-form>
<GLTable v-loading="loading" ref="tableEmp" :layout="layout" :tableData="tableData" :tableTotal="tableTotal" :pageConf="pageConf" :tableParams="tableParams" @refreshTable="handleSearch" @selectionTable="selectionTable">
<div class="table-btns" slot="optionBtns" slot-scope="scope">
<el-button type="text" @click="handleDetail(scope.scope)">详情</el-button>
</div>
<template slot="status" slot-scope="scope">
<div class="status-form" v-if="scope.scope.status" style="color: #eb4e4e">删除好友</div>
<div class="status-form" v-else style="color: #00a854">正常</div>
</template>
<template slot="customerName" slot-scope="scope">
<div class="form-row">
{{ scope.scope.customerName }}
<span style="color: #5850ff">{{ scope.scope.type == 1 ? '@微信' : '@企微' }}</span>
</div>
</template>
</GLTable>
<span slot="footer" class="dialog-footer">
<el-button size="small" @click="handleCancel" type="primary">关闭</el-button>
</span>
</el-dialog>
</div>
</template>
<script>
import { utils } from 'glsx-common'
import util from '@/utils/util'
export default {
name: 'customDetail',
data() {
return {
loading: false,
dialogVisible: false,
status: '',
createTime: [],
optionstatus: [
{
value: '',
label: '全部'
},
{
value: '0',
label: '正常'
},
{
value: '-1',
label: '删除好友'
}
],
tableSearchForm: {},
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
tableParams: {
listName: 'data',
tableOption: false,
tableColumns: [
{
label: '客户名称',
prop: 'customerName',
addHtml: 'customerName'
},
{
label: '微信号',
prop: 'status',
addHtml: 'status'
},
{
label: '手机号',
prop: 'followStaff'
},
{
label: '跟进专员',
prop: 'addTime'
},
{
label: '添加来源',
prop: 'addTime'
},
{
label: '流失时间',
prop: 'addTime'
},
{
label: '当前状态',
prop: 'addTime'
},
{
label: '操作',
prop: 'optionBtns',
width: '80px',
addHtml: 'optionBtns'
}
]
},
layout: 'sizes, prev, pager, next, jumper, ->, total',
tableData: [],
staffName: [],
tableTotal: 0,
selectItem: [],
selectEmp: [],
pStatus: null,
staffIds: null,
staffId: null
}
},
methods: {
jumpUrl() {
this.$history.push('/home/followUp/index')
},
getFollower() {
var params = {
...JSON.parse(JSON.stringify(this.tableSearchForm)),
pageSize: this.$refs.tableEmp.page.pageSize,
pageNum: this.$refs.tableEmp.page.pageNum,
}
this.loading = true
this.$apis.home.getCustomer(params).then(res => {
this.loading = false
this.tableData = res.data
this.tableTotal = res.count
})
},
init() {
this.dialogVisible = true
this.$nextTick(() => {
this.$refs.tableEmp.page.pageNum = 1
this.getFollower()
})
},
handleSearch() {
this.getFollower()
},
selectionTable(val) {
this.selectItem = val
},
handleClose() {
this.handleCancel()
},
handleDetail(scope) {
this.$history.push('/custom/clientManage/clientDetail?id=' + scope.oneId)
},
handleCancel: utils.debounce(function () {
this.dialogVisible = false
}, 300)
}
}
</script>
<style lang="scss" scoped>
.dialog-jump {
color: #5850ff;
float: left;
line-height: 24px;
text-decoration: underline;
cursor: pointer;
}
.emp-form {
/deep/ {
.el-date-editor,.el-input {
width: 215px;
}
}
}
.square-main {
/deep/ {
.el-table {
height: 35vh;
overflow-y: auto;
}
.el-form-item {
margin-right: 20px;
}
.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="square-main" v-loading="loading">
<el-dialog title="客户列表" :visible.sync="dialogVisible" width="70%" :before-close="handleClose">
<el-form :inline="true" :model="tableSearchForm" class="emp-form">
<el-form-item size="small" label="客户名称">
<el-input v-model="tableSearchForm.customerName" placeholder="请输入客户名称"></el-input>
</el-form-item>
<el-form-item size="small" label="状态" v-if="!pStatus">
<el-select v-model="tableSearchForm.status" placeholder="请选择">
<el-option v-for="item in optionstatus" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
</el-form-item>
<el-form-item size="small" label="跟进员工" v-if="!staffIds">
<el-select v-model="staffId" placeholder="请选择">
<el-option v-for="item in staffName" :key="item.staffId" :label="item.staffName" :value="item.staffId"></el-option>
</el-select>
</el-form-item>
<el-form-item size="small" label="添加时间" v-if="timeStatus">
<el-date-picker :picker-options="pickerOptions" value-format="yyyy-MM-dd" v-model="createTime" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
</el-form-item>
<el-form-item size="small" style="float: right; margin-right: 0px">
<el-button type="primary" @click="handleSearch">查询</el-button>
</el-form-item>
</el-form>
<GLTable v-loading="loading" ref="tableEmp" :layout="layout" :tableData="tableData" :tableTotal="tableTotal" :pageConf="pageConf" :tableParams="tableParams" @refreshTable="handleSearch" @selectionTable="selectionTable">
<div class="table-btns" slot="optionBtns" slot-scope="scope">
<el-button type="text" @click="handleDetail(scope.scope)">详情</el-button>
</div>
<template slot="status" slot-scope="scope">
<div class="status-form" v-if="scope.scope.status" style="color: #eb4e4e">删除好友</div>
<div class="status-form" v-else style="color: #00a854">正常</div>
</template>
<template slot="customerName" slot-scope="scope">
<div class="form-row">
{{ scope.scope.customerName }}
<span style="color: #5850ff">{{ scope.scope.type == 1 ? '@微信' : '@企微' }}</span>
</div>
</template>
</GLTable>
<span slot="footer" class="dialog-footer">
<el-button size="small" @click="handleCancel" type="primary">关闭</el-button>
</span>
</el-dialog>
</div>
</template>
<script>
import { utils } from 'glsx-common'
import util from '@/utils/util'
export default {
name: 'customDetail',
data() {
return {
loading: false,
dialogVisible: false,
status: '',
createTime: [],
optionstatus: [
{
value: '',
label: '全部'
},
{
value: '0',
label: '正常'
},
{
value: '-1',
label: '删除好友'
}
],
tableSearchForm: {},
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
tableParams: {
listName: 'data',
tableOption: false,
tableColumns: [
{
label: '订单编号',
prop: 'customerName',
addHtml: 'customerName'
},
{
label: '客户姓名',
prop: 'status',
addHtml: 'status'
},
{
label: '客户手机号',
prop: 'followStaff'
},
{
label: '商品/套餐名称',
prop: 'addTime'
},
{
label: '订单支付时间',
prop: 'addTime'
},
{
label: '订单支付金额',
prop: 'addTime'
},
{
label: '订单类型',
prop: 'addTime'
},
{
label: '订单状态',
prop: 'addTime'
},
{
label: '操作',
prop: 'optionBtns',
width: '80px',
addHtml: 'optionBtns'
}
]
},
layout: 'sizes, prev, pager, next, jumper, ->, total',
tableData: [],
staffName: [],
tableTotal: 0,
selectItem: [],
selectEmp: [],
pStatus: null,
staffIds: null,
staffId: null
}
},
methods: {
jumpUrl() {
this.$history.push('/home/followUp/index')
},
getFollower() {
var params = {
...JSON.parse(JSON.stringify(this.tableSearchForm)),
pageSize: this.$refs.tableEmp.page.pageSize,
pageNum: this.$refs.tableEmp.page.pageNum,
}
this.loading = true
this.$apis.home.getCustomer(params).then(res => {
this.loading = false
this.tableData = res.data
this.tableTotal = res.count
})
},
init() {
this.dialogVisible = true
this.$nextTick(() => {
this.$refs.tableEmp.page.pageNum = 1
this.getFollower()
})
},
handleSearch() {
this.getFollower()
},
selectionTable(val) {
this.selectItem = val
},
handleClose() {
this.handleCancel()
},
handleDetail(scope) {
this.$history.push('/custom/clientManage/clientDetail?id=' + scope.oneId)
},
handleCancel: utils.debounce(function () {
this.dialogVisible = false
}, 300)
}
}
</script>
<style lang="scss" scoped>
.dialog-jump {
color: #5850ff;
float: left;
line-height: 24px;
text-decoration: underline;
cursor: pointer;
}
.emp-form {
/deep/ {
.el-date-editor,.el-input {
width: 215px;
}
}
}
.square-main {
/deep/ {
.el-table {
height: 35vh;
overflow-y: auto;
}
.el-form-item {
margin-right: 20px;
}
.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="square-main" v-loading="loading">
<el-dialog title="客户列表" :visible.sync="dialogVisible" width="70%" :before-close="handleClose">
<el-form :inline="true" :model="tableSearchForm" class="emp-form">
<el-form-item size="small" label="客户名称">
<el-input v-model="tableSearchForm.customerName" placeholder="请输入客户名称"></el-input>
</el-form-item>
<el-form-item size="small" label="状态" v-if="!pStatus">
<el-select v-model="tableSearchForm.status" placeholder="请选择">
<el-option v-for="item in optionstatus" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
</el-form-item>
<el-form-item size="small" label="跟进员工" v-if="!staffIds">
<el-select v-model="staffId" placeholder="请选择">
<el-option v-for="item in staffName" :key="item.staffId" :label="item.staffName" :value="item.staffId"></el-option>
</el-select>
</el-form-item>
<el-form-item size="small" label="添加时间" v-if="timeStatus">
<el-date-picker :picker-options="pickerOptions" value-format="yyyy-MM-dd" v-model="createTime" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
</el-form-item>
<el-form-item size="small" style="float: right; margin-right: 0px">
<el-button type="primary" @click="handleSearch">查询</el-button>
</el-form-item>
</el-form>
<!-- <GLTable ref="tableEmp" class="table-img" :getListApi="getListApi" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn">
<template slot="goodsImage" slot-scope="scope">
<img class="img-60" :src="scope.scope.goodsImage" />
</template>
</GLTable> -->
<span slot="footer" class="dialog-footer">
<el-button size="small" @click="handleCancel" type="primary">关闭</el-button>
</span>
</el-dialog>
</div>
</template>
<script>
import { utils } from 'glsx-common'
import util from '@/utils/util'
export default {
name: 'customDetail',
data() {
return {
loading: false,
dialogVisible: false,
status: '',
createTime: [],
optionstatus: [
{
value: '',
label: '全部'
},
{
value: '0',
label: '正常'
},
{
value: '-1',
label: '删除好友'
}
],
getListApi: '',
tableSearchForm: {},
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
tableParams: {
listName: 'data',
tableOption: false,
tableColumns: [
{
label: '商品名称',
prop: 'goodsName',
line: 2
},
{
label: '缩略图',
prop: 'goodsImage',
addHtml: 'goodsImage'
},
{
label: '浏览量(次)',
name: 'goodsStatistics',
width: '180',
formatter: cellValue => {
return cellValue.goodsStatistics ? cellValue.goodsStatistics.viewAmount || '0' : '0'
}
},
{
label: '销量',
name: 'goodsStatistics',
formatter: cellValue => {
return cellValue.goodsStatistics ? cellValue.goodsStatistics.saleAmount || '0' : '0'
}
},
{
label: '零售价(元)',
name: 'retailPrice',
width: '180',
formatter: cellValue => {
return cellValue.retailPrice
}
},
{
label: '库存',
name: 'goodsStock',
formatter: cellValue => {
return cellValue.goodsStock || '0'
}
},
{
label: '创建日期',
prop: 'createdDate',
width: '180',
// formatter: cellValue => {
// return dayjs(cellValue.createdDate).format('YYYY-MM-DD HH:mm:ss')
// }
},
{
label: '商品状态',
name: 'goodsStatus',
// formatter: cellValue => {
// return this.baseData.goodsStatusList.find(item => item.confId == cellValue.goodsStatus).confName
// }
},
{
label: '带货来源',
name: 'goodsSource',
// formatter: cellValue => {
// return this.baseData.goodsSourceList.find(item => item.confId == cellValue.goodsSource).confName
// }
}
]
},
layout: 'sizes, prev, pager, next, jumper, ->, total',
tableData: [],
staffName: [],
tableTotal: 0,
selectItem: [],
selectEmp: [],
pStatus: null,
staffIds: null,
staffId: null
}
},
methods: {
jumpUrl() {
this.$history.push('/home/followUp/index')
},
getFollower() {
var params = {
...JSON.parse(JSON.stringify(this.tableSearchForm)),
pageSize: this.$refs.tableEmp.page.pageSize,
pageNum: this.$refs.tableEmp.page.pageNum
}
this.loading = true
this.$apis.home.getCustomer(params).then(res => {
this.loading = false
this.tableData = res.data
this.tableTotal = res.count
})
},
init() {
this.dialogVisible = true
this.$nextTick(() => {
this.$refs.tableEmp.page.pageNum = 1
this.getFollower()
})
},
handleSearch() {
this.getFollower()
},
selectionTable(val) {
this.selectItem = val
},
handleClose() {
this.handleCancel()
},
handleDetail(scope) {
this.$history.push('/custom/clientManage/clientDetail?id=' + scope.oneId)
},
handleCancel: utils.debounce(function () {
this.dialogVisible = false
}, 300)
}
}
</script>
<style lang="scss" scoped>
.dialog-jump {
color: #5850ff;
float: left;
line-height: 24px;
text-decoration: underline;
cursor: pointer;
}
.emp-form {
/deep/ {
.el-date-editor,
.el-input {
width: 215px;
}
}
}
.square-main {
/deep/ {
.el-table {
height: 35vh;
overflow-y: auto;
}
.el-form-item {
margin-right: 20px;
}
.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="square-main" v-loading="loading">
<el-dialog title="客户列表" :visible.sync="dialogVisible" width="70%" :before-close="handleClose">
<el-form :inline="true" :model="tableSearchForm" class="emp-form">
<el-form-item size="small" label="客户名称">
<el-input v-model="tableSearchForm.customerName" placeholder="请输入客户名称"></el-input>
</el-form-item>
<el-form-item size="small" label="状态" v-if="!pStatus">
<el-select v-model="tableSearchForm.status" placeholder="请选择">
<el-option v-for="item in optionstatus" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
</el-form-item>
<el-form-item size="small" label="跟进员工" v-if="!staffIds">
<el-select v-model="staffId" placeholder="请选择">
<el-option v-for="item in staffName" :key="item.staffId" :label="item.staffName" :value="item.staffId"></el-option>
</el-select>
</el-form-item>
<el-form-item size="small" label="添加时间" v-if="timeStatus">
<el-date-picker :picker-options="pickerOptions" value-format="yyyy-MM-dd" v-model="createTime" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
</el-form-item>
<el-form-item size="small" style="float: right; margin-right: 0px">
<el-button type="primary" @click="handleSearch">查询</el-button>
</el-form-item>
</el-form>
<!-- <GLTable ref="tableEmp" class="table-img" :getListApi="getListApi" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn">
<template slot="goodsImage" slot-scope="scope">
<img class="img-60" :src="scope.scope.goodsImage" />
</template>
</GLTable> -->
<span slot="footer" class="dialog-footer">
<el-button size="small" @click="handleCancel" type="primary">关闭</el-button>
</span>
</el-dialog>
</div>
</template>
<script>
import { utils } from 'glsx-common'
import util from '@/utils/util'
export default {
name: 'customDetail',
data() {
return {
loading: false,
dialogVisible: false,
status: '',
createTime: [],
optionstatus: [
{
value: '',
label: '全部'
},
{
value: '0',
label: '正常'
},
{
value: '-1',
label: '删除好友'
}
],
getListApi: '',
tableSearchForm: {},
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
tableParams: {
listName: 'data',
tableOption: false,
tableColumns: [
{
value: 'orderCode',
label: '主订单编号',
level: 1,
width: '200',
disabled: true
},
{
value: 'tradeNo',
label: '交易参考号',
level: 1,
width: '200',
disabled: true
},
{
value: 'subOrderCode',
label: '子订单编号',
level: 1,
width: '200',
disabled: true
},
{
value: 'upgradeGoodsName',
label: '商品名称',
level: 1,
width: '200',
disabled: false
},
{
value: 'upgradeGoodsCommodityCode',
label: '商品编号',
level: 1,
width: '200',
disabled: false
},
{
value: 'goodsCost',
label: '商品成本',
level: 1,
width: '110',
disabled: false
},
{
value: 'customerName',
label: '客户姓名',
level: 1,
width: '110',
disabled: false
},
{
value: 'customerPhone',
label: '客户手机号',
level: 2,
width: '110',
disabled: false
},
{
value: 'sellerName',
label: '转化员姓名',
level: 2,
width: '110',
disabled: false
},
{
value: 'employeeName',
label: '销售顾问',
level: 2,
width: '110',
disabled: false
},
{
value: 'paySuccessDate',
label: '支付时间',
level: 2,
width: '160',
disabled: false
},
{
value: 'payTypeName',
label: '支付方式',
level: 3,
width: '110',
disabled: false
},
{
value: 'subTotalPrice',
label: '支付金额',
level: 3,
width: '110',
disabled: true
},
{
value: 'actualIncomeMoney',
label: '总分账金额',
level: 3,
width: '110',
disabled: true
},
{
value: 'shopMerchantName',
label: '分账对象',
level: 3,
width: '110',
disabled: false
},
{
value: 'rule',
label: '分账规则',
level: 3,
width: '80',
disabled: false
},
{
value: 'shopProfitMoney',
label: '分账金额',
level: 3,
width: '110',
disabled: true
},
{
value: 'divisionTypeName',
label: '分账类型',
level: 3,
width: '110',
disabled: false
}
]
},
layout: 'sizes, prev, pager, next, jumper, ->, total',
tableData: [],
staffName: [],
tableTotal: 0,
selectItem: [],
selectEmp: [],
pStatus: null,
staffIds: null,
staffId: null
}
},
methods: {
jumpUrl() {
this.$history.push('/home/followUp/index')
},
getFollower() {
var params = {
...JSON.parse(JSON.stringify(this.tableSearchForm)),
pageSize: this.$refs.tableEmp.page.pageSize,
pageNum: this.$refs.tableEmp.page.pageNum
}
this.loading = true
this.$apis.home.getCustomer(params).then(res => {
this.loading = false
this.tableData = res.data
this.tableTotal = res.count
})
},
init() {
this.dialogVisible = true
this.$nextTick(() => {
this.$refs.tableEmp.page.pageNum = 1
this.getFollower()
})
},
handleSearch() {
this.getFollower()
},
selectionTable(val) {
this.selectItem = val
},
handleClose() {
this.handleCancel()
},
handleDetail(scope) {
this.$history.push('/custom/clientManage/clientDetail?id=' + scope.oneId)
},
handleCancel: utils.debounce(function () {
this.dialogVisible = false
}, 300)
}
}
</script>
<style lang="scss" scoped>
.dialog-jump {
color: #5850ff;
float: left;
line-height: 24px;
text-decoration: underline;
cursor: pointer;
}
.emp-form {
/deep/ {
.el-date-editor,
.el-input {
width: 215px;
}
}
}
.square-main {
/deep/ {
.el-table {
height: 35vh;
overflow-y: auto;
}
.el-form-item {
margin-right: 20px;
}
.el-table::before {
left: 0;
bottom: 0;
width: 100%;
height: 0px;
}
}
}
</style>
\ No newline at end of file \ No newline at end of file
...@@ -8,11 +8,11 @@ ...@@ -8,11 +8,11 @@
</div> </div>
</div> </div>
<div class="view-title-num">{{ totalOutputValue ? '¥' + totalOutputValue : '¥ - -' }}</div> <div class="view-title-num">{{ totalBillNum }}</div>
</div> </div>
<div class="view-chart"> <div class="view-chart">
<div class="view-chart-title">产值分析</div> <div class="view-chart-title">产值分析</div>
<output-echart echartId="echartId_2" lineType="2" :outputCircle="output" v-show="!output.boutiqueUpgradeTotalOutputValueRadio || output.shopmallTotalOutputValueRadio || output.otherTotalOutputValueRadio"></output-echart> <output-echart echartId="echartId_2" lineType="2" :outputCircle="output"></output-echart>
<!-- <div class="view-chart-empty" v-show="!(output.boutiqueUpgradeTotalOutputValueRadio || output.shopmallTotalOutputValueRadio || output.otherTotalOutputValueRadio)"> <!-- <div class="view-chart-empty" v-show="!(output.boutiqueUpgradeTotalOutputValueRadio || output.shopmallTotalOutputValueRadio || output.otherTotalOutputValueRadio)">
<img src="@/assets/img/empty.png" /> <img src="@/assets/img/empty.png" />
<div>暂无数据</div> <div>暂无数据</div>
...@@ -27,22 +27,24 @@ ...@@ -27,22 +27,24 @@
</div> </div>
<div class="summary-item-total"> <div class="summary-item-total">
<div> <div>
{{ todayBillNum }}
<span>单</span> <span>单</span>
</div> </div>
<div class="summary-radio"> <div class="summary-radio">
日环比:37% 日环比:{{ billNumSequential }}%
<i class="el-icon-caret-top"></i> <i class="el-icon-caret-top" v-if="billNumSequential > 0"></i>
<!-- <i class="el-icon-caret-top"></i> --> <i class="el-icon-caret-bottom" v-if="billNumSequential < 0"></i>
</div> </div>
</div> </div>
</div> </div>
</div> </div>
<linechart :echartData="totalOutputValueTrends"></linechart> <linechart :echartData="serviceOrderTrendList"></linechart>
</div> </div>
</div> </div>
</template> </template>
<script> <script>
import util from '@/utils/util'
import outputEchart from './output-echart' import outputEchart from './output-echart'
import linechart from './linechart' import linechart from './linechart'
export default { export default {
...@@ -54,22 +56,9 @@ export default { ...@@ -54,22 +56,9 @@ export default {
data() { data() {
return { return {
output: {}, output: {},
totalOutputValueTrends: [], totalBillNum: 0,
shopmallOutputValueTrends: [], todayBillNum: 0,
boutiqueUpgradeOutputValueTrends: [], billNumSequential: 0
liveOutputValueTrends: [],
equityOutputValueTrends: [],
equityTotalOutputValue: 0,
totalOutputValue: 0,
todayTotalOutputValue: 0,
todayShopmallTotalOutputValue: 0,
todayBoutiqueUpgradeTotalOutputValue: 0,
liveTotalOutputValue: 0,
currentDayTotalOutputValue: 0,
currentDayShopmallTotalOutputValue: 0,
currentDayLiveTotalOutputValue: 0,
currentDayEquityTotalOutputValue: 0,
currentDayBoutiqueUpgradeTotalOutputValue: 0
} }
}, },
props: { props: {
...@@ -84,20 +73,12 @@ export default { ...@@ -84,20 +73,12 @@ export default {
}, },
methods: { methods: {
getOutput() { getOutput() {
this.$apis.home.outputValue({ dataEndDateStr: this.summaryTimeFomat }).then(res => { this.$apis.home.equityOrderStatistical({ dataStartDateStr: util.getBetweenDate(this.summaryTimeFomat, 30), dataEndDateStr: this.summaryTimeFomat, merchantId: '44184606' }).then(res => {
this.output = res this.output = res.servicePackageList
this.totalOutputValue = res.totalOutputValue this.totalBillNum = res.totalBillNum
this.currentDayTotalOutputValue = res.currentDayTotalOutputValue this.todayBillNum = res.todayBillNum
this.currentDayShopmallTotalOutputValue = res.currentDayShopmallTotalOutputValue this.billNumSequential = res.billNumSequential
this.currentDayLiveTotalOutputValue = res.currentDayLiveTotalOutputValue this.serviceOrderTrendList = res.serviceOrderTrendList
this.currentDayEquityTotalOutputValue = res.currentDayEquityTotalOutputValue
this.currentDayBoutiqueUpgradeTotalOutputValue = res.currentDayBoutiqueUpgradeTotalOutputValue
this.totalOutputValueTrends = res.totalOutputValueTrends
this.shopmallOutputValueTrends = res.shopmallOutputValueTrends
this.boutiqueUpgradeOutputValueTrends = res.boutiqueUpgradeOutputValueTrends
this.liveOutputValueTrends = res.liveOutputValueTrends
this.equityOutputValueTrends = res.equityOutputValueTrends
this.equityTotalOutputValue = res.equityTotalOutputValue
}) })
} }
}, },
......
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
</div> </div>
<div class="view-chart"> <div class="view-chart">
<div class="view-chart-title">产值分析</div> <div class="view-chart-title">产值分析</div>
<output-echart echartId="echartId" lineType="1" :outputCircle="output" v-show="!output.boutiqueUpgradeTotalOutputValueRadio || output.shopmallTotalOutputValueRadio || output.otherTotalOutputValueRadio"></output-echart> <output-echart echartId="echartId" lineType="1" :outputCircle="output"></output-echart>
<!-- <div class="view-chart-empty" v-show="!(output.boutiqueUpgradeTotalOutputValueRadio || output.shopmallTotalOutputValueRadio || output.otherTotalOutputValueRadio)"> <!-- <div class="view-chart-empty" v-show="!(output.boutiqueUpgradeTotalOutputValueRadio || output.shopmallTotalOutputValueRadio || output.otherTotalOutputValueRadio)">
<img src="@/assets/img/empty.png" /> <img src="@/assets/img/empty.png" />
<div>暂无数据</div> <div>暂无数据</div>
...@@ -72,8 +72,8 @@ ...@@ -72,8 +72,8 @@
</el-popover> </el-popover>
</div> </div>
<div class="summary-item-total"> <div class="summary-item-total">
<div> <div @click="handleEquityDetail(summaryTimeFomat)">1
<span>人</span> <span></span>
</div> </div>
</div> </div>
<div class="summary-radio"> <div class="summary-radio">
...@@ -102,18 +102,22 @@ ...@@ -102,18 +102,22 @@
</div> </div>
</div> </div>
<line-view></line-view> <line-view></line-view>
<equity-detail ref="equityForm"></equity-detail>
</div> </div>
</div> </div>
</template> </template>
<script> <script>
import equityDetail from './detail/equityDetail.vue'
import outputEchart from './output-echart' import outputEchart from './output-echart'
import lineView from './lineView' import lineView from './lineView'
import util from '@/utils/util'
export default { export default {
name: 'customerEchart', name: 'customerEchart',
components: { components: {
outputEchart, outputEchart,
lineView lineView,
equityDetail
}, },
data() { data() {
return { return {
...@@ -147,21 +151,12 @@ export default { ...@@ -147,21 +151,12 @@ export default {
} }
}, },
methods: { methods: {
handleEquityDetail(day) {
this.$refs.equityForm.init(day)
},
getOutput() { getOutput() {
this.$apis.home.outputValue({ dataEndDateStr: this.summaryTimeFomat }).then(res => { this.$apis.home.equityOrderStatistical({ dataStartDateStr: util.getBetweenDate(this.summaryTimeFomat, 30), dataEndDateStr: this.summaryTimeFomat, merchantId: '44184606' }).then(res => {
this.output = res this.output = res.servicePackageList
this.totalOutputValue = res.totalOutputValue
this.currentDayTotalOutputValue = res.currentDayTotalOutputValue
this.currentDayShopmallTotalOutputValue = res.currentDayShopmallTotalOutputValue
this.currentDayLiveTotalOutputValue = res.currentDayLiveTotalOutputValue
this.currentDayEquityTotalOutputValue = res.currentDayEquityTotalOutputValue
this.currentDayBoutiqueUpgradeTotalOutputValue = res.currentDayBoutiqueUpgradeTotalOutputValue
this.totalOutputValueTrends = res.totalOutputValueTrends
this.shopmallOutputValueTrends = res.shopmallOutputValueTrends
this.boutiqueUpgradeOutputValueTrends = res.boutiqueUpgradeOutputValueTrends
this.liveOutputValueTrends = res.liveOutputValueTrends
this.equityOutputValueTrends = res.equityOutputValueTrends
this.equityTotalOutputValue = res.equityTotalOutputValue
}) })
} }
}, },
...@@ -181,7 +176,7 @@ export default { ...@@ -181,7 +176,7 @@ export default {
margin-right: 20px; margin-right: 20px;
.left-header { .left-header {
height: 140px; height: 140px;
background: linear-gradient(360deg, #F7F7FF 0%, #F3F5F8 100%); background: linear-gradient(360deg, #f7f7ff 0%, #f3f5f8 100%);
} }
.view-chart { .view-chart {
width: 100%; width: 100%;
......
...@@ -2,11 +2,6 @@ ...@@ -2,11 +2,6 @@
<div class="square-main" v-loading="loading"> <div class="square-main" v-loading="loading">
<el-dialog title="客户列表" :visible.sync="dialogVisible" width="70%" :before-close="handleClose"> <el-dialog title="客户列表" :visible.sync="dialogVisible" width="70%" :before-close="handleClose">
<el-form :inline="true" :model="tableSearchForm" class="emp-form"> <el-form :inline="true" :model="tableSearchForm" class="emp-form">
<el-form-item size="small" label="列表显示规则">
<el-select v-model="tableSearchForm.status" placeholder="请选择">
<el-option v-for="item in optionsRule" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
</el-form-item>
<el-form-item size="small" label="客户名称"> <el-form-item size="small" label="客户名称">
<el-input v-model="tableSearchForm.customerName" placeholder="请输入客户名称"></el-input> <el-input v-model="tableSearchForm.customerName" placeholder="请输入客户名称"></el-input>
</el-form-item> </el-form-item>
......
<template> <template>
<div class="square-main" v-loading="loading"> <div class="square-main" v-loading="loading">
<el-dialog title="客户列表" :visible.sync="dialogVisible" width="70%" :before-close="handleClose"> <el-dialog title="当日新增群客户数" :visible.sync="dialogVisible" width="70%" :before-close="handleClose">
<el-form :inline="true" :model="tableSearchForm" class="emp-form"> <el-form :inline="true" :model="tableSearchForm" class="emp-form">
<el-form-item size="small" label="客户名称"> <el-form-item size="small" label="群主">
<el-input v-model="tableSearchForm.customerName" placeholder="请输入客户名称"></el-input> <el-input v-model="tableSearchForm.groupHostName" placeholder="请输入客户名称"></el-input>
</el-form-item> </el-form-item>
<el-form-item size="small" label="状态" v-if="!pStatus"> <el-form-item size="small" label="群聊昵称" v-if="!pStatus">
<el-select v-model="tableSearchForm.status" placeholder="请选择"> <el-input v-model="tableSearchForm.custGroupName" placeholder="请输入客户名称"></el-input>
<el-option v-for="item in optionstatus" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
</el-form-item> </el-form-item>
<el-form-item size="small" label="跟进员工" v-if="!staffIds"> <el-form-item size="small" label="管理员" v-if="!pStatus">
<el-select v-model="staffId" placeholder="请选择"> <el-input v-model="tableSearchForm.groupAdminName" placeholder="请输入客户名称"></el-input>
<el-option v-for="item in staffName" :key="item.staffId" :label="item.staffName" :value="item.staffId"></el-option>
</el-select>
</el-form-item>
<el-form-item size="small" label="添加时间" v-if="timeStatus">
<el-date-picker :picker-options="pickerOptions" value-format="yyyy-MM-dd" v-model="createTime" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
</el-form-item> </el-form-item>
<el-form-item size="small" style="float: right; margin-right: 0px"> <el-form-item size="small" style="float: right; margin-right: 0px">
<el-button type="primary" @click="handleSearch">查询</el-button> <el-button type="primary" @click="handleSearch">查询</el-button>
...@@ -77,40 +70,47 @@ export default { ...@@ -77,40 +70,47 @@ export default {
tableOption: false, tableOption: false,
tableColumns: [ tableColumns: [
{ {
label: '客户名称', label: '群聊名称',
prop: 'customerName', prop: 'custGroupName',
addHtml: 'customerName' minWidth: 160
},
{
label: '当前成员总数',
prop: 'allMembers',
minWidth: 110
}, },
{ {
label: '手机号', label: '当前客户数',
prop: 'status', prop: 'totalCount',
addHtml: 'status' minWidth: 90
}, },
{ {
label: '所属群聊名称', label: '当日新增入群客户数',
prop: 'followStaff' prop: 'newCustomerCount',
minWidth: 150
}, },
{ {
label: '邀请人', label: '当日新增退群客户数',
prop: 'addTime' prop: 'delCustomerCount',
minWidth: 150
}, },
{ {
label: '创建方式', label: '当前跟进员工数',
prop: 'addTime' prop: 'staffs',
minWidth: 130
}, },
{ {
label: '群主', label: '群主',
prop: 'addTime' prop: 'groupHostName'
}, },
{ {
label: '入群时间', label: '管理员',
prop: 'addTime' prop: 'groupAdminName'
}, },
{ {
label: '操作', label: '创建时间',
prop: 'optionBtns', prop: 'addTime',
width: '80px', width: 140
addHtml: 'optionBtns'
} }
] ]
}, },
...@@ -122,7 +122,9 @@ export default { ...@@ -122,7 +122,9 @@ export default {
selectEmp: [], selectEmp: [],
pStatus: null, pStatus: null,
staffIds: null, staffIds: null,
staffId: null staffId: null,
endTime: null,
beginTime: null
} }
}, },
methods: { methods: {
...@@ -133,7 +135,9 @@ export default { ...@@ -133,7 +135,9 @@ export default {
var params = { var params = {
...JSON.parse(JSON.stringify(this.tableSearchForm)), ...JSON.parse(JSON.stringify(this.tableSearchForm)),
pageSize: this.$refs.tableEmp.page.pageSize, pageSize: this.$refs.tableEmp.page.pageSize,
pageNum: this.$refs.tableEmp.page.pageNum pageNum: this.$refs.tableEmp.page.pageNum,
beginTime: this.beginTime,
endTime: this.endTime
} }
this.loading = true this.loading = true
this.$apis.home.customerCustPage(params).then(res => { this.$apis.home.customerCustPage(params).then(res => {
...@@ -142,7 +146,10 @@ export default { ...@@ -142,7 +146,10 @@ export default {
this.tableTotal = res.count this.tableTotal = res.count
}) })
}, },
init() { init(day) {
console.log(day)
this.beginTime = day
this.endTime = day
this.dialogVisible = true this.dialogVisible = true
this.$nextTick(() => { this.$nextTick(() => {
this.$refs.tableEmp.page.pageNum = 1 this.$refs.tableEmp.page.pageNum = 1
...@@ -155,10 +162,8 @@ export default { ...@@ -155,10 +162,8 @@ export default {
handleExport() { handleExport() {
var params = { var params = {
...JSON.parse(JSON.stringify(this.tableSearchForm)), ...JSON.parse(JSON.stringify(this.tableSearchForm)),
isJoin: this.isJoin,
beginTime: this.beginTime, beginTime: this.beginTime,
endTime: this.endTime, endTime: this.endTime
deleteTime: this.deleteTime
} }
this.$apis.home.customerBaseCustListExport(params).then(res => { this.$apis.home.customerBaseCustListExport(params).then(res => {
util.openUrl(res) util.openUrl(res)
......
<template> <template>
<div class="square-main" v-loading="loading"> <div class="square-main" v-loading="loading">
<el-dialog title="客户列表" :visible.sync="dialogVisible" width="70%" :before-close="handleClose"> <el-dialog title="当日新增门店服务套餐" :visible.sync="dialogVisible" width="70%" :before-close="handleClose">
<el-form :inline="true" :model="tableSearchForm" class="emp-form"> <el-form :inline="true" :model="tableSearchForm" class="emp-form">
<el-form-item size="small" label="客户名称">
<el-input v-model="tableSearchForm.customerName" placeholder="请输入客户名称"></el-input>
</el-form-item>
<el-form-item size="small" label="状态" v-if="!pStatus">
<el-select v-model="tableSearchForm.status" placeholder="请选择">
<el-option v-for="item in optionstatus" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
</el-form-item>
<el-form-item size="small" label="跟进员工" v-if="!staffIds">
<el-select v-model="staffId" placeholder="请选择">
<el-option v-for="item in staffName" :key="item.staffId" :label="item.staffName" :value="item.staffId"></el-option>
</el-select>
</el-form-item>
<el-form-item size="small" label="添加时间" v-if="timeStatus">
<el-date-picker :picker-options="pickerOptions" value-format="yyyy-MM-dd" v-model="createTime" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
</el-form-item>
<el-form-item size="small" style="float: right; margin-right: 0px"> <el-form-item size="small" style="float: right; margin-right: 0px">
<el-button type="primary" @click="handleSearch">查询</el-button> <el-button type="primary" @click="handleExport">导出</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
<GLTable v-loading="loading" ref="tableEmp" :layout="layout" :tableData="tableData" :tableTotal="tableTotal" :pageConf="pageConf" :tableParams="tableParams" @refreshTable="handleSearch" @selectionTable="selectionTable"> <GLTable v-loading="loading" ref="tableEmp" :layout="layout" :tableData="tableData" :tableTotal="tableTotal" :pageConf="pageConf" :tableParams="tableParams" @refreshTable="handleSearch" @selectionTable="selectionTable">
...@@ -135,7 +119,9 @@ export default { ...@@ -135,7 +119,9 @@ export default {
selectEmp: [], selectEmp: [],
pStatus: null, pStatus: null,
staffIds: null, staffIds: null,
staffId: null staffId: null,
startTime: null,
endTime: null
} }
}, },
methods: { methods: {
...@@ -146,22 +132,39 @@ export default { ...@@ -146,22 +132,39 @@ export default {
var params = { var params = {
...JSON.parse(JSON.stringify(this.tableSearchForm)), ...JSON.parse(JSON.stringify(this.tableSearchForm)),
pageSize: this.$refs.tableEmp.page.pageSize, pageSize: this.$refs.tableEmp.page.pageSize,
pageNum: this.$refs.tableEmp.page.pageNum pageNum: this.$refs.tableEmp.page.pageNum,
merchantId: this.$globalState.session.merchantId,
startTime: this.startTime + ' 00:00:00',
endTime: this.endTime + ' 23:59:59'
} }
this.loading = true this.loading = true
this.$apis.home.getCustomer(params).then(res => { this.$apis.home.equityInfo(params).then(res => {
this.loading = false this.loading = false
this.tableData = res.data this.tableData = res.data
this.tableTotal = res.count this.tableTotal = res.count
}) })
}, },
init() { init(day) {
this.startTime = day
this.endTime = day
this.dialogVisible = true this.dialogVisible = true
this.$nextTick(() => { this.$nextTick(() => {
this.$refs.tableEmp.page.pageNum = 1 this.$refs.tableEmp.page.pageNum = 1
this.getFollower() this.getFollower()
}) })
}, },
//导出
handleExport() {
var params = {
...JSON.parse(JSON.stringify(this.tableSearchForm)),
merchantId: this.$globalState.session.merchantId,
startTime: this.startTime + ' 00:00:00',
endTime: this.endTime + ' 23:59:59'
}
this.$apis.home.equityExport(params).then(res => {
// util.openUrl(res)
})
},
handleSearch() { handleSearch() {
this.getFollower() this.getFollower()
}, },
......
...@@ -67,66 +67,130 @@ export default { ...@@ -67,66 +67,130 @@ export default {
tableOption: false, tableOption: false,
tableColumns: [ tableColumns: [
{ {
value: 'orderCode',
label: '主订单编号',
level: 1,
width: '200',
disabled: true
},
{
value: 'tradeNo',
label: '交易参考号',
level: 1,
width: '200',
disabled: true
},
{
value: 'subOrderCode',
label: '子订单编号',
level: 1,
width: '200',
disabled: true
},
{
value: 'upgradeGoodsName',
label: '商品名称', label: '商品名称',
prop: 'goodsName', level: 1,
line: 2 width: '200',
disabled: false
}, },
{ {
label: '缩略图', value: 'upgradeGoodsCommodityCode',
prop: 'goodsImage', label: '商品编号',
addHtml: 'goodsImage' level: 1,
width: '200',
disabled: false
}, },
{ {
label: '浏览量(次)', value: 'goodsCost',
name: 'goodsStatistics', label: '商品成本',
width: '180', level: 1,
formatter: cellValue => { width: '110',
return cellValue.goodsStatistics ? cellValue.goodsStatistics.viewAmount || '0' : '0' disabled: false
}
}, },
{ {
label: '销量', value: 'customerName',
name: 'goodsStatistics', label: '客户姓名',
formatter: cellValue => { level: 1,
return cellValue.goodsStatistics ? cellValue.goodsStatistics.saleAmount || '0' : '0' width: '110',
} disabled: false
}, },
{ {
label: '零售价(元)', value: 'customerPhone',
name: 'retailPrice', label: '客户手机号',
width: '180', level: 2,
formatter: cellValue => { width: '110',
return cellValue.retailPrice disabled: false
}
}, },
{ {
label: '库存', value: 'sellerName',
name: 'goodsStock', label: '转化员姓名',
formatter: cellValue => { level: 2,
return cellValue.goodsStock || '0' width: '110',
} disabled: false
},
{
value: 'employeeName',
label: '销售顾问',
level: 2,
width: '110',
disabled: false
},
{
value: 'paySuccessDate',
label: '支付时间',
level: 2,
width: '160',
disabled: false
},
{
value: 'payTypeName',
label: '支付方式',
level: 3,
width: '110',
disabled: false
},
{
value: 'subTotalPrice',
label: '支付金额',
level: 3,
width: '110',
disabled: true
},
{
value: 'actualIncomeMoney',
label: '总分账金额',
level: 3,
width: '110',
disabled: true
},
{
value: 'shopMerchantName',
label: '分账对象',
level: 3,
width: '110',
disabled: false
}, },
{ {
label: '创建日期', value: 'rule',
prop: 'createdDate', label: '分账规则',
width: '180', level: 3,
// formatter: cellValue => { width: '80',
// return dayjs(cellValue.createdDate).format('YYYY-MM-DD HH:mm:ss') disabled: false
// }
}, },
{ {
label: '商品状态', value: 'shopProfitMoney',
name: 'goodsStatus', label: '分账金额',
// formatter: cellValue => { level: 3,
// return this.baseData.goodsStatusList.find(item => item.confId == cellValue.goodsStatus).confName width: '110',
// } disabled: true
}, },
{ {
label: '带货来源', value: 'divisionTypeName',
name: 'goodsSource', label: '分账类型',
// formatter: cellValue => { level: 3,
// return this.baseData.goodsSourceList.find(item => item.confId == cellValue.goodsSource).confName width: '110',
// } disabled: false
} }
] ]
}, },
......
...@@ -26,10 +26,10 @@ export default { ...@@ -26,10 +26,10 @@ export default {
handler(value) { handler(value) {
console.log(value) console.log(value)
let data = value.map(item => { let data = value.map(item => {
return item.outputValue return item.billNum
}) })
let dateTime = value.map(item => { let dateTime = value.map(item => {
return item.dateTime return item.timeStr
}) })
this.status = data.some(item=>item) this.status = data.some(item=>item)
this.getChartTotal(dateTime, data) this.getChartTotal(dateTime, data)
...@@ -46,7 +46,7 @@ export default { ...@@ -46,7 +46,7 @@ export default {
option = { option = {
xAxis: { xAxis: {
type: 'category', type: 'category',
data: [1,2,3,4,5,6,7] data: dateTime
}, },
yAxis: { yAxis: {
type: 'value' type: 'value'
...@@ -59,7 +59,7 @@ export default { ...@@ -59,7 +59,7 @@ export default {
}, },
series: [ series: [
{ {
data: [1,2,3,5,6,7,8,9], data: lineData,
type: 'line', type: 'line',
symbol: 'none', symbol: 'none',
color: '#5850FF', color: '#5850FF',
......
...@@ -23,7 +23,7 @@ export default { ...@@ -23,7 +23,7 @@ export default {
lineType: { lineType: {
type: String, type: String,
default: '' default: ''
}, }
}, },
watch: { watch: {
outputCircle: { outputCircle: {
...@@ -118,6 +118,19 @@ export default { ...@@ -118,6 +118,19 @@ export default {
}) })
}, },
getEquity() { getEquity() {
const packageName = this.outputCircle.map(item => {
return {
name: item.packageName
}
})
const packageData = this.outputCircle.map(item => {
return {
value: item.billNumRate,
name: item.packageName,
unit: '%',
ratio: item.billNum
}
})
var chartDom = document.getElementById(this.echartId) var chartDom = document.getElementById(this.echartId)
var myChart = echarts.init(chartDom) var myChart = echarts.init(chartDom)
var option var option
...@@ -135,20 +148,7 @@ export default { ...@@ -135,20 +148,7 @@ export default {
icon: 'stack', icon: 'stack',
itemHeight: 2, itemHeight: 2,
itemWidth: 12, itemWidth: 12,
data: [ data: packageName
{
name: '全损无忧'
},
{
name: '轮胎'
},
{
name: '碰撞'
},
{
name: '其他'
}
]
}, },
color: ['#5850FF', '#64C0A2', '#FACD67', '#F7A7B3', '#34911A'], color: ['#5850FF', '#64C0A2', '#FACD67', '#F7A7B3', '#34911A'],
series: [ series: [
...@@ -157,12 +157,7 @@ export default { ...@@ -157,12 +157,7 @@ export default {
type: 'pie', type: 'pie',
center: ['50%', '53%'], center: ['50%', '53%'],
radius: ['40%', '70%'], radius: ['40%', '70%'],
data: [ data: packageData,
{ value: this.outputCircle.shopmallTotalOutputValueRadio, name: '全损无忧', unit: '%', ratio: this.outputCircle.shopmallTotalOutputValue },
{ value: this.outputCircle.equityTotalOutputValueRadio, name: '轮胎', unit: '%', ratio: this.outputCircle.equityTotalOutputValue },
{ value: this.outputCircle.boutiqueUpgradeTotalOutputValueRadio, name: '碰撞', unit: '%', ratio: this.outputCircle.boutiqueUpgradeTotalOutputValue },
{ value: this.outputCircle.otherTotalOutputValueRadio, name: '其他', unit: '%', ratio: this.outputCircle.otherTotalOutputValue }
],
itemStyle: { itemStyle: {
normal: { normal: {
label: { label: {
......
...@@ -6,14 +6,14 @@ ...@@ -6,14 +6,14 @@
<div class="home-statistics-title"> <div class="home-statistics-title">
客户概览 客户概览
<span class="home-title-radio">企微客户占比</span> <span class="home-title-radio">企微客户占比</span>
<span class="home-title-radio" style="color: #5850ff">80%</span> <span class="home-title-radio" style="color: #5850ff">{{entmicroCountRadio}}%</span>
</div> </div>
<div class="summary-time"> <div class="summary-time">
<span>统计截止至</span> <span>统计截止至</span>
<el-date-picker size="small" value-format="yyyy-MM-dd" v-model="summaryTime" type="date" placeholder="选择日期" :clearable="false" :picker-options="pickerOptions"></el-date-picker> <el-date-picker size="small" value-format="yyyy-MM-dd" v-model="summaryTime" type="date" placeholder="选择日期" :clearable="false" :picker-options="pickerOptions"></el-date-picker>
</div> </div>
</div> </div>
<overview-enterprise :summaryTime="summaryTime"></overview-enterprise> <overview-enterprise :summaryTime="summaryTime" @getEntmicroRadio="getEntmicroRadio"></overview-enterprise>
<div class="home-statistics-title">产值概览</div> <div class="home-statistics-title">产值概览</div>
<customer-echart :summaryTimeFomat="summaryTime"></customer-echart> <customer-echart :summaryTimeFomat="summaryTime"></customer-echart>
<div class="home-overview-content"></div> <div class="home-overview-content"></div>
...@@ -55,6 +55,7 @@ export default { ...@@ -55,6 +55,7 @@ export default {
return time.getTime() > Date.now() return time.getTime() > Date.now()
} }
}, },
entmicroCountRadio: 0,
guideStatus: false, guideStatus: false,
step: 1, step: 1,
headHeight: 0, headHeight: 0,
...@@ -73,78 +74,13 @@ export default { ...@@ -73,78 +74,13 @@ export default {
jumpSqure() { jumpSqure() {
this.$history.push('/drainage/square/index') this.$history.push('/drainage/square/index')
}, },
handleNext(val) { getEntmicroRadio(value) {
if (val == 3) { this.entmicroCountRadio = value
this.guideStatus = false
document.documentElement.scrollTop = 0
document.body.parentNode.style.overflowY = 'auto'
} else {
this.step++
this.getRezie()
}
},
getRezie() {
this.borderLeft = document.querySelector('.el-main').offsetLeft + 38
this.borderTop = document.querySelector('.el-main').offsetTop
if (this.step == 1) {
this.guideWidth = document.querySelector('.header-panel').offsetWidth + 5
this.guideHeight = this.headHeight
this.imgWidth = this.guideWidth / 2
this.imgHeight = (this.imgWidth * 246) / 541
this.guideLeft = this.borderLeft
this.guideTop = document.querySelector('.header-panel').offsetTop + this.borderTop - 2
} else if (this.step == 2) {
setTimeout(() => {
document.querySelectorAll('.nav-text')[1].querySelector('.el-popover__reference').click()
this.$nextTick(() => {
const contactEl = document.querySelector('.com-nav-contact').parentNode
const cloneEl = contactEl.cloneNode(true)
cloneEl.style.opacity = 1
document.body.appendChild(cloneEl)
this.guideWidth = cloneEl.offsetWidth
this.guideHeight = cloneEl.offsetHeight
this.imgHeight = this.guideHeight / 2
this.imgWidth = (this.imgHeight * 759) / 128
this.guideLeft = cloneEl.offsetLeft - 2
this.guideTop = cloneEl.offsetTop
})
}, 10)
} else {
const contactEl = document.querySelectorAll('.com-nav-contact')[1].parentNode
document.body.removeChild(contactEl)
let domWrapper = document.querySelector('.main-panel')
let top = domWrapper.scrollHeight - domWrapper.offsetHeight - 150
this.guideLeft = document.querySelector('.operational-panel-s').offsetLeft + this.borderLeft - 40
this.guideTop = document.querySelector('.operational-panel-s').offsetTop - top - 10 + this.borderTop
this.guideWidth = document.querySelector('.operational-panel-s').offsetWidth + 5
this.guideHeight = document.querySelector('.operational-panel-s').offsetHeight + 10
document.querySelector('.main-panel').scrollTop = top
this.imgWidth = this.guideWidth / 1.5
this.imgHeight = (this.imgWidth * 222) / 668
}
}, },
findLogin() {
this.$apis.home.findLoginCount({ loginType: 1 }).then(res => {
if (res) {
this.guideStatus = true
this.getRezie()
}
})
}
}, },
mounted() { mounted() {
this.headHeight = document.querySelector('.header-panel').offsetWidth / 8
this.headWidth = document.querySelector('.header-panel').offsetWidth
window.addEventListener('resize', () => {
this.headHeight = document.querySelector('.header-panel').offsetWidth / 8
this.headWidth = document.querySelector('.header-panel').offsetWidth
})
// this.findLogin()
}, },
beforeDestroy() {
window.removeEventListener('resize')
}
} }
</script> </script>
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!