Commit 0add10fa authored by 华国豪's avatar 华国豪 🙄

客户地图

parent cb137e85
......@@ -7,6 +7,11 @@
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<meta name="renderer" content="webkit">
<link rel="icon" href="<%= BASE_URL %>favicon.ico">
<script type="text/javascript" src="http://api.map.baidu.com/api?v=3.0&ak=L5Qw0GlbbCIMwgR4Uug3ogM40Imkd3CV" ></script>
<script type="text/javascript" src="http://api.map.baidu.com/library/TextIconOverlay/1.2/src/TextIconOverlay_min.js"></script>
<!-- <script type="text/javascript" src="http://api.map.baidu.com/library/MarkerClusterer/1.2/src/MarkerClusterer_min.js"></script> -->
<script type="text/javascript" src="./static/MarkerClusterer.js"></script>
<script type="text/javascript" src="./static/CurveLine.min.js"></script>
<title>CRM</title>
</head>
......
......@@ -30,7 +30,7 @@ export default {
@import './assets/css/tablevoerride.css';
@import './assets/global/font.css';
@import '//at.alicdn.com/t/font_1627123_udqp6oxn9ki.css';
@import '//at.alicdn.com/t/font_1627123_m34imq176cf.css';
@import url('//at.alicdn.com/t/font_1627123_grz80mbm3sv.css');
/* @import './assets/css/common.css'; */
@import './assets/css/init.css';
......
......@@ -44,9 +44,10 @@
<div class="vux-flexbox handle-button vux-flex-row" @click="MsgBus.$emit('sceneBoxShow', 3, 1)">
<i class="el-icon-circle-plus-outline handle-button-icon"></i>
<div class="handle-button-name">新建场景</div></div>
<!-- <div class="vux-flexbox handle-button vux-flex-row">
<div class="vux-flexbox handle-button vux-flex-row" @click="MsgBus.$emit('sceneEditBoxShow', 3, SceneEmployeeList)">
<i class="el-icon-setting handle-button-icon"></i>
<div class="handle-button-name">管理</div></div> -->
<div class="handle-button-name">管理</div>
</div>
</div>
</div>
<el-select size="mini" popper-class="select-no" slot="reference" v-model="msg.ID" placeholder="请选择">
......@@ -481,8 +482,13 @@ export default {
$this.msg.Data = obj
$this.getList()
})
this.MsgBus.$on('editScene', function (){
console.log(1)
$this.GetSceneEmployeeList()
})
},beforeDestroy() {
this.MsgBus.$off('sceneSave');
this.MsgBus.$off('editScene');
},
methods: {
changeWhere(item){
......
......@@ -75,9 +75,10 @@
<div class="vux-flexbox handle-button vux-flex-row" @click="MsgBus.$emit('sceneBoxShow', 4, 1)">
<i class="el-icon-circle-plus-outline handle-button-icon"></i>
<div class="handle-button-name">新建场景</div></div>
<!-- <div class="vux-flexbox handle-button vux-flex-row">
<i class="el-icon-setting handle-button-icon"></i>
<div class="handle-button-name">管理</div></div> -->
<div class="vux-flexbox handle-button vux-flex-row" @click="MsgBus.$emit('sceneEditBoxShow', 4, SceneEmployeeList)">
<i class="el-icon-setting handle-button-icon"></i>
<div class="handle-button-name">管理</div>
</div>
</div>
</div>
<el-select size="mini" popper-class="select-no" slot="reference" v-model="msg.ID" placeholder="请选择">
......@@ -456,17 +457,17 @@ export default {
visible: false,
};
},
mounted() {
this.userInfo = this.getLocalStorage();
this.getList()
this.Employee()
let $this = this
this.MsgBus.$on('closeCustomerDialogBox', function (){
$this.dialogTableVisible = false
$this.guestDialogBoxShow = false
})
this.GetSceneEmployeeList()
this.MsgBus.$on('sceneSave', function (msg){
mounted() {
this.userInfo = this.getLocalStorage();
this.getList()
this.Employee()
let $this = this
this.MsgBus.$on('closeCustomerDialogBox', function (){
$this.dialogTableVisible = false
$this.guestDialogBoxShow = false
})
this.GetSceneEmployeeList()
this.MsgBus.$on('sceneSave', function (msg){
$this.sceneList = [...msg]
$this.GetSceneEmployeeList()
let obj = {}
......@@ -476,8 +477,12 @@ export default {
$this.msg.Data = obj
$this.getList()
})
this.MsgBus.$on('editScene', function (){
$this.GetSceneEmployeeList()
})
},beforeDestroy() {
this.MsgBus.$off('sceneSave');
this.MsgBus.$off('editScene');
},
methods: {
changeWhere(item){
......
......@@ -44,9 +44,10 @@
<div class="vux-flexbox handle-button vux-flex-row" @click="MsgBus.$emit('sceneBoxShow', 2, 1)">
<i class="el-icon-circle-plus-outline handle-button-icon"></i>
<div class="handle-button-name">新建场景</div></div>
<!-- <div class="vux-flexbox handle-button vux-flex-row">
<div class="vux-flexbox handle-button vux-flex-row" @click="MsgBus.$emit('sceneEditBoxShow', 2, SceneEmployeeList)">
<i class="el-icon-setting handle-button-icon"></i>
<div class="handle-button-name">管理</div></div> -->
<div class="handle-button-name">管理</div>
</div>
</div>
</div>
<el-select size="mini" popper-class="select-no" slot="reference" v-model="msg.ID" placeholder="请选择">
......@@ -446,8 +447,12 @@ export default {
$this.msg.Data = obj
$this.getList()
})
this.MsgBus.$on('editScene', function (){
$this.GetSceneEmployeeList()
})
},beforeDestroy() {
this.MsgBus.$off('sceneSave');
this.MsgBus.$off('editScene');
},
methods: {
changeWhere(item){
......
......@@ -144,9 +144,10 @@
<div class="vux-flexbox handle-button vux-flex-row" @click="MsgBus.$emit('sceneBoxShow', 1, 1)">
<i class="el-icon-circle-plus-outline handle-button-icon"></i>
<div class="handle-button-name">新建场景</div></div>
<!-- <div class="vux-flexbox handle-button vux-flex-row">
<div class="vux-flexbox handle-button vux-flex-row" @click="MsgBus.$emit('sceneEditBoxShow', 1, SceneEmployeeList)">
<i class="el-icon-setting handle-button-icon"></i>
<div class="handle-button-name">管理</div></div> -->
<div class="handle-button-name">管理</div>
</div>
</div>
</div>
<el-select size="mini" popper-class="select-no" slot="reference" v-model="msg.ID" placeholder="请选择">
......@@ -709,8 +710,12 @@ export default {
$this.msg.Data = obj
$this.getList()
})
this.MsgBus.$on('editScene', function (){
$this.GetSceneEmployeeList()
})
},beforeDestroy() {
this.MsgBus.$off('sceneSave');
this.MsgBus.$off('editScene');
},
methods: {
changeWhere(item){
......
......@@ -97,7 +97,7 @@
</template>
<script>
export default {
props: ['LableType', 'sceneType'],
props: ['LableType', 'sceneType', 'sceneDataList'],
data(){
return{
checked: false,
......@@ -281,6 +281,30 @@ export default {
]
},
deep:true
},
sceneDataList: {
handler(val, oldVal){
this.GetSceneList()
this.dataList = [
{
SceneName: '',
IsDefault: '',
region: '',
regionS: [],
sceneList: [],
SceneIndex: '',
Setting: [],
time: [],
WhereDataStr: {},
formType: ''
}
]
this.sceneMsg = {
SceneName: '',
IsDefault: 0,
}
},
deep:true
}
},
mounted(){
......@@ -289,6 +313,37 @@ export default {
this.Employee()
},
methods:{
// 修改组装数据
sceneInitDataList(){
this.dataList = []
let item = JSON.parse(this.sceneDataList.WhereData)
let i = 0
var arr = []
for (let i in item) {
arr.push(item[i])
}
arr.map((x, index)=>{
console.log(x)
this.sceneList.map((s, sIndex)=>{
if(x.name === s.FieldName) {
let msg = {
SceneName: x.value,
IsDefault: '',
region: x.condition,
regionS: [],
sceneList: this.sceneList,
SceneIndex: sIndex,
Setting: s.Setting,
time: [x.start, x.end],
WhereDataStr: {},
formType: s.FormType
}
this.dataList.push(msg)
this.changeScene(this.dataList[index], index, 2)
}
})
})
},
changeFC(index){
for(let i = 0; i < this.EmployeeList.length; i++){
if (this.EmployeeList[i].EmployeeId === this.dataList[index].id){
......@@ -355,16 +410,40 @@ export default {
}
this.sceneMsg.WhereDataStr = msg
this.sceneMsg.LableType = this.LableType
if(this.sceneDataList) {
this.sceneMsg.ID = this.sceneDataList.ID
}
this.apipost('/api/Scene/AddSceneEmployee', this.sceneMsg, res=>{
if (res.data.resultCode == 1) {
this.$message.success('操作成功')
this.MsgBus.$emit('editScene')
this.dataList = [
{
SceneName: '',
IsDefault: '',
region: '',
regionS: [],
sceneList: this.sceneList,
SceneIndex: '',
Setting: [],
time: [],
WhereDataStr: {},
formType: ''
}
]
this.checked = false
}
})
}
setTimeout(()=>{
if(this.sceneDataList && ok) {
this.MsgBus.$emit('sceneBoxClose')
this.MsgBus.$emit('sceneSave', list)
}, 500)
} else if (ok){
setTimeout(()=>{
this.MsgBus.$emit('sceneBoxClose')
this.MsgBus.$emit('sceneSave', list)
}, 500)
}
},
changeRegion(i, index){
this.optionsNames.map(x=>{
......@@ -374,15 +453,18 @@ export default {
})
},
changeScene(item, pIndex){
changeScene(item, pIndex, type){
this.dataList[pIndex].regionS = this.dataList[pIndex].sceneList[item.SceneIndex].region
this.dataList[pIndex].nameStr = this.dataList[pIndex].sceneList[item.SceneIndex].Name
this.dataList[pIndex].formType = this.dataList[pIndex].sceneList[item.SceneIndex].FormType
this.dataList[pIndex].region = ''
this.dataList[pIndex].region = type ? this.dataList[pIndex].region : ''
this.dataList[pIndex].FieldName = this.dataList[pIndex].sceneList[item.SceneIndex].FieldName
this.dataList[pIndex].SceneName = ''
this.dataList[pIndex].time = []
this.dataList[pIndex].SceneName = type ? this.dataList[pIndex].SceneName : ''
this.dataList[pIndex].time = type && this.dataList[pIndex].formType === 'datetime' ? this.dataList[pIndex].time : []
this.region = this.sceneList[item.SceneIndex].region
if(this.dataList[pIndex].nameStr && type) {
this.dataList[pIndex].id = this.dataList[pIndex].SceneName
}
if(this.dataList[pIndex].sceneList[item.SceneIndex].FormType === 'select') {
this.dataList[pIndex].Setting = this.dataList[pIndex].sceneList[item.SceneIndex].Setting
} else {
......@@ -431,7 +513,13 @@ export default {
}
})
this.sceneList = arr
this.dataList[0].sceneList = arr
if (this.sceneDataList){
this.sceneInitDataList()
this.sceneMsg.SceneName = this.sceneDataList.SceneName
this.sceneMsg.IsDefault = this.sceneDataList.IsDefault
} else {
this.dataList[0].sceneList = arr
}
}
})
},
......
......@@ -46,9 +46,10 @@
<div class="vux-flexbox handle-button vux-flex-row" @click="MsgBus.$emit('sceneBoxShow', 5, 1)">
<i class="el-icon-circle-plus-outline handle-button-icon"></i>
<div class="handle-button-name">新建场景</div></div>
<!-- <div class="vux-flexbox handle-button vux-flex-row">
<div class="vux-flexbox handle-button vux-flex-row" @click="MsgBus.$emit('sceneEditBoxShow', 5, SceneEmployeeList)">
<i class="el-icon-setting handle-button-icon"></i>
<div class="handle-button-name">管理</div></div> -->
<div class="handle-button-name">管理</div>
</div>
</div>
</div>
<el-select size="mini" popper-class="select-no" slot="reference" v-model="msg.ID" placeholder="请选择">
......@@ -653,8 +654,13 @@ export default {
$this.msg.Data = obj
$this.getList()
})
this.MsgBus.$on('editScene', function (){
console.log(1)
$this.GetSceneEmployeeList()
})
},beforeDestroy() {
this.MsgBus.$off('sceneSave');
this.MsgBus.$off('editScene');
},
methods: {
changeWhere(item){
......
......@@ -13,6 +13,8 @@ import waitMatter from "./components/waitMatter/waitMatter"
import datasheet from './components/datasheet/index'
import contractManagement from "./components/contractManagement/contractManagement"
import guestManagement from "./components/guestManagement/guestManagement"
import customerApr from "./components/approval/customerApr"
import customerMap from "./components/customerManage/customerMap"
Vue.use(Router);
export default new Router({
......@@ -184,6 +186,22 @@ export default new Router({
meta: {
title: "直客管理"
}
},
{
path: "/customerApr",
name: "customerApr",
component: customerApr,
meta: {
title: "客户审批"
}
},
{
path: "/customerMap",
name: "customerMap",
component: customerMap,
meta: {
title: "客户地图"
}
}
]
},
......
......@@ -68,6 +68,9 @@
.add-scene .el-dialog__body{
padding-top: 20px;
}
.add-scene2 .el-dialog__body{
padding-bottom: 20px;
}
</style>
<template>
<div class="main">
......@@ -176,7 +179,15 @@
<p><span></span>新建场景</p>
<span icon="el-icon-close"></span>
</div>
<sceneBox :LableType="LableType" :sceneType="sceneType"/>
<sceneBox :LableType="LableType" :sceneType="sceneType" :sceneDataList="sceneDataList"/>
</el-dialog>
<!-- 高级筛选修改 -->
<el-dialog :visible.sync="sceneEditBoxShow" :close-on-click-modal="false" width="800px" custom-class="transfer-box add-box add-box2 add-scene add-scene2">
<div class="add-tit" slot="title">
<p><span></span>场景管理</p>
<span icon="el-icon-close"></span>
</div>
<sceneEditBox :LableType="LableType" :sceneData="sceneData" />
</el-dialog>
</div>
</template>
......@@ -196,8 +207,9 @@ import TravelContractView from '../components/contractManagement/TravelContractV
import contractInfoBox from '../components/contractManagement/contractInfoBox'
import businessInfoBox from "../components/businessManagement/businessInfoBox";
import sceneBox from "../components/dialogModel/sceneBox"
import sceneEditBox from "../components/dialogModel/sceneEditBox"
export default {
components: {HomeNavLeft, HomeNavTop, addBusinessBox, customerDialogBox, customerInfoBox, clueBox, clueDialogBox, ElImageViewer, domesticTravelcontract, onedayTripContract, singleContract, TravelContractView, contractInfoBox, businessInfoBox, sceneBox},
components: {HomeNavLeft, HomeNavTop, addBusinessBox, customerDialogBox, customerInfoBox, clueBox, clueDialogBox, ElImageViewer, domesticTravelcontract, onedayTripContract, singleContract, TravelContractView, contractInfoBox, businessInfoBox, sceneBox, sceneEditBox},
data () {
return {
sceneType: 0,
......@@ -237,7 +249,12 @@ export default {
singleContractShow: false,
onedayTripContractShow: false,
TravelContractViewShow: false,
isGuest: false
isGuest: false,
sceneData: [],
sceneEditBoxShow: false,
sceneDataList: [],
SceneName: '',
SceneID: 0,
}
},
mounted () {
......@@ -312,14 +329,23 @@ export default {
$this.BusinessId = ID
$this.BusinessIdCustomerId = BusinessIdCustomerId
})
this.MsgBus.$on('sceneBoxShow', function (type, sceneType){
this.MsgBus.$on('sceneBoxShow', function (type, sceneType, sceneDataList){
$this.LableType = type
$this.sceneType = sceneType
$this.sceneDataList = sceneDataList
$this.sceneShow = true
})
this.MsgBus.$on('sceneBoxClose', function (){
$this.sceneShow = false
})
this.MsgBus.$on('sceneEditBoxShow', function (type, data){
$this.LableType = type
$this.sceneData = data
$this.sceneEditBoxShow = true
})
this.MsgBus.$on('ssceneEditBoxClose', function (){
$this.sceneEditBoxShow = false
})
},
methods: {
sceneAdd(){
......@@ -365,7 +391,6 @@ export default {
// 转移
busTransfer(type){
if (type !== 2) {
console.log(typeof type)
if (type === 3) {
this.multipleSelection.push(this.CustomerId)
}
......@@ -572,7 +597,6 @@ export default {
}
})
}
console.log('转移')
},
// 转移
transfer(type){
......
......@@ -128,7 +128,8 @@ export default {
var msg = {
EmAccount: this.account,
EmPassword: this.pwd,
Domain: 'fcrmyx.oytour.com'
Domain:'testerp.oytour.com'
// Domain: 'crmyx.oytour.com'
};
this.apipost('/api/Login/UserLogin', msg, res=>{
var jsonData = res.data;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment