|
@@ -490,7 +490,6 @@ export default {
|
|
}
|
|
}
|
|
this.INITOBJEXTINFO(objExtInfo);
|
|
this.INITOBJEXTINFO(objExtInfo);
|
|
}
|
|
}
|
|
-
|
|
|
|
// 初始化样式信息
|
|
// 初始化样式信息
|
|
if (res.content.style) {
|
|
if (res.content.style) {
|
|
// 拼接设备默认样式
|
|
// 拼接设备默认样式
|
|
@@ -557,16 +556,7 @@ export default {
|
|
if (this.ruleNum === this.loadedRuleNum) this.loadMarkRelation();
|
|
if (this.ruleNum === this.loadedRuleNum) this.loadMarkRelation();
|
|
}
|
|
}
|
|
// 加载区域显示
|
|
// 加载区域显示
|
|
- // TODO: 12
|
|
|
|
- // res.content.outline = [
|
|
|
|
- // { x: -24257.467785976827, y: -188397.297908777 },
|
|
|
|
- // {
|
|
|
|
- // x: 129712.73367871458,
|
|
|
|
- // y: -100521.62195087993,
|
|
|
|
- // },
|
|
|
|
- // ];
|
|
|
|
if (res.content.outline) {
|
|
if (res.content.outline) {
|
|
- // this.
|
|
|
|
const outline = res.content.outline;
|
|
const outline = res.content.outline;
|
|
const item = this.scene.initMaskItem(outline);
|
|
const item = this.scene.initMaskItem(outline);
|
|
this.SETOUTLINE(item);
|
|
this.SETOUTLINE(item);
|
|
@@ -596,15 +586,21 @@ export default {
|
|
equipItem.visible = Boolean(equipItem.legendData.bimLocation);
|
|
equipItem.visible = Boolean(equipItem.legendData.bimLocation);
|
|
// equipItem.connect("finishCreated", this.scene, this.scene.finishCreated);
|
|
// equipItem.connect("finishCreated", this.scene, this.scene.finishCreated);
|
|
equipItem.connect("onContextMenu", this, this.scene.getItem);
|
|
equipItem.connect("onContextMenu", this, this.scene.getItem);
|
|
- // 优先设备自身的样式
|
|
|
|
|
|
+ console.log(equip.classCode, equip.codeName);
|
|
|
|
+ // TODO: 设备样式
|
|
|
|
+ const equipStyle = window.__systemConf.equipStyle;
|
|
|
|
+ // 使用设备自身的样式
|
|
if (this.styleMap[equip.id]) {
|
|
if (this.styleMap[equip.id]) {
|
|
SPlanDecorator.equipDecorator(equipItem, this.styleMap[equip.id]);
|
|
SPlanDecorator.equipDecorator(equipItem, this.styleMap[equip.id]);
|
|
} else if (this.styleMap[equip.classCode]) {
|
|
} else if (this.styleMap[equip.classCode]) {
|
|
- // 设备类的样式
|
|
|
|
|
|
+ // 使用自身设备类的样式
|
|
SPlanDecorator.equipDecorator(equipItem, this.styleMap[equip.classCode]);
|
|
SPlanDecorator.equipDecorator(equipItem, this.styleMap[equip.classCode]);
|
|
|
|
+ } else if (equipStyle[equip.classCode]) {
|
|
|
|
+ // 使用配置文件中的设备类样式
|
|
|
|
+ SPlanDecorator.equipDecorator(equipItem, equipStyle[equip.classCode]);
|
|
} else {
|
|
} else {
|
|
- // 默认设备类的样式
|
|
|
|
- SPlanDecorator.equipDecorator(equipItem, this.styleMap["defaultEquipStyle"]);
|
|
|
|
|
|
+ // 使用配置文件中的默认样式
|
|
|
|
+ SPlanDecorator.equipDecorator(equipItem, equipStyle["defaultEquipStyle"]);
|
|
}
|
|
}
|
|
this.scene.addItem(equipItem);
|
|
this.scene.addItem(equipItem);
|
|
this.ADDEQUIP(equipItem);
|
|
this.ADDEQUIP(equipItem);
|