|
@@ -41,7 +41,7 @@ export default {
|
|
floorid: '', //楼层id
|
|
floorid: '', //楼层id
|
|
topologyParser: null, // 解析器数据
|
|
topologyParser: null, // 解析器数据
|
|
fParser: null, // 底图解析器
|
|
fParser: null, // 底图解析器
|
|
- wellMap: {}, // 电井控制商铺映射
|
|
|
|
|
|
+ wellMap: {} // 电井控制商铺映射
|
|
}
|
|
}
|
|
},
|
|
},
|
|
props: {
|
|
props: {
|
|
@@ -204,14 +204,15 @@ export default {
|
|
let selectItem1 = ev[0][0],
|
|
let selectItem1 = ev[0][0],
|
|
name = selectItem1.data.Name,
|
|
name = selectItem1.data.Name,
|
|
location = selectItem1.data.AttachObjectIds[0] ? selectItem1.data.AttachObjectIds[0].id : ''
|
|
location = selectItem1.data.AttachObjectIds[0] ? selectItem1.data.AttachObjectIds[0].id : ''
|
|
- if (!location) {
|
|
|
|
- this.$message('未添加位置类型')
|
|
|
|
- }
|
|
|
|
- if (name.slice(name.length - 2, name.length) == '机房' && location) {
|
|
|
|
- this.$refs.boxRoom.open({ name: name, type: this.type, location: location })
|
|
|
|
|
|
+ if (name.slice(name.length - 2, name.length) == '机房') {
|
|
|
|
+ if (location) {
|
|
|
|
+ this.$refs.boxRoom.open({ name: name, type: this.type, location: location })
|
|
|
|
+ } else {
|
|
|
|
+ this.$message('未添加位置类型')
|
|
|
|
+ }
|
|
}
|
|
}
|
|
// 选中电井设置电井关联的商铺高亮
|
|
// 选中电井设置电井关联的商铺高亮
|
|
- this.setHightLight(ev[0]);
|
|
|
|
|
|
+ this.setHightLight(ev[0])
|
|
} else {
|
|
} else {
|
|
this.clearHightLight()
|
|
this.clearHightLight()
|
|
}
|
|
}
|
|
@@ -223,10 +224,10 @@ export default {
|
|
let location = item.data.AttachObjectIds[0] ? item.data.AttachObjectIds[0].id : ''
|
|
let location = item.data.AttachObjectIds[0] ? item.data.AttachObjectIds[0].id : ''
|
|
// 添加了位置类型并且选中的类型为电井类型
|
|
// 添加了位置类型并且选中的类型为电井类型
|
|
if (
|
|
if (
|
|
- (item.data.GraphElementId == "100050" ||
|
|
|
|
- item.data.GraphElementId == "100055" ||
|
|
|
|
- item.data.GraphElementId == "100056" ||
|
|
|
|
- item.data.GraphElementId == "100057") &&
|
|
|
|
|
|
+ (item.data.GraphElementId == '100050' ||
|
|
|
|
+ item.data.GraphElementId == '100055' ||
|
|
|
|
+ item.data.GraphElementId == '100056' ||
|
|
|
|
+ item.data.GraphElementId == '100057') &&
|
|
location
|
|
location
|
|
) {
|
|
) {
|
|
if (this.wellMap.hasOwnProperty(location)) {
|
|
if (this.wellMap.hasOwnProperty(location)) {
|
|
@@ -238,17 +239,17 @@ export default {
|
|
let getParams = {
|
|
let getParams = {
|
|
plazaId: this.plazaId,
|
|
plazaId: this.plazaId,
|
|
floor: this.floorid,
|
|
floor: this.floorid,
|
|
- keyword: `${location}:wellnum;`,
|
|
|
|
|
|
+ keyword: `${location}:wellnum;`
|
|
}
|
|
}
|
|
- queryShops({getParams}).then(res => {
|
|
|
|
- let shopsnumList = [];
|
|
|
|
- let shopsnumItemList = [];
|
|
|
|
|
|
+ queryShops({ getParams }).then(res => {
|
|
|
|
+ let shopsnumList = []
|
|
|
|
+ let shopsnumItemList = []
|
|
if (res.data && res.data.length) {
|
|
if (res.data && res.data.length) {
|
|
- for(let floor in res.data[0]) {
|
|
|
|
|
|
+ for (let floor in res.data[0]) {
|
|
if (res.data[0][floor].length) {
|
|
if (res.data[0][floor].length) {
|
|
res.data[0][floor].forEach(v => {
|
|
res.data[0][floor].forEach(v => {
|
|
- shopsnumList = shopsnumList.concat(v.shopsnumList.split(","))
|
|
|
|
- })
|
|
|
|
|
|
+ shopsnumList = shopsnumList.concat(v.shopsnumList.split(','))
|
|
|
|
+ })
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -259,7 +260,7 @@ export default {
|
|
item.zOrder = 30
|
|
item.zOrder = 30
|
|
shopsnumItemList.push(item)
|
|
shopsnumItemList.push(item)
|
|
}
|
|
}
|
|
- });
|
|
|
|
|
|
+ })
|
|
this.wellMap[location] = shopsnumItemList
|
|
this.wellMap[location] = shopsnumItemList
|
|
}
|
|
}
|
|
})
|
|
})
|
|
@@ -269,7 +270,7 @@ export default {
|
|
},
|
|
},
|
|
// 清除电井关联商铺的高亮状态
|
|
// 清除电井关联商铺的高亮状态
|
|
clearHightLight() {
|
|
clearHightLight() {
|
|
- for(let key in this.wellMap) {
|
|
|
|
|
|
+ for (let key in this.wellMap) {
|
|
this.wellMap[key].forEach(item => {
|
|
this.wellMap[key].forEach(item => {
|
|
item.highLightFlag = false
|
|
item.highLightFlag = false
|
|
item.zOrder = ItemOrder.spaceOrder
|
|
item.zOrder = ItemOrder.spaceOrder
|