Commit 40683887 authored by 纪泽龙's avatar 纪泽龙

企业不受控制

parent 82d7a63a
/*
* @Author: your name
* @Date: 2022-01-11 13:45:12
* @LastEditTime: 2022-03-01 16:16:19
* @LastEditTime: 2022-03-01 17:25:23
* @LastEditors: Please set LastEditors
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: /test/hello-world/src/utils/mapClass.js
......@@ -482,9 +482,9 @@ export class EditorMap {
// 设备存在 受到设备按钮限制
const deviceHas = typeArr.indexOf(+data.iconType) >= 0;
// 如果是燃气公司的话,不受按钮限制
const enterprise = data.iconType ==7 || data.iconType ==8;
const enterprise = data.iconType == 7 || data.iconType == 8;
// 必须设备存在数组里,才会显示设备 !data.companyType代表用户不受公司制约
if ( (deviceHas || enterprise) && (companyHas || !data.companyType)) {
if (enterprise || (deviceHas && (companyHas || !data.companyType))) {
device.show();
} else {
device.hide();
......@@ -508,7 +508,10 @@ export class EditorMap {
device.oldData = device.getExtData();
device.setExtData(obj);
// 如果infowindow是打开的,就改变里面的数据,必须是用户才行
if (this.infowindowComponent && this.infowindowComponent.deviceData.iconType==6) {
if (
this.infowindowComponent &&
this.infowindowComponent.deviceData.iconType == 6
) {
this.infowindowComponentChange(obj);
}
if (!this.alarmObj[iconType]) {
......@@ -547,7 +550,10 @@ export class EditorMap {
device.setExtData(deviceData);
device.oldData = null;
// 如果infowindow是打开的
if (this.infowindowComponent && this.infowindowComponent.deviceData.iconType==6) {
if (
this.infowindowComponent &&
this.infowindowComponent.deviceData.iconType == 6
) {
this.infowindowComponentChange(deviceData);
}
// 在arr中删掉
......
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