Merge branch 'dev' of git.cloud.tencent.com:joylink/jl-nclient into dev
This commit is contained in:
commit
4e1f95e900
3
.gitignore
vendored
3
.gitignore
vendored
@ -6,8 +6,7 @@ yarn-debug.log*
|
||||
yarn-error.log*
|
||||
package-lock.json
|
||||
tests/**/coverage/
|
||||
/src/utils/baseUrl.js
|
||||
/src/utils/
|
||||
src/utils/baseUrl.js
|
||||
|
||||
# Editor directories and files
|
||||
.idea
|
||||
|
@ -1,6 +1,6 @@
|
||||
import request from '@/utils/request';
|
||||
|
||||
/** 获取考题列表*/
|
||||
/** 获取用户试题列表*/
|
||||
export function generateExamList(examId) {
|
||||
return request({
|
||||
url: `/api/userExam/${examId}/generate`,
|
||||
|
@ -383,3 +383,19 @@ export function listAllTempLateRunPlan() {
|
||||
method: 'get'
|
||||
});
|
||||
}
|
||||
|
||||
// 删除加载计划
|
||||
export function deleteDailyRunPlanLoad(id) {
|
||||
return request({
|
||||
url: `/api/runPlan/daily/runPlanLoad/${id}`,
|
||||
method: 'DELETE'
|
||||
});
|
||||
}
|
||||
|
||||
// 从加载计划创建每日计划
|
||||
export function postDailyRunPlanLoadGenerate(id) {
|
||||
return request({
|
||||
url: `/api/runPlan/daily/runPlanLoad/${id}/generate`,
|
||||
method: 'post'
|
||||
});
|
||||
}
|
||||
|
Binary file not shown.
Before Width: | Height: | Size: 12 KiB After Width: | Height: | Size: 11 KiB |
Binary file not shown.
Before Width: | Height: | Size: 67 KiB After Width: | Height: | Size: 57 KiB |
@ -69,7 +69,7 @@ deviceRender[deviceType.AppendageBox] = {
|
||||
deviceRender[deviceType.IbpLine] = {
|
||||
_type: deviceType.IbpLine,
|
||||
zlevel: 1,
|
||||
z: 3
|
||||
z: 1
|
||||
};
|
||||
|
||||
/** Elevator 渲染配置 */
|
||||
|
File diff suppressed because one or more lines are too long
864
src/ibp/constant/ibpData_zaoyuan.js
Normal file
864
src/ibp/constant/ibpData_zaoyuan.js
Normal file
@ -0,0 +1,864 @@
|
||||
const ibpData = {
|
||||
'background': {
|
||||
'_type': 'Background',
|
||||
'code': 'bg_0000',
|
||||
'width': 4096,
|
||||
'height': 1300,
|
||||
'zlevel': 1,
|
||||
'z': 0
|
||||
},
|
||||
'arrowList': [{
|
||||
'zlevel': 1,
|
||||
'z': 2,
|
||||
'point': {
|
||||
'x': 50,
|
||||
'y': 338
|
||||
},
|
||||
'_type': 'Arrow',
|
||||
'code': 'arrow_0001',
|
||||
'orientation': 'left',
|
||||
'fill': '#0000CD',
|
||||
'width': 10,
|
||||
'length': 875,
|
||||
'lineWidth': 1
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 2,
|
||||
'point': {
|
||||
'x': 925,
|
||||
'y': 440
|
||||
},
|
||||
'_type': 'Arrow',
|
||||
'code': 'arrow_0002',
|
||||
'orientation': 'right',
|
||||
'fill': '#0000CD',
|
||||
'width': 10,
|
||||
'length': 875,
|
||||
'lineWidth': 1
|
||||
},
|
||||
{'point': {'x': 2675, 'y': 340}, '_type': 'Arrow', 'code': 'arrow_0003', 'orientation': 'left', 'fill': '#0000CD', 'width': 10, 'length': 350, 'zlevel': 1, 'z': 2},
|
||||
{'point': {'x': 3025, 'y': 466}, '_type': 'Arrow', 'code': 'arrow_0004', 'orientation': 'right', 'fill': '#0000CD', 'width': 10, 'length': 350, 'zlevel': 1, 'z': 2},
|
||||
{'point': {'x': 3126, 'y': 339}, '_type': 'Arrow', 'code': 'arrow_0005', 'orientation': 'left', 'fill': '#0000CD', 'width': 10, 'length': 800, 'zlevel': 1, 'z': 2},
|
||||
{'point': {'x': 3926, 'y': 466}, '_type': 'Arrow', 'code': 'arrow_0006', 'orientation': 'right', 'fill': '#0000CD', 'width': 10, 'length': 800, 'zlevel': 1, 'z': 2}
|
||||
],
|
||||
'clockList': [{'zlevel': 3, 'z': 1, 'point': {'x': 2374, 'y': 51}, '_type': 'Clock', 'code': 'clock_0001', 'width': 300}],
|
||||
'textList': [{
|
||||
'code': 'text_0001',
|
||||
'context': '隧 道 紧 急 通 风',
|
||||
'fontFamily': 'consolas',
|
||||
'fontSize': 38,
|
||||
'fontWeight': 900,
|
||||
'point': {
|
||||
'x': 332,
|
||||
'y': 114
|
||||
},
|
||||
'textFill': '#000',
|
||||
'z': 4,
|
||||
'zlevel': 1,
|
||||
'_type': 'IbpText'
|
||||
},
|
||||
{
|
||||
'code': 'text_0054',
|
||||
'context': '车 站 紧 急 通 风',
|
||||
'fontFamily': 'consolas',
|
||||
'fontSize': 38,
|
||||
'fontWeight': 900,
|
||||
'point': {
|
||||
'x': 1160,
|
||||
'y': 114
|
||||
},
|
||||
'textFill': '#000',
|
||||
'z': 4,
|
||||
'zlevel': 1,
|
||||
'_type': 'IbpText'
|
||||
},
|
||||
{
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 53,
|
||||
'y': 305
|
||||
},
|
||||
'code': 'text_0002',
|
||||
'_type': 'IbpText',
|
||||
'context': '皂 河 方 向',
|
||||
'textFill': '#000',
|
||||
'fontSize': 17,
|
||||
'fontWeight': 700,
|
||||
'fontFamily': 'consolas'
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 54,
|
||||
'y': 357
|
||||
},
|
||||
'code': 'text_0003',
|
||||
'_type': 'IbpText',
|
||||
'context': '下 行',
|
||||
'textFill': '#000',
|
||||
'fontSize': 17,
|
||||
'fontWeight': 700,
|
||||
'fontFamily': 'consolas'
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 879,
|
||||
'y': 406
|
||||
},
|
||||
'code': 'text_0004',
|
||||
'_type': 'IbpText',
|
||||
'context': '上 行',
|
||||
'textFill': '#000',
|
||||
'fontSize': 17,
|
||||
'fontWeight': 700,
|
||||
'fontFamily': 'consolas'
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 802,
|
||||
'y': 456
|
||||
},
|
||||
'code': 'text_0005',
|
||||
'_type': 'IbpText',
|
||||
'context': '汉 城 路 方 向',
|
||||
'textFill': '#000',
|
||||
'fontSize': 17,
|
||||
'fontWeight': 700,
|
||||
'fontFamily': 'consolas'
|
||||
},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1130, 'y': 213}, 'code': 'text_0006', '_type': 'IbpText', 'context': 'A端 小 系 统', 'textFill': '#000', 'fontSize': 12, 'fontWeight': 800, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1414, 'y': 213}, 'code': 'text_0007', '_type': 'IbpText', 'context': '大 系 统', 'textFill': '#000', 'fontSize': 12, 'fontWeight': 800, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1531, 'y': 212}, 'code': 'text_0008', '_type': 'IbpText', 'context': 'B端 小 系 统', 'textFill': '#000', 'fontSize': 12, 'fontWeight': 800, 'fontFamily': 'consolas'},
|
||||
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 138, 'y': 278}, 'code': 'text_0009', '_type': 'IbpText', 'context': 'ZZ14\n车头', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 188, 'y': 278}, 'code': 'text_0010', '_type': 'IbpText', 'context': 'ZZ15\n车尾', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 238, 'y': 278}, 'code': 'text_0011', '_type': 'IbpText', 'context': 'ZZ16\n车中\n近皂河\n疏散同行车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 288, 'y': 278}, 'code': 'text_0012', '_type': 'IbpText', 'context': 'ZZ17\n车中\n近皂河\n疏散逆行车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 338, 'y': 278}, 'code': 'text_0013', '_type': 'IbpText', 'context': 'ZZ18\n车中\n近枣园\n疏散同行车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 388, 'y': 278}, 'code': 'text_0014', '_type': 'IbpText', 'context': 'ZZ19\n车中\n近枣园\n疏散逆行车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 488, 'y': 278}, 'code': 'text_0015', '_type': 'IbpText', 'context': 'ZH16\n车头', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 538, 'y': 278}, 'code': 'text_0016', '_type': 'IbpText', 'context': 'ZH17\n车尾', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 588, 'y': 278}, 'code': 'text_0017', '_type': 'IbpText', 'context': 'ZH18\n车中\n近枣园\n疏散同行车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 638, 'y': 278}, 'code': 'text_0018', '_type': 'IbpText', 'context': 'ZH19\n车中\n近枣园\n疏散逆行车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 688, 'y': 278}, 'code': 'text_0019', '_type': 'IbpText', 'context': 'ZH20\n车中\n近汉城路\n疏散同行车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 738, 'y': 278}, 'code': 'text_0020', '_type': 'IbpText', 'context': 'ZH21\n车中\n近汉城路\n疏散逆行车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 138, 'y': 502}, 'code': 'text_0021', '_type': 'IbpText', 'context': 'ZZ08\n车头', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 188, 'y': 502}, 'code': 'text_0022', '_type': 'IbpText', 'context': 'ZZ09\n车尾', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 238, 'y': 502}, 'code': 'text_0023', '_type': 'IbpText', 'context': 'ZZ10\n车中\n近皂河\n疏散逆行车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 288, 'y': 502}, 'code': 'text_0024', '_type': 'IbpText', 'context': 'ZZ11\n车中\n近皂河\n疏散同行车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 338, 'y': 502}, 'code': 'text_0025', '_type': 'IbpText', 'context': 'ZZ12\n车中\n近枣园\n疏散同行车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 388, 'y': 502}, 'code': 'text_0026', '_type': 'IbpText', 'context': 'ZZ13\n车中\n近枣园\n疏散逆行车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 488, 'y': 502}, 'code': 'text_0027', '_type': 'IbpText', 'context': 'ZH08\n车头', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 538, 'y': 502}, 'code': 'text_0028', '_type': 'IbpText', 'context': 'ZH09\n车尾', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 588, 'y': 502}, 'code': 'text_0029', '_type': 'IbpText', 'context': 'ZH10\n车中\n近枣园\n疏散逆行车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 638, 'y': 502}, 'code': 'text_0030', '_type': 'IbpText', 'context': 'ZH11\n车中\n近枣园\n疏散同行车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 688, 'y': 502}, 'code': 'text_0031', '_type': 'IbpText', 'context': 'ZH12\n车中\n近汉城路\n疏散同行车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 738, 'y': 502}, 'code': 'text_0032', '_type': 'IbpText', 'context': 'ZH13\n车中\n近汉城路\n疏散逆行车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 788, 'y': 502}, 'code': 'text_0033', '_type': 'IbpText', 'context': 'ZH14\n存车线\n近车站', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 838, 'y': 502}, 'code': 'text_0034', '_type': 'IbpText', 'context': 'ZH15\n存车线\n远车站', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1013, 'y': 278}, 'code': 'text_0035', '_type': 'IbpText', 'context': 'XA04\n通风空调电控室\n灭火时', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1088, 'y': 278}, 'code': 'text_0036', '_type': 'IbpText', 'context': 'XA06\n通风设备室\n灭火时', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1163, 'y': 278}, 'code': 'text_0037', '_type': 'IbpText', 'context': 'XA08\n通信电源室\n灭火时', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1238, 'y': 278}, 'code': 'text_0038', '_type': 'IbpText', 'context': 'XA10\n综合监控室\n灭火时', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1313, 'y': 278}, 'code': 'text_0039', '_type': 'IbpText', 'context': 'XA12\n信号设备室\n灭火时', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1013, 'y': 353}, 'code': 'text_0040', '_type': 'IbpText', 'context': 'XA14\n控制室\n灭火时', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1088, 'y': 353}, 'code': 'text_0041', '_type': 'IbpText', 'context': 'XA16\n照明配电合蓄电\n池室灭火时', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1163, 'y': 353}, 'code': 'text_0042', '_type': 'IbpText', 'context': 'XA18\n屏蔽门控制室\n灭火时', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1238, 'y': 353}, 'code': 'text_0043', '_type': 'IbpText', 'context': 'XA20\n通信设备室\n灭火时', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1313, 'y': 353}, 'code': 'text_0044', '_type': 'IbpText', 'context': 'XA22\n警务机房\n灭火时', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1013, 'y': 428}, 'code': 'text_0045', '_type': 'IbpText', 'context': 'XA24\n35kV开关柜室\n灭火时', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1088, 'y': 428}, 'code': 'text_0046', '_type': 'IbpText', 'context': 'XA26\n1.5kV直流开关柜室\n灭火时', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1163, 'y': 428}, 'code': 'text_0047', '_type': 'IbpText', 'context': 'XA28\n整流变压器室1\n灭火时', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1238, 'y': 428}, 'code': 'text_0048', '_type': 'IbpText', 'context': 'XA30\n整流变压器室2\n灭火时', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1313, 'y': 428}, 'code': 'text_0049', '_type': 'IbpText', 'context': 'XA32\n0.4kV开关柜室\n灭火时', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1013, 'y': 503}, 'code': 'text_0050', '_type': 'IbpText', 'context': 'XA34\n站厅防烟分区1\n车控站长、AFC、\n值班会议、更衣、\n警务、招募配', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1088, 'y': 503}, 'code': 'text_0051', '_type': 'IbpText', 'context': 'XA35\n站厅防烟分区2\n走道', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1163, 'y': 503}, 'code': 'text_0052', '_type': 'IbpText', 'context': 'XA36\n站厅防烟分区3\n通风空调机房', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1238, 'y': 503}, 'code': 'text_0053', '_type': 'IbpText', 'context': 'XA37\n气瓶、保洁、电\n井、检修等', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1438, 'y': 278}, 'code': 'text_0055', '_type': 'IbpText', 'context': 'DW05\n站厅公共区', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1438, 'y': 328}, 'code': 'text_0056', '_type': 'IbpText', 'context': 'DW06\n站台公共区', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1438, 'y': 378}, 'code': 'text_0057', '_type': 'IbpText', 'context': 'DW07\n上行轨行区', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1438, 'y': 428}, 'code': 'text_0058', '_type': 'IbpText', 'context': 'DW08\n下行轨行区', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1438, 'y': 478}, 'code': 'text_0059', '_type': 'IbpText', 'context': 'DW09\nⅡ号出入口', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1563, 'y': 278}, 'code': 'text_0060', '_type': 'IbpText', 'context': 'XB04\n通风空调电控室\n灭火时', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1563, 'y': 353}, 'code': 'text_0061', '_type': 'IbpText', 'context': 'XB06\n蓄电池室\n灭火时', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1563, 'y': 428}, 'code': 'text_0062', '_type': 'IbpText', 'context': 'XB08\n站厅防烟分区1\n通风空调机房', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1563, 'y': 503}, 'code': 'text_0063', '_type': 'IbpText', 'context': 'XB09\n气瓶、照明配\n备品、工具、电\n井、工务、AFC等', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 170, 'y': 611}, 'code': 'text_0064', '_type': 'IbpText', 'context': 'IBP试灯', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 369, 'y': 610}, 'code': 'text_0065', '_type': 'IbpText', 'context': '自动状态', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 468, 'y': 609}, 'code': 'text_0066', '_type': 'IbpText', 'context': '手动状态', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 675, 'y': 610}, 'code': 'text_0067', '_type': 'IbpText', 'context': '复 位', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 238, 'y': 579}, 'code': 'text_0068', '_type': 'IbpText', 'context': '专业人员定期\n按压、检查', 'textFill': '#000', 'fontSize': 9, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 528, 'y': 575}, 'code': 'text_0069', '_type': 'IbpText', 'context': '正常位为\n自动位;\n根据环调\n指令,如需\n人工操作时\n转至手动位,\n按压上方对\n应按钮', 'textFill': '#000', 'fontSize': 9, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 617, 'y': 585}, 'code': 'text_0070', '_type': 'IbpText', 'context': '自动', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 577, 'y': 620}, 'code': 'text_0071', '_type': 'IbpText', 'context': '手动', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
|
||||
{
|
||||
'code': 'text_0072',
|
||||
'context': '消 火 栓 水 泵',
|
||||
'fontFamily': 'consolas',
|
||||
'fontSize': 36,
|
||||
'fontWeight': 900,
|
||||
'point': {'x': 1736, 'y': 114},
|
||||
'textFill': '#000',
|
||||
'z': 4,
|
||||
'zlevel': 1,
|
||||
'_type': 'IbpText'
|
||||
},
|
||||
{
|
||||
'code': 'text_0073',
|
||||
'context': 'AFC 闸 机',
|
||||
'fontFamily': 'consolas',
|
||||
'fontSize': 40,
|
||||
'fontWeight': 900,
|
||||
'point': {'x': 1781, 'y': 359},
|
||||
'textFill': '#000',
|
||||
'z': 4,
|
||||
'zlevel': 1,
|
||||
'_type': 'IbpText'
|
||||
},
|
||||
{
|
||||
'code': 'text_0074',
|
||||
'context': '门 禁',
|
||||
'fontFamily': 'consolas',
|
||||
'fontSize': 38,
|
||||
'fontWeight': 900,
|
||||
'point': {'x': 1814, 'y': 512},
|
||||
'textFill': '#000',
|
||||
'z': 4,
|
||||
'zlevel': 1,
|
||||
'_type': 'IbpText'
|
||||
},
|
||||
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1711, 'y': 205}, 'code': 'text_0075', '_type': 'IbpText', 'context': '1#消火栓\n水泵运行', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1786, 'y': 205}, 'code': 'text_0076', '_type': 'IbpText', 'context': '1#消火栓\n水泵故障', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1861, 'y': 205}, 'code': 'text_0077', '_type': 'IbpText', 'context': '2#消火栓\n水泵运行', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 1936, 'y': 205}, 'code': 'text_0078', '_type': 'IbpText', 'context': '2#消火栓\n水泵故障', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 3, 'z': 1, 'point': {'x': 2001, 'y': 205}, 'code': 'text_0079', '_type': 'IbpText', 'context': '消火栓水泵\n处于自动状态', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas' },
|
||||
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1754, 'y': 283}, 'code': 'text_0080', '_type': 'IbpText', 'context': '消火栓水泵启动', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1905, 'y': 283}, 'code': 'text_0081', '_type': 'IbpText', 'context': '消火栓水泵停止', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1680, 'y': 436}, 'code': 'text_0082', '_type': 'IbpText', 'context': '紧急释放状态', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1817, 'y': 436}, 'code': 'text_0083', '_type': 'IbpText', 'context': '紧急释放', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1785, 'y': 587}, 'code': 'text_0084', '_type': 'IbpText', 'context': '紧急开门状态', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1894, 'y': 587}, 'code': 'text_0085', '_type': 'IbpText', 'context': '紧急开门', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
|
||||
{'code': 'text_0086', 'context': '自 动 扶 梯', 'fontFamily': 'consolas', 'fontSize': 38, 'fontWeight': 900, 'point': {'x': 2280, 'y': 186}, 'textFill': '#000', 'z': 4, 'zlevel': 1, '_type': 'IbpText'},
|
||||
{'code': 'text_0087', 'context': '屏 蔽 门', 'fontFamily': 'consolas', 'fontSize': 38, 'fontWeight': 900, 'point': {'x': 2806, 'y': 185}, 'textFill': '#000', 'z': 4, 'zlevel': 1, '_type': 'IbpText'},
|
||||
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2180, 'y': 285}, 'code': 'text_0088', '_type': 'IbpText', 'context': 'B口', 'textFill': '#000', 'fontSize': 12, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2280, 'y': 285}, 'code': 'text_0089', '_type': 'IbpText', 'context': 'C口', 'textFill': '#000', 'fontSize': 12, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2130, 'y': 435}, 'code': 'text_0090', '_type': 'IbpText', 'context': '西\n端', 'textFill': '#000', 'fontSize': 16, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2455, 'y': 435}, 'code': 'text_0091', '_type': 'IbpText', 'context': '东\n端', 'textFill': '#000', 'fontSize': 16, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1784, 'y': 452}, 'code': 'text_0092', '_type': 'IbpText', 'context': '紧急情况下,直接按压\n“紧急释放”,紧急释\n放状态灯亮,即执行成功', 'textFill': '#000', 'fontSize': 8, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1928, 'y': 505}, 'code': 'text_0093', '_type': 'IbpText', 'context': '应急情况下按\n压,“紧急开门\n状态”灯亮,即\n执行成功,所有\n门禁将释放,恢\n复时需由专业\n操作。', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1986, 'y': 455}, 'code': 'text_0094', '_type': 'IbpText', 'context': '正常位为\n“联动禁止”位', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'textAlign': 'center'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2350, 'y': 229}, 'code': 'text_0095', '_type': 'IbpText', 'context': '按压后,红灯亮,现场\n扶梯停止运行,需现场\n用钥匙开启扶梯时,须\n再次按压,红灯熄灭', 'textFill': '#000', 'fontSize': 5, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2015, 'y': 411}, 'code': 'text_0096', '_type': 'IbpText', 'context': '联动允许', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1970, 'y': 436}, 'code': 'text_0097', '_type': 'IbpText', 'context': '联动禁止', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2593, 'y': 259}, 'code': 'text_0098', '_type': 'IbpText', 'context': '地面', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2593, 'y': 382}, 'code': 'text_0099', '_type': 'IbpText', 'context': '站厅', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2593, 'y': 507}, 'code': 'text_0100', '_type': 'IbpText', 'context': '站台', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2129, 'y': 383}, 'code': 'text_0101', '_type': 'IbpText', 'context': 'E0114/03(K1)', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2227, 'y': 383}, 'code': 'text_0102', '_type': 'IbpText', 'context': 'E0114/04(K2)', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2328, 'y': 383}, 'code': 'text_0103', '_type': 'IbpText', 'context': 'E0114/05(K3)', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2128, 'y': 509}, 'code': 'text_0104', '_type': 'IbpText', 'context': 'E0114/01(N)', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2228, 'y': 508}, 'code': 'text_0105', '_type': 'IbpText', 'context': 'E0114/02(N)', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2528, 'y': 455}, 'code': 'text_0106', '_type': 'IbpText', 'context': '扶梯盖板\n非正常打开', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
|
||||
{'point': {'x': 2178, 'y': 336}, 'code': 'text_0107', '_type': 'IbpText', 'context': '急停', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'zlevel': 1, 'z': 4},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2278, 'y': 336}, 'code': 'text_0108', '_type': 'IbpText', 'context': '急停', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'point': {'x': 2378, 'y': 336}, 'code': 'text_0109', '_type': 'IbpText', 'context': '急停', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'zlevel': 1, 'z': 4},
|
||||
{'point': {'x': 2177, 'y': 460}, 'code': 'text_0110', '_type': 'IbpText', 'context': '急停', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'zlevel': 1, 'z': 4},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2278, 'y': 460}, 'code': 'text_0111', '_type': 'IbpText', 'context': '急停', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2711, 'y': 285}, 'code': 'text_0112', '_type': 'IbpText', 'context': '门关闭且锁紧', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'point': {'x': 2797, 'y': 285}, 'code': 'text_0113', '_type': 'IbpText', 'context': '开门状态', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'zlevel': 1, 'z': 4},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2878, 'y': 285}, 'code': 'text_0114', '_type': 'IbpText', 'context': '开门', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'point': {'x': 2709, 'y': 535}, 'code': 'text_0115', '_type': 'IbpText', 'context': '门关闭且锁紧', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'zlevel': 1, 'z': 4},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2798, 'y': 535}, 'code': 'text_0116', '_type': 'IbpText', 'context': '开门状态', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2879, 'y': 535}, 'code': 'text_0117', '_type': 'IbpText', 'context': '开门', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2679, 'y': 354}, 'code': 'text_0118', '_type': 'IbpText', 'context': '下 行', 'textFill': '#000', 'fontSize': 17, 'fontWeight': 700, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2979, 'y': 431}, 'code': 'text_0119', '_type': 'IbpText', 'context': '上 行', 'textFill': '#000', 'fontSize': 17, 'fontWeight': 700, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3129, 'y': 357}, 'code': 'text_0120', '_type': 'IbpText', 'context': '下 行', 'textFill': '#000', 'fontSize': 17, 'fontWeight': 700, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3879, 'y': 433}, 'code': 'text_0121', '_type': 'IbpText', 'context': '上 行', 'textFill': '#000', 'fontSize': 17, 'fontWeight': 700, 'fontFamily': 'consolas'},
|
||||
|
||||
{
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 3127,
|
||||
'y': 307
|
||||
},
|
||||
'code': 'text_0122',
|
||||
'_type': 'IbpText',
|
||||
'context': '皂 河 方 向',
|
||||
'textFill': '#000',
|
||||
'fontSize': 17,
|
||||
'fontWeight': 700,
|
||||
'fontFamily': 'consolas'
|
||||
},
|
||||
{
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 3802,
|
||||
'y': 483
|
||||
},
|
||||
'code': 'text_0123',
|
||||
'_type': 'IbpText',
|
||||
'context': '汉 城 路 方 向',
|
||||
'textFill': '#000',
|
||||
'fontSize': 17,
|
||||
'fontWeight': 700,
|
||||
'fontFamily': 'consolas'
|
||||
},
|
||||
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2903, 'y': 235}, 'code': 'text_0124', '_type': 'IbpText', 'context': '正常位为“禁止位”', 'textFill': '#000', 'fontSize': 9, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2930, 'y': 357}, 'code': 'text_0125', '_type': 'IbpText', 'context': '钥匙转至“允许位”\n再按压“开门”按钮,乘客\n上下完毕后转至“禁止”\n位,现场方可使用PSL钥\n匙关门或打互锁解除发车', 'textFill': '#000', 'fontSize': 8, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3407, 'y': 187}, 'code': 'text_0126', '_type': 'IbpText', 'context': '下行按压后,\n表示灯亮\nATS/LOW机界\n面下行站台旁\n出现,即执行成功', 'textFill': '#000', 'fontSize': 8, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3607, 'y': 188}, 'code': 'text_0127', '_type': 'IbpText', 'context': '下行按压,待\n扣车表示灯熄灭后,\nATS/LOW机下行\n站厅旁圆点与字\n符消失,即执行\n成功', 'textFill': '#000', 'fontSize': 8, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3331, 'y': 386}, 'code': 'text_0128', '_type': 'IbpText', 'context': '按压后,表示灯亮\n蜂鸣器持续响(可\n按压报警切除进行\n消音),ATS/LOW\n机站台中央出现红\n色菱形,即执行\n成功', 'textFill': '#000', 'fontSize': 8, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3504, 'y': 356}, 'code': 'text_0129', '_type': 'IbpText', 'context': '按压后,表示灯熄灭蜂\n鸣器持续响(可按压报\n警切除进行消音),\nATS/LOW机站台中\n央红色菱形消失,即\n执行成功', 'textFill': '#000', 'fontSize': 7, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3656, 'y': 406}, 'code': 'text_0130', '_type': 'IbpText', 'context': '按压后,蜂鸣器静\n音,即执行成功', 'textFill': '#000', 'fontSize': 8, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3407, 'y': 563}, 'code': 'text_0131', '_type': 'IbpText', 'context': '上行按压后,\n表示灯亮,\nATS/LOW机界\n面下行站台旁\n出现,即执行成功', 'textFill': '#000', 'fontSize': 8, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3611, 'y': 561}, 'code': 'text_0132', '_type': 'IbpText', 'context': '上行按压,待扣\n车表示灯熄灭后,\nATS/LOW机下行\n站厅旁圆点与字\n符消失,即执行\n成功', 'textFill': '#000', 'fontSize': 8, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3426, 'y': 285}, 'code': 'text_0133', '_type': 'IbpText', 'context': 'X扣车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3527, 'y': 283}, 'code': 'text_0134', '_type': 'IbpText', 'context': 'X扣车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3618, 'y': 286}, 'code': 'text_0135', '_type': 'IbpText', 'context': 'X终止扣车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'point': {'x': 3420, 'y': 382}, 'code': 'text_0136', '_type': 'IbpText', 'context': '紧急停车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'zlevel': 1, 'z': 4},
|
||||
{'point': {'x': 3618, 'y': 382}, 'code': 'text_0137', '_type': 'IbpText', 'context': '紧急报警', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas', 'zlevel': 1, 'z': 4},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3419, 'y': 436}, 'code': 'text_0138', '_type': 'IbpText', 'context': '紧急停车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3519, 'y': 435}, 'code': 'text_0139', '_type': 'IbpText', 'context': '取消紧停', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3618, 'y': 434}, 'code': 'text_0140', '_type': 'IbpText', 'context': '报警切除', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3425, 'y': 534}, 'code': 'text_0141', '_type': 'IbpText', 'context': 'S扣车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3526, 'y': 533}, 'code': 'text_0142', '_type': 'IbpText', 'context': 'S扣车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3617, 'y': 533}, 'code': 'text_0143', '_type': 'IbpText', 'context': 'S终止扣车', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3907, 'y': 587}, 'code': 'text_0144', '_type': 'IbpText', 'context': '电话端子', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2965, 'y': 261}, 'code': 'text_0145', '_type': 'IbpText', 'context': '禁止', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2928, 'y': 288}, 'code': 'text_0146', '_type': 'IbpText', 'context': '允许', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2966, 'y': 510}, 'code': 'text_0147', '_type': 'IbpText', 'context': '禁止', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2928, 'y': 541}, 'code': 'text_0148', '_type': 'IbpText', 'context': '允许', 'textFill': '#000', 'fontSize': 10, 'fontWeight': 600, 'fontFamily': 'consolas'},
|
||||
|
||||
{'code': 'text_0149', 'context': '信 号', 'fontFamily': 'consolas', 'fontSize': 38, 'fontWeight': 900, 'point': {'x': 3488, 'y': 87}, 'textFill': '#000', 'z': 4, 'zlevel': 1, '_type': 'IbpText'},
|
||||
{'code': 'text_0150', 'context': ' 枣 园 站', 'fontFamily': 'consolas', 'fontSize': 44, 'fontWeight': 900, 'point': {'x': 2128, 'y': 59}, 'textFill': '#000', 'z': 4, 'zlevel': 1, '_type': 'IbpText'}
|
||||
],
|
||||
'teleTerminalList': [
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3908, 'y': 555}, 'draggable': true, '_type': 'TeleTerminal', 'code': 'terminal0001', 'width': 15},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3931, 'y': 555}, 'draggable': true, '_type': 'TeleTerminal', 'code': 'terminal0002', 'width': 15}],
|
||||
'squareButtonList': [{
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 125,
|
||||
'y': 246
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0001',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 176,
|
||||
'y': 246
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0002',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 226,
|
||||
'y': 247
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0003',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 275,
|
||||
'y': 247
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0004',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 325,
|
||||
'y': 247
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0005',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 376,
|
||||
'y': 246
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0006',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 475,
|
||||
'y': 246
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0007',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 526,
|
||||
'y': 247
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0008',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 576,
|
||||
'y': 246
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0009',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 625,
|
||||
'y': 247
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0010',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 676,
|
||||
'y': 247
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0011',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 726,
|
||||
'y': 247
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0012',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 126,
|
||||
'y': 472
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0013',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 175,
|
||||
'y': 472
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0014',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 225,
|
||||
'y': 472
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0015',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 275,
|
||||
'y': 472
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0016',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 325,
|
||||
'y': 472
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0017',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 376,
|
||||
'y': 471
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0018',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 475,
|
||||
'y': 472
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0019',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 525,
|
||||
'y': 472
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0020',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 576,
|
||||
'y': 472
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0021',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 626,
|
||||
'y': 472
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0022',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 677,
|
||||
'y': 472
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0023',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 727,
|
||||
'y': 472
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0024',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 776,
|
||||
'y': 473
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0025',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 825,
|
||||
'y': 473
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0026',
|
||||
'color': 'red',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
}, {
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 176,
|
||||
'y': 572
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0027',
|
||||
'color': 'yellow',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
},
|
||||
{
|
||||
'zlevel': 1,
|
||||
'z': 4,
|
||||
'point': {
|
||||
'x': 675,
|
||||
'y': 572
|
||||
},
|
||||
'_type': 'SquareButton',
|
||||
'code': 'button_0028',
|
||||
'color': 'green',
|
||||
'status': 'off',
|
||||
'width': 25
|
||||
},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1000, 'y': 247}, '_type': 'SquareButton', 'code': 'button_0029', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1075, 'y': 247}, '_type': 'SquareButton', 'code': 'button_0030', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1150, 'y': 247}, '_type': 'SquareButton', 'code': 'button_0031', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1225, 'y': 247}, '_type': 'SquareButton', 'code': 'button_0032', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1300, 'y': 247}, '_type': 'SquareButton', 'code': 'button_0033', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1000, 'y': 322}, '_type': 'SquareButton', 'code': 'button_0034', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1075, 'y': 322}, '_type': 'SquareButton', 'code': 'button_0035', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1150, 'y': 322}, '_type': 'SquareButton', 'code': 'button_0036', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1225, 'y': 322}, '_type': 'SquareButton', 'code': 'button_0037', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1300, 'y': 322}, '_type': 'SquareButton', 'code': 'button_0038', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1000, 'y': 397}, '_type': 'SquareButton', 'code': 'button_0039', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1075, 'y': 397}, '_type': 'SquareButton', 'code': 'button_0040', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1150, 'y': 397}, '_type': 'SquareButton', 'code': 'button_0041', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1225, 'y': 397}, '_type': 'SquareButton', 'code': 'button_0042', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1300, 'y': 397}, '_type': 'SquareButton', 'code': 'button_0043', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1000, 'y': 472}, '_type': 'SquareButton', 'code': 'button_0044', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1075, 'y': 472}, '_type': 'SquareButton', 'code': 'button_0045', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1150, 'y': 472}, '_type': 'SquareButton', 'code': 'button_0046', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1225, 'y': 472}, '_type': 'SquareButton', 'code': 'button_0047', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1425, 'y': 247}, '_type': 'SquareButton', 'code': 'button_0048', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1425, 'y': 297}, '_type': 'SquareButton', 'code': 'button_0049', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1425, 'y': 347}, '_type': 'SquareButton', 'code': 'button_0050', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1425, 'y': 397}, '_type': 'SquareButton', 'code': 'button_0051', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1425, 'y': 447}, '_type': 'SquareButton', 'code': 'button_0052', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1550, 'y': 247}, '_type': 'SquareButton', 'code': 'button_0053', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1550, 'y': 322}, '_type': 'SquareButton', 'code': 'button_0054', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1550, 'y': 397}, '_type': 'SquareButton', 'code': 'button_0055', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1550, 'y': 472}, '_type': 'SquareButton', 'code': 'button_0056', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1776, 'y': 247}, '_type': 'SquareButton', 'code': 'button_0057', 'color': 'green', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1925, 'y': 247}, '_type': 'SquareButton', 'code': 'button_0058', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'point': {'x': 1825, 'y': 398}, '_type': 'SquareButton', 'code': 'button_0059', 'color': 'red', 'status': 'off', 'width': 25, 'zlevel': 1, 'z': 4},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1900, 'y': 547}, '_type': 'SquareButton', 'code': 'button_0060', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2176, 'y': 299}, '_type': 'SquareButton', 'code': 'button_0061', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'point': {'x': 2276, 'y': 298}, '_type': 'SquareButton', 'code': 'button_0062', 'color': 'red', 'status': 'off', 'width': 25, 'zlevel': 1, 'z': 4},
|
||||
{'point': {'x': 2375, 'y': 297}, '_type': 'SquareButton', 'code': 'button_0063', 'color': 'red', 'status': 'off', 'width': 25, 'zlevel': 1, 'z': 4},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2176, 'y': 421}, '_type': 'SquareButton', 'code': 'button_0064', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2276, 'y': 423}, '_type': 'SquareButton', 'code': 'button_0065', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2875, 'y': 248}, '_type': 'SquareButton', 'code': 'button_0066', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2875, 'y': 498}, '_type': 'SquareButton', 'code': 'button_0067', 'color': 'red', 'status': 'off', 'width': 25},
|
||||
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3426, 'y': 247}, '_type': 'SquareButton', 'code': 'button_0068', 'color': 'yellow', 'status': 'off', 'width': 25}, {'zlevel': 1, 'z': 4, 'point': {'x': 3625, 'y': 248}, '_type': 'SquareButton', 'code': 'button_0069', 'color': 'green', 'status': 'off', 'width': 25}, {'zlevel': 1, 'z': 4, 'point': {'x': 3425, 'y': 397}, '_type': 'SquareButton', 'code': 'button_0070', 'color': 'red', 'status': 'off', 'width': 25}, {'zlevel': 1, 'z': 4, 'point': {'x': 3526, 'y': 396}, '_type': 'SquareButton', 'code': 'button_0071', 'color': 'yellow', 'status': 'off', 'width': 25}, {'zlevel': 1, 'z': 4, 'point': {'x': 3625, 'y': 396}, '_type': 'SquareButton', 'code': 'button_0072', 'color': 'blue', 'status': 'off', 'width': 25}, {'zlevel': 1, 'z': 4, 'point': {'x': 3425, 'y': 498}, '_type': 'SquareButton', 'code': 'button_0073', 'color': 'yellow', 'status': 'off', 'width': 25},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 3626, 'y': 497}, '_type': 'SquareButton', 'code': 'button_0074', 'color': 'green', 'status': 'off', 'width': 25}
|
||||
],
|
||||
'ibpLineList': [
|
||||
{'zlevel': 1, 'z': 1, 'point1': {'x': 963, 'y': 237}, 'point2': {'x': 1363, 'y': 237}, 'direction': 'transverse', 'code': 'line_0001', '_type': 'IbpLine', 'lineWidth': 2, 'fillColor': '#0000CD'},
|
||||
{'zlevel': 1, 'z': 1, 'point1': {'x': 963, 'y': 587}, 'point2': {'x': 1363, 'y': 587}, 'direction': 'transverse', 'code': 'line_0002', '_type': 'IbpLine', 'lineWidth': 2, 'fillColor': '#0000CD'},
|
||||
{'zlevel': 1, 'z': 1, 'point1': {'x': 963, 'y': 236}, 'point2': {'x': 963, 'y': 588}, 'direction': 'transverse', 'code': 'line_0003', '_type': 'IbpLine', 'lineWidth': 2, 'fillColor': '#0000CD'},
|
||||
{'zlevel': 1, 'z': 1, 'point1': {'x': 1363, 'y': 236}, 'point2': {'x': 1363, 'y': 588}, 'direction': 'transverse', 'code': 'line_0004', '_type': 'IbpLine', 'lineWidth': 2, 'fillColor': '#0000CD'},
|
||||
|
||||
{'zlevel': 1, 'z': 1, 'point1': {'x': 1388, 'y': 237}, 'point2': {'x': 1488, 'y': 237}, 'direction': 'transverse', 'code': 'line_0005', '_type': 'IbpLine', 'lineWidth': 2, 'fillColor': '#0000CD'},
|
||||
{'zlevel': 1, 'z': 1, 'point1': {'x': 1388, 'y': 587}, 'point2': {'x': 1488, 'y': 587}, 'direction': 'transverse', 'code': 'line_0006', '_type': 'IbpLine', 'lineWidth': 2, 'fillColor': '#0000CD'},
|
||||
{'zlevel': 1, 'z': 1, 'point1': {'x': 1388, 'y': 236}, 'point2': {'x': 1388, 'y': 588}, 'direction': 'transverse', 'code': 'line_0007', '_type': 'IbpLine', 'lineWidth': 2, 'fillColor': '#0000CD'},
|
||||
{'zlevel': 1, 'z': 1, 'point1': {'x': 1488, 'y': 236}, 'point2': {'x': 1488, 'y': 588}, 'direction': 'transverse', 'code': 'line_0008', '_type': 'IbpLine', 'lineWidth': 2, 'fillColor': '#0000CD'},
|
||||
|
||||
{'zlevel': 1, 'z': 1, 'point1': {'x': 1513, 'y': 237}, 'point2': {'x': 1613, 'y': 237}, 'direction': 'transverse', 'code': 'line_0009', '_type': 'IbpLine', 'lineWidth': 2, 'fillColor': '#0000CD'},
|
||||
{'zlevel': 1, 'z': 1, 'point1': {'x': 1513, 'y': 587}, 'point2': {'x': 1613, 'y': 587}, 'direction': 'transverse', 'code': 'line_0010', '_type': 'IbpLine', 'lineWidth': 2, 'fillColor': '#0000CD'},
|
||||
{'zlevel': 1, 'z': 1, 'point1': {'x': 1513, 'y': 236}, 'point2': {'x': 1513, 'y': 588}, 'direction': 'transverse', 'code': 'line_0011', '_type': 'IbpLine', 'lineWidth': 2, 'fillColor': '#0000CD'},
|
||||
{'zlevel': 1, 'z': 1, 'point1': {'x': 1613, 'y': 236}, 'point2': {'x': 1613, 'y': 588}, 'direction': 'transverse', 'code': 'line_0012', '_type': 'IbpLine', 'lineWidth': 2, 'fillColor': '#0000CD'},
|
||||
|
||||
{'zlevel': 1, 'z': 1, 'point1': {'x': 605, 'y': 588}, 'point2': {'x': 615, 'y': 588}, 'direction': 'transverse', 'code': 'line_0013', '_type': 'IbpLine', 'lineWidth': 3, 'fillColor': '#000'},
|
||||
{'zlevel': 1, 'z': 1, 'point1': {'x': 590, 'y': 603}, 'point2': {'x': 590, 'y': 613}, 'direction': 'transverse', 'code': 'line_0014', '_type': 'IbpLine', 'lineWidth': 3, 'fillColor': '#000'},
|
||||
|
||||
{'zlevel': 1, 'z': 1, 'point1': {'x': 1663, 'y': 0}, 'point2': {'x': 1663, 'y': 1300}, 'direction': 'transverse', 'code': 'line_0015', '_type': 'IbpLine', 'lineWidth': 5, 'fillColor': '#3A3A36'},
|
||||
{'zlevel': 1, 'z': 1, 'point1': {'x': 1663, 'y': 337}, 'point2': {'x': 2076, 'y': 337}, 'direction': 'transverse', 'code': 'line_0016', '_type': 'IbpLine', 'lineWidth': 5, 'fillColor': '#3A3A36'},
|
||||
{'zlevel': 1, 'z': 1, 'point1': {'x': 2076, 'y': 0}, 'point2': {'x': 2076, 'y': 1300}, 'direction': 'transverse', 'code': 'line_0017', '_type': 'IbpLine', 'lineWidth': 5, 'fillColor': '#3A3A36'},
|
||||
{'zlevel': 1, 'z': 1, 'point1': {'x': 1663, 'y': 487}, 'point2': {'x': 2076, 'y': 487}, 'direction': 'transverse', 'code': 'line_0018', '_type': 'IbpLine', 'lineWidth': 5, 'fillColor': '#3A3A36'},
|
||||
|
||||
{'zlevel': 1, 'z': 1, 'point1': {'x': 3063, 'y': 0}, 'point2': {'x': 3063, 'y': 1300}, 'direction': 'transverse', 'code': 'line_0019', '_type': 'IbpLine', 'lineWidth': 5, 'fillColor': '#3A3A36'},
|
||||
|
||||
{'zlevel': 1, 'z': 3, 'point1': {'x': 2002, 'y': 414}, 'point2': {'x': 2012, 'y': 414}, 'direction': 'transverse', 'code': 'line_0020', '_type': 'IbpLine', 'lineWidth': 3, 'fillColor': '#000'},
|
||||
{'zlevel': 1, 'z': 3, 'point1': {'x': 1988, 'y': 425}, 'point2': {'x': 1988, 'y': 435}, 'direction': 'transverse', 'code': 'line_0021', '_type': 'IbpLine', 'lineWidth': 3, 'fillColor': '#000'},
|
||||
{'zlevel': 1, 'z': 3, 'point1': {'x': 2952, 'y': 265}, 'point2': {'x': 2962, 'y': 265}, 'direction': 'transverse', 'code': 'line_0022', '_type': 'IbpLine', 'lineWidth': 3, 'fillColor': '#000'},
|
||||
{'zlevel': 1, 'z': 3, 'point1': {'x': 2939, 'y': 276}, 'point2': {'x': 2939, 'y': 286}, 'direction': 'transverse', 'code': 'line_0023', '_type': 'IbpLine', 'lineWidth': 3, 'fillColor': '#000'},
|
||||
{'zlevel': 1, 'z': 3, 'point1': {'x': 2952, 'y': 513}, 'point2': {'x': 2962, 'y': 513}, 'direction': 'transverse', 'code': 'line_0024', '_type': 'IbpLine', 'lineWidth': 3, 'fillColor': '#000'},
|
||||
{'zlevel': 1, 'z': 3, 'point1': {'x': 2939, 'y': 526}, 'point2': {'x': 2939, 'y': 536}, 'direction': 'transverse', 'code': 'line_0025', '_type': 'IbpLine', 'lineWidth': 3, 'fillColor': '#000'}
|
||||
],
|
||||
'circularLampList': [
|
||||
{'zlevel': 1, 'z': 1, 'point': {'x': 388, 'y': 588}, '_type': 'CircularLamp', 'code': 'lamp_0001', 'r': 8, 'fillColor': '#332C22', 'switch': 'on'},
|
||||
{'zlevel': 1, 'z': 1, 'point': {'x': 488, 'y': 588}, '_type': 'CircularLamp', 'code': 'lamp_0002', 'r': 8, 'fillColor': '#332C22', 'switch': 'off'},
|
||||
|
||||
{'zlevel': 1, 'z': 1, 'point': {'x': 1713, 'y': 188}, '_type': 'CircularLamp', 'code': 'lamp_0003', 'r': 8, 'fillColor': '#332C22', 'switch': 'off'},
|
||||
{'zlevel': 1, 'z': 1, 'point': {'x': 1788, 'y': 188}, '_type': 'CircularLamp', 'code': 'lamp_0004', 'r': 8, 'fillColor': '#332C22', 'switch': 'off'},
|
||||
{'zlevel': 1, 'z': 1, 'point': {'x': 1863, 'y': 188}, '_type': 'CircularLamp', 'code': 'lamp_0005', 'r': 8, 'fillColor': '#332C22', 'switch': 'off'},
|
||||
{'zlevel': 1, 'z': 1, 'point': {'x': 1938, 'y': 188}, '_type': 'CircularLamp', 'code': 'lamp_0006', 'r': 8, 'fillColor': '#332C22', 'switch': 'off'},
|
||||
{'zlevel': 1, 'z': 1, 'point': {'x': 2013, 'y': 188}, '_type': 'CircularLamp', 'code': 'lamp_0007', 'r': 8, 'fillColor': '#332C22', 'switch': 'on'},
|
||||
|
||||
{'zlevel': 1, 'z': 1, 'point': {'x': 1713, 'y': 413}, '_type': 'CircularLamp', 'code': 'lamp_0008', 'r': 8, 'fillColor': '#332C22', 'switch': 'off'},
|
||||
{'zlevel': 1, 'z': 1, 'point': {'x': 1813, 'y': 563}, '_type': 'CircularLamp', 'code': 'lamp_0009', 'r': 8, 'fillColor': '#332C22', 'switch': 'off'},
|
||||
|
||||
{'zlevel': 1, 'z': 1, 'point': {'x': 2538, 'y': 438}, '_type': 'CircularLamp', 'code': 'lamp_0010', 'r': 8, 'fillColor': '#332C22', 'switch': 'off'},
|
||||
{'zlevel': 1, 'z': 1, 'point': {'x': 2738, 'y': 264}, '_type': 'CircularLamp', 'code': 'lamp_0011', 'r': 8, 'fillColor': '#332C22', 'switch': 'on'},
|
||||
{'zlevel': 1, 'z': 1, 'point': {'x': 2813, 'y': 264}, '_type': 'CircularLamp', 'code': 'lamp_0012', 'r': 8, 'fillColor': '#332C22', 'switch': 'off' },
|
||||
{'zlevel': 1, 'z': 1, 'point': {'x': 2738, 'y': 513}, '_type': 'CircularLamp', 'code': 'lamp_0013', 'r': 8, 'fillColor': '#332C22', 'switch': 'on'},
|
||||
{'zlevel': 1, 'z': 1, 'point': {'x': 2813, 'y': 513}, '_type': 'CircularLamp', 'code': 'lamp_0014', 'r': 8, 'fillColor': '#332C22', 'switch': 'off' },
|
||||
|
||||
{'zlevel': 1, 'z': 1, 'point': {'x': 3538, 'y': 264}, '_type': 'CircularLamp', 'code': 'lamp_0015', 'r': 8, 'fillColor': '#332C22', 'switch': 'off' },
|
||||
{'zlevel': 1, 'z': 1, 'point': {'x': 3438, 'y': 363}, '_type': 'CircularLamp', 'code': 'lamp_0016', 'r': 8, 'fillColor': '#332C22', 'switch': 'off' },
|
||||
{'zlevel': 1, 'z': 1, 'point': {'x': 3538, 'y': 512}, '_type': 'CircularLamp', 'code': 'lamp_0017', 'r': 8, 'fillColor': '#332C22', 'switch': 'off' }
|
||||
],
|
||||
'tipBoxList': [
|
||||
{'zlevel': 2, 'z': 2, 'point': {'x': 202, 'y': 576}, 'code': 'tipBox_0001', '_type': 'TipBox', 'width': 75, 'height': 25, 'fillColor': '#CE950F'},
|
||||
{'zlevel': 2, 'z': 2, 'point': {'x': 525, 'y': 570}, 'code': 'tipBox_0002', '_type': 'TipBox', 'width': 50, 'height': 80, 'fillColor': '#CE950F'},
|
||||
{'zlevel': 2, 'z': 2, 'point': {'x': 600, 'y': 600}, 'code': 'tipBox_0003', '_type': 'TipBox', 'width': 25, 'height': 25, 'fillColor': '#CE950F'},
|
||||
|
||||
{'point': {'x': 1776, 'y': 450}, 'code': 'tipBox_0004', '_type': 'TipBox', 'width': 100, 'height': 25, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3},
|
||||
{'point': {'x': 1925, 'y': 501}, 'code': 'tipBox_0005', '_type': 'TipBox', 'width': 75, 'height': 75, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3},
|
||||
{'point': {'x': 1951, 'y': 450}, 'code': 'tipBox_0006', '_type': 'TipBox', 'width': 75, 'height': 25, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3},
|
||||
{'point': {'x': 2017, 'y': 423}, 'code': 'tipBox_0007', '_type': 'TipBox', 'width': 25, 'height': 25, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3 },
|
||||
{'point': {'x': 2176, 'y': 275}, 'code': 'tipBox_0008', '_type': 'TipBox', 'width': 25, 'height': 25, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3},
|
||||
{'point': {'x': 2277, 'y': 276}, 'code': 'tipBox_0009', '_type': 'TipBox', 'width': 25, 'height': 25, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3},
|
||||
{'point': {'x': 2126, 'y': 426}, 'code': 'tipBox_0010', '_type': 'TipBox', 'width': 25, 'height': 50, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3},
|
||||
{'point': {'x': 2451, 'y': 426}, 'code': 'tipBox_0011', '_type': 'TipBox', 'width': 25, 'height': 50, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3},
|
||||
{'point': {'x': 2350, 'y': 225}, 'code': 'tipBox_0012', '_type': 'TipBox', 'width': 50, 'height': 25, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3 },
|
||||
|
||||
{'point': {'x': 2901, 'y': 225}, 'code': 'tipBox_0013', '_type': 'TipBox', 'width': 75, 'height': 25, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3},
|
||||
{'point': {'x': 2951, 'y': 275}, 'code': 'tipBox_0014', '_type': 'TipBox', 'width': 25, 'height': 25, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3},
|
||||
{'point': {'x': 2925, 'y': 351}, 'code': 'tipBox_0015', '_type': 'TipBox', 'width': 100, 'height': 50, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3},
|
||||
{'point': {'x': 2951, 'y': 526}, 'code': 'tipBox_0016', '_type': 'TipBox', 'width': 25, 'height': 25, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3},
|
||||
|
||||
{'point': {'x': 3401, 'y': 174}, 'code': 'tipBox_0017', '_type': 'TipBox', 'width': 75, 'height': 75, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3}, {'point': {'x': 3601, 'y': 174}, 'code': 'tipBox_0018', '_type': 'TipBox', 'width': 75, 'height': 75, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3},
|
||||
{'point': {'x': 3326, 'y': 376}, 'code': 'tipBox_0019', '_type': 'TipBox', 'width': 75, 'height': 75, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3}, {'point': {'x': 3501, 'y': 351}, 'code': 'tipBox_0020', '_type': 'TipBox', 'width': 75, 'height': 50, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3}, {'point': {'x': 3651, 'y': 400}, 'code': 'tipBox_0021', '_type': 'TipBox', 'width': 75, 'height': 25, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3}, {'point': {'x': 3400, 'y': 551}, 'code': 'tipBox_0022', '_type': 'TipBox', 'width': 75, 'height': 75, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3}, {'point': {'x': 3601, 'y': 551}, 'code': 'tipBox_0023', '_type': 'TipBox', 'width': 75, 'height': 75, 'fillColor': '#CE950F', 'zlevel': 1, 'z': 3}
|
||||
],
|
||||
'rotatingButtonList': [
|
||||
{'point': {'x': 578, 'y': 578}, 'draggable': true, '_type': 'RotatingButton', 'code': 'rButton_0001', 'width': 20, 'zlevel': 1, 'z': 3},
|
||||
{'zlevel': 1, 'z': 3, 'point': {'x': 1979, 'y': 404}, 'draggable': true, '_type': 'RotatingButton', 'code': 'rButton_0002', 'width': 20, 'height': 20},
|
||||
{'point': {'x': 2928, 'y': 254}, 'draggable': true, '_type': 'RotatingButton', 'code': 'rButton_0003', 'width': 20, 'zlevel': 1, 'z': 3},
|
||||
{'point': {'x': 2929, 'y': 504}, 'draggable': true, '_type': 'RotatingButton', 'code': 'rButton_0004', 'width': 20, 'zlevel': 1, 'z': 3}
|
||||
],
|
||||
'keyList': [
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 578, 'y': 578}, 'draggable': true, '_type': 'Key', 'code': 'key_0001', 'width': 25, 'height': 75, 'status': 'on'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 1978, 'y': 403}, 'draggable': true, '_type': 'Key', 'code': 'key_0002', 'width': 25, 'height': 75, 'status': 'on'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2928, 'y': 253}, 'draggable': true, '_type': 'Key', 'code': 'key_0003', 'width': 25, 'height': 75, 'status': 'on'},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2929, 'y': 503}, 'draggable': true, '_type': 'Key', 'code': 'key_0004', 'width': 25, 'height': 75, 'status': 'on'}
|
||||
],
|
||||
'rotateTipList': [
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 602, 'y': 604}, 'draggable': true, '_type': 'RotateTip', 'code': 'rTip_0001', 'width': 20},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2019, 'y': 427}, 'draggable': true, '_type': 'RotateTip', 'code': 'rTip_0002', 'width': 20},
|
||||
{'zlevel': 1, 'z': 4, 'point': {'x': 2953, 'y': 278}, 'draggable': true, '_type': 'RotateTip', 'code': 'rTip_0003', 'width': 20},
|
||||
{'point': {'x': 2953, 'y': 529}, 'draggable': true, '_type': 'RotateTip', 'code': 'rTip_0004', 'width': 20, 'zlevel': 1, 'z': 4}
|
||||
],
|
||||
'appendageBoxList': [
|
||||
{'point': {'x': 2101, 'y': 250}, '_type': 'AppendageBox', 'code': 'aBox41745264751296', 'width': 525, 'height': 275, 'zlevel': 1, 'z': 1}
|
||||
],
|
||||
'alarmList': [
|
||||
{'point': {'x': 2553, 'y': 427}, 'code': 'alarm_0001', '_type': 'Alarm', 'width': 22, 'zlevel': 1, 'z': 4},
|
||||
{'point': {'x': 3627, 'y': 353}, 'code': 'alarm_0002', '_type': 'Alarm', 'width': 22, 'zlevel': 1, 'z': 4}
|
||||
],
|
||||
'elevatorList': [
|
||||
{'zlevel': 1, 'z': 2, 'point': {'x': 2151, 'y': 275}, '_type': 'Elevator', 'code': 'elevator_0001', 'width': 75, 'height': 100, 'fillColor': '#3E3E3E', 'direction': 'top'},
|
||||
{'zlevel': 1, 'z': 2, 'point': {'x': 2251, 'y': 275}, '_type': 'Elevator', 'code': 'elevator_0002', 'width': 75, 'height': 100, 'fillColor': '#3E3E3E', 'direction': 'top'},
|
||||
{'zlevel': 1, 'z': 2, 'point': {'x': 2351, 'y': 275}, '_type': 'Elevator', 'code': 'elevator_0003', 'width': 75, 'height': 100, 'fillColor': '#3E3E3E', 'direction': 'none'},
|
||||
{'zlevel': 1, 'z': 2, 'point': {'x': 2151, 'y': 400}, '_type': 'Elevator', 'code': 'elevator_0004', 'width': 75, 'height': 100, 'fillColor': '#3E3E3E', 'direction': 'top'},
|
||||
{'zlevel': 1, 'z': 2, 'point': {'x': 2251, 'y': 400}, '_type': 'Elevator', 'code': 'elevator_0005', 'width': 75, 'height': 100, 'fillColor': '#3E3E3E', 'direction': 'top'}
|
||||
]
|
||||
// 'teleTerminalList': [
|
||||
// {'zlevel': 3, 'z': 1, 'point': {'x': 3980, 'y': 471}, 'draggable': true, '_type': 'TeleTerminal', 'code': 'terminal5163486449281', 'width': 15},
|
||||
// {'zlevel': 3, 'z': 1, 'point': {'x': 4004, 'y': 471}, 'draggable': true, '_type': 'TeleTerminal', 'code': 'terminal51663374196', 'width': 15}
|
||||
// ]
|
||||
};
|
||||
export default ibpData;
|
@ -141,16 +141,24 @@ class IbpPan {
|
||||
(list || []).forEach(elem => {
|
||||
const code = elem.code;
|
||||
const type = elem._type;
|
||||
if (type === deviceType.Background) {
|
||||
this.canvasSize = {
|
||||
x: 0,
|
||||
y: 0,
|
||||
width: elem.width,
|
||||
height: elem.height
|
||||
};
|
||||
}
|
||||
updateIbpData(elem);
|
||||
const oDevice = this.ibpDevice[code] || deviceFactory(type, elem);
|
||||
const nDevice = deviceFactory(type, Object.assign(oDevice.model || {}, elem));
|
||||
delete this.ibpDevice[code];
|
||||
this.$painter.delete(oDevice);
|
||||
if (!elem._dispose) {
|
||||
this.ibpDevice[code] = nDevice;
|
||||
this.$painter.add(nDevice, true);
|
||||
this.$painter.add(nDevice);
|
||||
}
|
||||
});
|
||||
|
||||
if (this.methods.viewUpdate instanceof Function) { this.methods.viewUpdate(list); }
|
||||
}
|
||||
|
||||
@ -194,9 +202,6 @@ class IbpPan {
|
||||
}
|
||||
|
||||
drawIbpInit() {
|
||||
(Object.keys(this.ibpDevice) || []).forEach(elem => {
|
||||
this.$painter.drawIbp(this.ibpDevice[elem]);
|
||||
});
|
||||
this.$mouseController.setAllowDragging(true);
|
||||
}
|
||||
|
||||
|
@ -2,7 +2,6 @@ import deviceType from './constant/deviceType';
|
||||
import Eventful from 'zrender/src/mixin/Eventful';
|
||||
import * as eventTool from 'zrender/src/core/event';
|
||||
import store from '@/store';
|
||||
import Group from 'zrender/src/container/Group';
|
||||
|
||||
class EventModel {
|
||||
constructor(e) {
|
||||
@ -14,16 +13,9 @@ class EventModel {
|
||||
if (Object.values(deviceType).includes(view._type)) {
|
||||
this.deviceCode = view._code;
|
||||
this.deviceType = view._type;
|
||||
this.eventTarget = view;
|
||||
break;
|
||||
}
|
||||
|
||||
if (view._subType) {
|
||||
this.subType = view._subType;
|
||||
}
|
||||
if (view._val) {
|
||||
this.val = view._val;
|
||||
}
|
||||
|
||||
view = view.parent;
|
||||
}
|
||||
}
|
||||
@ -36,7 +28,6 @@ class MouseController extends Eventful {
|
||||
this.$zr = ibp.getZr();
|
||||
this.isAllowDragging=ibp.isAllowDragging||false;
|
||||
this.events = ibp.getEvents();
|
||||
this._draggingTarget=null;
|
||||
this._dragging = false;
|
||||
this.initHandler(this.$zr);
|
||||
}
|
||||
@ -100,40 +91,16 @@ class MouseController extends Eventful {
|
||||
if (eventTool.notLeftMouse(e)) {
|
||||
return;
|
||||
}
|
||||
//
|
||||
const draggingTarget = e.target;
|
||||
// draggingTarget.draggable
|
||||
if (draggingTarget) {
|
||||
if (e.target.parent.getName()=='background') {
|
||||
this._draggingName='background';
|
||||
} else if (this.isAllowDragging&&e.target.parent.getName()=='simple') {
|
||||
this._draggingName='simple';
|
||||
} else if (this.isAllowDragging&&e.target.parent.getName()=='group') {
|
||||
this._draggingName='group';
|
||||
this._offsetX=e.offsetX;
|
||||
this._offsetY=e.offsetY;
|
||||
// debugger;
|
||||
// this._draggingTarget.parent.model.point
|
||||
|
||||
} else if (this.isAllowDragging&&e.target.parent.getName()=='group_child') {
|
||||
this._draggingName='group_child';
|
||||
this._offsetX=e.offsetX;
|
||||
this._offsetY=e.offsetY;
|
||||
}
|
||||
this._draggingTarget = draggingTarget;
|
||||
// draggingTarget.dragging = true;
|
||||
this._x = e.offsetX;
|
||||
this._y = e.offsetY;
|
||||
this._dragging = true;
|
||||
// this.dispatchToElement(param(draggingTarget, e), 'dragstart', e.event);
|
||||
const em = new EventModel(e);
|
||||
this.eventTarget = em.eventTarget;
|
||||
if (this.eventTarget && this.eventTarget._type === deviceType.Background) {
|
||||
this.eventTarget.setCursor('pointer');
|
||||
}
|
||||
|
||||
// var x = e.offsetX;
|
||||
// var y = e.offsetY;
|
||||
|
||||
// this._x = x;
|
||||
// this._y = y;
|
||||
// this._dragging = true;
|
||||
this._offsetX=e.offsetX;
|
||||
this._offsetY=e.offsetY;
|
||||
this._x = e.offsetX;
|
||||
this._y = e.offsetY;
|
||||
this._dragging = true;
|
||||
}
|
||||
|
||||
mousemove(e) {
|
||||
@ -152,54 +119,30 @@ class MouseController extends Eventful {
|
||||
|
||||
this._x = e.offsetX;
|
||||
this._y = e.offsetY;
|
||||
|
||||
if (this._dragging) {
|
||||
if (this._draggingTarget&&this._draggingName=='background') {
|
||||
if ((this.eventTarget && this.eventTarget._type === deviceType.Background) || !this.isAllowDragging) {
|
||||
this._preventDefaultMouseMove && eventTool.stop(e.event);
|
||||
this.trigger(this.events.__Pan, { dx, dy, oldX, oldY, newX: this._x, newY: this._y });
|
||||
return true;
|
||||
} else if (this.isAllowDragging&&this._draggingTarget&&this._draggingName=='simple') {
|
||||
this._draggingTarget.drift(dx, dy, e);
|
||||
return true;
|
||||
} else if (this.isAllowDragging&&this._draggingTarget&&(this._draggingName=='group'||this._draggingName=='group_child')) {
|
||||
// debugger;
|
||||
if (this._draggingName=='group') {
|
||||
// this._draggingTarget.parent.model.point.x+=dx;
|
||||
// this._draggingTarget.parent.model.point.y+=dy;
|
||||
// this._draggingTarget.parent.dirty();
|
||||
this._draggingTarget.parent.drift(dx, dy, e);
|
||||
return true;
|
||||
} else {
|
||||
this._draggingTarget.parent.parent.drift(dx, dy, e);
|
||||
return true;
|
||||
}
|
||||
} else if (this.isAllowDragging) {
|
||||
this.eventTarget.grouper.drift(dx, dy, e);
|
||||
}
|
||||
} else {
|
||||
// debugger;
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
mouseup(e) {
|
||||
// debugger;
|
||||
const draggingTarget = this._draggingTarget;
|
||||
if (!eventTool.notLeftMouse(e)&&draggingTarget) {
|
||||
if (this._draggingName=='simple') {
|
||||
console.log();
|
||||
} else if (this._draggingName=='group'||this._draggingName=='group_child') {
|
||||
if (this._draggingName=='group') {
|
||||
this._draggingTarget.parent.setModal(e.offsetX - this._offsetX, e.offsetY - this._offsetY);
|
||||
this._draggingTarget.parent.dirty();
|
||||
} else {
|
||||
this._draggingTarget.parent.parent.parent.setModal(e.offsetX - this._offsetX, e.offsetY - this._offsetY);
|
||||
this._draggingTarget.parent.parent.dirty();
|
||||
}
|
||||
}
|
||||
this._dragging = false;
|
||||
this._draggingTarget = null;
|
||||
this._draggingName=='';
|
||||
if (!eventTool.notLeftMouse(e)&&this.isAllowDragging && this.eventTarget) {
|
||||
this.eventTarget.setModel(e.offsetX - this._offsetX, e.offsetY - this._offsetY);
|
||||
this.eventTarget.dirty();
|
||||
this.eventTarget = '';
|
||||
}
|
||||
if (this.eventTarget && this.eventTarget._type === deviceType.Background) {
|
||||
this.eventTarget.setCursor('default');
|
||||
}
|
||||
this._dragging = false;
|
||||
}
|
||||
|
||||
mousewheel(e) {
|
||||
@ -221,7 +164,7 @@ class MouseController extends Eventful {
|
||||
scale = -1;
|
||||
}
|
||||
|
||||
this.trigger(this.events.__Zoom, {type: 'zoom', scale, originX, originY });
|
||||
this.trigger(this.events.__Zoom, {type: this.events.__Zoom, scale, originX, originY });
|
||||
}
|
||||
}
|
||||
|
||||
@ -278,10 +221,6 @@ class MouseController extends Eventful {
|
||||
|
||||
return newEm;
|
||||
}
|
||||
|
||||
updateDatazoom(zoom) {
|
||||
this.trigger(this.events.Datazoom, zoom);
|
||||
}
|
||||
}
|
||||
|
||||
export default MouseController;
|
||||
|
@ -58,13 +58,12 @@ class Painter {
|
||||
* 添加视图
|
||||
* @param {*} device
|
||||
*/
|
||||
add(device, draggable) {
|
||||
add(device) {
|
||||
try {
|
||||
device = Object.assign(device, { event: this.$ibp.$mouseController });
|
||||
const instance = shapefactory(device, this.$ibp);
|
||||
if (instance) {
|
||||
device.instance = instance;
|
||||
draggable?instance.setDraggable():'';
|
||||
this.$transformHandle.transformView(instance);
|
||||
this.ibpInstanceLevel[device.model._type].add(instance);
|
||||
}
|
||||
@ -101,18 +100,6 @@ class Painter {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 绘制ipb时,更改draggable 和注册事件
|
||||
*/
|
||||
drawIbp(device) {
|
||||
if (device) {
|
||||
const instance = device.instance;
|
||||
if (instance) {
|
||||
instance.setDraggable();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 更新transform变化
|
||||
* @param {*} opt
|
||||
|
@ -1,81 +1,49 @@
|
||||
import Group from 'zrender/src/container/Group';
|
||||
import Image from 'zrender/src/graphic/Image';
|
||||
import alarmpic from '@/assets/ibp_images/alarm.png';
|
||||
import store from '@/store';
|
||||
|
||||
export default class alarm extends Group {
|
||||
|
||||
constructor(device) {
|
||||
super();
|
||||
this.model = device.model;
|
||||
this.event = device.event;
|
||||
this._type = device.model._type;
|
||||
this._code = device.model.code;
|
||||
this.zlevel = device.model.zlevel;
|
||||
this.z = device.model.zlevel;
|
||||
this.offsetX = 0;
|
||||
this.offsetY = 0;
|
||||
this.dragging = false;
|
||||
this.name='simple';
|
||||
this.create();
|
||||
}
|
||||
|
||||
create() {
|
||||
const model = this.model;
|
||||
this.grouper=new Group({
|
||||
id: this.model.code,
|
||||
position: [this.model.point.x, this.model.point.y]
|
||||
});
|
||||
this.imageBg = new Image({
|
||||
zlevel: this.zlevel,
|
||||
z: this.z,
|
||||
draggable: false,
|
||||
style: {
|
||||
image: alarmpic,
|
||||
x: model.point.x,
|
||||
y: model.point.y,
|
||||
width: model.width,
|
||||
height: model.width/71*74
|
||||
x: 0,
|
||||
y: 0,
|
||||
width: 71,
|
||||
height: 74
|
||||
}
|
||||
});
|
||||
this.add(this.imageBg);
|
||||
this.grouper.add(this.imageBg);
|
||||
this.add(this.grouper);
|
||||
this.transformScale();
|
||||
}
|
||||
/** 缩放按钮 */
|
||||
transformScale() {
|
||||
this.imageBg.origin = [this.model.point.x, this.model.point.y];
|
||||
this.imageBg.origin = [0, 0];
|
||||
this.imageBg.scale =[this.model.width/71, this.model.width/71];
|
||||
this.imageBg.dirty();
|
||||
}
|
||||
|
||||
setDraggable() {
|
||||
this.imageBg.attr('draggable', true);
|
||||
this.createMouseEvent();
|
||||
}
|
||||
createMouseEvent() {
|
||||
this.on('mousedown', this.mousedown, this);
|
||||
this.on('mousemove', this.mousemove, this);
|
||||
this.on('mouseup', this.mouseup, this);
|
||||
}
|
||||
|
||||
mousedown(e) {
|
||||
this.event.disable();
|
||||
if (e.which == 3) {
|
||||
store.dispatch('ibp/setUpdateDeviceData', this.model);
|
||||
return;
|
||||
}
|
||||
this.offsetX = e.offsetX;
|
||||
this.offsetY = e.offsetY;
|
||||
this.dragging = true;
|
||||
}
|
||||
|
||||
mousemove(e) {
|
||||
}
|
||||
|
||||
mouseup(e) {
|
||||
this.event.enable();
|
||||
if (this.dragging) {
|
||||
this.model.point.x = this.model.point.x + (e.offsetX - this.offsetX);
|
||||
this.model.point.y = this.model.point.y + (e.offsetY - this.offsetY);
|
||||
this.dragging = false;
|
||||
}
|
||||
|
||||
}
|
||||
getName() {
|
||||
return this.name;
|
||||
setModel(dx, dy) {
|
||||
this.model.point.x+=dx;
|
||||
this.model.point.y+=dy;
|
||||
}
|
||||
}
|
||||
|
@ -1,69 +1,40 @@
|
||||
import Group from 'zrender/src/container/Group';
|
||||
import Image from 'zrender/src/graphic/Image';
|
||||
import AppendageBoxImage from '@/assets/ibp_images/appendage_box.png';
|
||||
import store from '@/store';
|
||||
|
||||
export default class AppendageBox extends Group {
|
||||
constructor(device) {
|
||||
super();
|
||||
this.model = device.model;
|
||||
this.event = device.event;
|
||||
this._type = device.model._type;
|
||||
this._code = device.model.code;
|
||||
this.zlevel = device.model.zlevel;
|
||||
this.z = device.model.z;
|
||||
this.offsetX = 0;
|
||||
this.offsetY = 0;
|
||||
this.dragging = false;
|
||||
this.name='simple';
|
||||
this.create();
|
||||
}
|
||||
|
||||
create() {
|
||||
this.grouper=new Group({
|
||||
id: this.model.code,
|
||||
position: [this.model.point.x, this.model.point.y]
|
||||
});
|
||||
this.appendageBox = new Image({
|
||||
zlevel: this.zlevel,
|
||||
z: this.z,
|
||||
draggable: false,
|
||||
style: {
|
||||
image: AppendageBoxImage,
|
||||
x: this.model.point.x,
|
||||
y: this.model.point.y,
|
||||
x: 0,
|
||||
y: 0,
|
||||
width: this.model.width,
|
||||
height: this.model.height
|
||||
}
|
||||
});
|
||||
this.add(this.appendageBox);
|
||||
this.grouper.add(this.appendageBox);
|
||||
this.add(this.grouper);
|
||||
}
|
||||
|
||||
setDraggable() {
|
||||
this.appendageBox.attr('draggable', true);
|
||||
this.createMouseEvent();
|
||||
}
|
||||
createMouseEvent() {
|
||||
this.on('mousedown', this.mousedown, this);
|
||||
this.on('mousemove', this.mousemove, this);
|
||||
this.on('mouseup', this.mouseup, this);
|
||||
}
|
||||
mousedown(e) {
|
||||
this.event.disable();
|
||||
if (e.which == 3) {
|
||||
store.dispatch('ibp/setUpdateDeviceData', this.model);
|
||||
return;
|
||||
}
|
||||
this.offsetX = e.offsetX;
|
||||
this.offsetY = e.offsetY;
|
||||
this.dragging = true;
|
||||
}
|
||||
mousemove() {
|
||||
}
|
||||
mouseup(e) {
|
||||
this.event.enable();
|
||||
if (this.dragging) {
|
||||
this.model.point.x = this.model.point.x + (e.offsetX - this.offsetX);
|
||||
this.model.point.y = this.model.point.y + (e.offsetY - this.offsetY);
|
||||
this.dragging = false;
|
||||
}
|
||||
|
||||
}
|
||||
getName() {
|
||||
return this.name;
|
||||
setModel(dx, dy) {
|
||||
this.model.point.x+=dx;
|
||||
this.model.point.y+=dy;
|
||||
}
|
||||
}
|
||||
|
@ -1,36 +1,36 @@
|
||||
import Polygon from 'zrender/src/graphic/shape/Polygon';
|
||||
import Group from 'zrender/src/container/Group';
|
||||
import {arrow} from '@/jmap/shape/utils/ShapePoints';
|
||||
// import { updateIbpData } from '@/ibp/utils/parser';
|
||||
import store from '@/store';
|
||||
import {arrow} from './utils';
|
||||
|
||||
class Arrow extends Group {
|
||||
constructor(device) {
|
||||
super();
|
||||
this.event = device.event;
|
||||
this._type = device.model._type;
|
||||
this._code = device.model.code;
|
||||
this.model = device.model;
|
||||
this.offsetX = 0;
|
||||
this.offsetY = 0;
|
||||
this.dragging = false;
|
||||
this.name='simple';
|
||||
this.create();
|
||||
}
|
||||
|
||||
create() {
|
||||
const model = this.model;
|
||||
this.grouper=new Group({
|
||||
id: this.model.code,
|
||||
position: [this.model.point.x, this.model.point.y]
|
||||
});
|
||||
this.arrow = new Polygon({
|
||||
zlevel: model.zlevel,
|
||||
z: model.z,
|
||||
draggable: false,
|
||||
shape: {
|
||||
points: arrow(this.model.point.x, this.model.point.y, this.model.length, this.model.width)
|
||||
points: arrow(0, 0, this.model.length, this.model.width)
|
||||
},
|
||||
style: {
|
||||
stroke: model.stroke,
|
||||
fill: model.fill
|
||||
}
|
||||
});
|
||||
this.add(this.arrow);
|
||||
this.grouper.add(this.arrow);
|
||||
this.add(this.grouper);
|
||||
this.getOrientate();
|
||||
}
|
||||
|
||||
@ -57,7 +57,7 @@ class Arrow extends Group {
|
||||
|
||||
// 整体旋转箭头
|
||||
transformRotation(rotate) {
|
||||
this.arrow.origin = [this.model.point.x, this.model.point.y];
|
||||
this.arrow.origin = [0, 0];
|
||||
this.arrow.rotation = Math.PI / 180 * Number(rotate);
|
||||
this.arrow.dirty();
|
||||
}
|
||||
@ -66,37 +66,9 @@ class Arrow extends Group {
|
||||
setColor(color) {
|
||||
this.arrow.setStyle('fill', color);
|
||||
}
|
||||
setDraggable() {
|
||||
this.arrow.attr('draggable', true);
|
||||
this.createMouseEvent();
|
||||
}
|
||||
createMouseEvent() {
|
||||
this.on('mousedown', this.mousedown, this);
|
||||
this.on('mousemove', this.mousemove, this);
|
||||
this.on('mouseup', this.mouseup, this);
|
||||
}
|
||||
mousedown(e) {
|
||||
this.event.disable();
|
||||
if (e.which == 3) {
|
||||
store.dispatch('ibp/setUpdateDeviceData', this.model);
|
||||
return;
|
||||
}
|
||||
this.offsetX = e.offsetX;
|
||||
this.offsetY = e.offsetY;
|
||||
this.dragging = true;
|
||||
}
|
||||
mousemove() {
|
||||
}
|
||||
mouseup(e) {
|
||||
this.event.enable();
|
||||
if (this.dragging) {
|
||||
this.model.point.x = this.model.point.x + (e.offsetX - this.offsetX);
|
||||
this.model.point.y = this.model.point.y + (e.offsetY - this.offsetY);
|
||||
this.dragging = false;
|
||||
}
|
||||
}
|
||||
getName() {
|
||||
return this.name;
|
||||
setModel(dx, dy) {
|
||||
this.model.point.x+=dx;
|
||||
this.model.point.y+=dy;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -7,11 +7,11 @@ export default class background extends Group {
|
||||
constructor(device) {
|
||||
super();
|
||||
this.model = device.model;
|
||||
this._type = device.model._type;
|
||||
this._code = device.model.code;
|
||||
this.zlevel = device.model.zlevel;
|
||||
this.z = 1;
|
||||
this.name='background';
|
||||
this.create();
|
||||
this.createMouseEvent();
|
||||
}
|
||||
create() {
|
||||
const image = new Image(25, 25);
|
||||
@ -34,24 +34,10 @@ export default class background extends Group {
|
||||
});
|
||||
this.add(this.imageBg);
|
||||
};
|
||||
|
||||
}
|
||||
createMouseEvent() {
|
||||
this.on('mousedown', this.mousedown, this);
|
||||
this.on('mouseup', this.mouseup, this);
|
||||
setModel(dx, dy) {
|
||||
}
|
||||
mousedown(e) {
|
||||
if (e.which == 3) {
|
||||
return;
|
||||
}
|
||||
this.imageBg.attr('cursor', 'pointer');
|
||||
}
|
||||
mouseup() {
|
||||
this.imageBg.attr('cursor', 'default');
|
||||
}
|
||||
setDraggable() {
|
||||
}
|
||||
getName() {
|
||||
return this.name;
|
||||
setCursor(mouseStyle) {
|
||||
this.imageBg.attr('cursor', mouseStyle);
|
||||
}
|
||||
}
|
||||
|
@ -10,7 +10,6 @@ import yellowButtonPic from '@/assets/ibp_images/yellow_button.png';
|
||||
import yellowButtonPicOn from '@/assets/ibp_images/yellow_button_on.png';
|
||||
import grayButtonPic from '@/assets/ibp_images/gray_button.png';
|
||||
import grayButtonPicOn from '@/assets/ibp_images/gray_button_on.png';
|
||||
import store from '@/store';
|
||||
|
||||
export default class button extends Group {
|
||||
static colors = new Map([
|
||||
@ -27,38 +26,38 @@ export default class button extends Group {
|
||||
]);
|
||||
constructor(device) {
|
||||
super();
|
||||
this.event = device.event;
|
||||
this._type = device.model._type;
|
||||
this._code = device.model.code;
|
||||
this.model = device.model;
|
||||
this.zlevel = device.model.zlevel;
|
||||
this.z = device.model.z;
|
||||
this.event = device.event;
|
||||
this.offsetX = 0;
|
||||
this.offsetY = 0;
|
||||
this.dragging = false;
|
||||
this.name='simple';
|
||||
this.create();
|
||||
}
|
||||
create() {
|
||||
const model = this.model;
|
||||
this.grouper=new Group({
|
||||
id: this.model.code,
|
||||
position: [this.model.point.x, this.model.point.y]
|
||||
});
|
||||
this.imageBg = new Image({
|
||||
zlevel: this.zlevel,
|
||||
z: this.z,
|
||||
draggable: false,
|
||||
style: {
|
||||
image: this.getImagePic(),
|
||||
x: model.point.x,
|
||||
y: model.point.y,
|
||||
x: 0,
|
||||
y: 0,
|
||||
width: 70,
|
||||
height: 80
|
||||
}
|
||||
});
|
||||
this.add(this.imageBg);
|
||||
this.grouper.add(this.imageBg);
|
||||
this.add(this.grouper);
|
||||
this.transformScale();
|
||||
}
|
||||
|
||||
/** 缩放按钮 */
|
||||
transformScale() {
|
||||
this.imageBg.origin = [this.model.point.x, this.model.point.y];
|
||||
this.imageBg.origin = [0, 0];
|
||||
this.imageBg.scale =[this.model.width/70, this.model.width/70];
|
||||
this.imageBg.dirty();
|
||||
}
|
||||
@ -68,16 +67,6 @@ export default class button extends Group {
|
||||
return color[0];
|
||||
}
|
||||
|
||||
setDraggable() {
|
||||
this.imageBg.attr('draggable', true);
|
||||
this.createMouseEvent();
|
||||
}
|
||||
createMouseEvent() {
|
||||
this.on('mousedown', this.mousedown, this);
|
||||
this.on('mousemove', this.mousemove, this);
|
||||
this.on('mouseup', this.mouseup, this);
|
||||
}
|
||||
|
||||
// 设置按钮状态
|
||||
setState(model) {
|
||||
switch (model.status) {
|
||||
@ -112,28 +101,6 @@ export default class button extends Group {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
mousedown(e) {
|
||||
this.event.disable();
|
||||
if (e.which == 3) {
|
||||
store.dispatch('ibp/setUpdateDeviceData', this.model);
|
||||
return;
|
||||
}
|
||||
this.offsetX = e.offsetX;
|
||||
this.offsetY = e.offsetY;
|
||||
this.dragging = true;
|
||||
}
|
||||
mousemove() {
|
||||
}
|
||||
mouseup(e) {
|
||||
this.event.enable();
|
||||
if (this.dragging) {
|
||||
this.model.point.x = this.model.point.x + (e.offsetX - this.offsetX);
|
||||
this.model.point.y = this.model.point.y + (e.offsetY - this.offsetY);
|
||||
this.dragging = false;
|
||||
}
|
||||
|
||||
}
|
||||
// 关闭
|
||||
close() {
|
||||
const color = button.colors.get(`${this.model.color}_off`);
|
||||
@ -144,7 +111,8 @@ export default class button extends Group {
|
||||
const color = button.colors.get(`${this.model.color}_on`);
|
||||
this.imageBg.setStyle({image: color[0]});
|
||||
}
|
||||
getName() {
|
||||
return this.name;
|
||||
setModel(dx, dy) {
|
||||
this.model.point.x+=dx;
|
||||
this.model.point.y+=dy;
|
||||
}
|
||||
}
|
||||
|
@ -1,79 +1,52 @@
|
||||
import Group from 'zrender/src/container/Group';
|
||||
import Circle from 'zrender/src/graphic/shape/Circle';
|
||||
import store from '@/store';
|
||||
|
||||
export default class CircularLamp extends Group {
|
||||
constructor(device) {
|
||||
super();
|
||||
this.model = device.model;
|
||||
this.event = device.event;
|
||||
this._type = device.model._type;
|
||||
this._code = device.model.code;
|
||||
this.zlevel = device.model.zlevel;
|
||||
this.z = device.model.z;
|
||||
this.offsetX = 0;
|
||||
this.offsetY = 0;
|
||||
this.dragging = false;
|
||||
this.name='simple';
|
||||
this.create();
|
||||
this.setStatus(this.model);
|
||||
}
|
||||
|
||||
create() {
|
||||
this.grouper=new Group({
|
||||
id: this.model.code,
|
||||
position: [this.model.point.x, this.model.point.y]
|
||||
});
|
||||
this.lamp = new Circle({
|
||||
zlevel: this.zlevel,
|
||||
z: this.z,
|
||||
draggable: false,
|
||||
shape: {
|
||||
cx: this.model.point.x,
|
||||
cy: this.model.point.y,
|
||||
cx: 0,
|
||||
cy: 0,
|
||||
r: this.model.r
|
||||
},
|
||||
style: {
|
||||
fill: this.model.fillColor
|
||||
}
|
||||
});
|
||||
this.add(this.lamp);
|
||||
this.grouper.add(this.lamp);
|
||||
this.add(this.grouper);
|
||||
}
|
||||
|
||||
setCircularLampColor(color) {
|
||||
this.lamp.setStyle('fill', color);
|
||||
}
|
||||
setDraggable() {
|
||||
this.lamp.attr('draggable', true);
|
||||
this.createMouseEvent();
|
||||
}
|
||||
createMouseEvent() {
|
||||
this.on('mousedown', this.mousedown, this);
|
||||
this.on('mousemove', this.mousemove, this);
|
||||
this.on('mouseup', this.mouseup, this);
|
||||
}
|
||||
mousedown(e) {
|
||||
this.event.disable();
|
||||
if (e.which == 3) {
|
||||
store.dispatch('ibp/setUpdateDeviceData', this.model);
|
||||
return;
|
||||
}
|
||||
this.offsetX = e.offsetX;
|
||||
this.offsetY = e.offsetY;
|
||||
this.dragging = true;
|
||||
}
|
||||
mousemove() {
|
||||
}
|
||||
mouseup(e) {
|
||||
this.event.enable();
|
||||
if (this.dragging) {
|
||||
this.model.point.x = this.model.point.x + (e.offsetX - this.offsetX);
|
||||
this.model.point.y = this.model.point.y + (e.offsetY - this.offsetY);
|
||||
this.dragging = false;
|
||||
}
|
||||
this.lamp.setStyle({fill: color});
|
||||
}
|
||||
setStatus(model) {
|
||||
if (model.switch === 'on') {
|
||||
this.lamp.setStyle('fill', '#D8FCF2');
|
||||
this.setCircularLampColor('#D8FCF2');
|
||||
} else {
|
||||
this.lamp.setStyle('fill', '#332C22');
|
||||
this.setCircularLampColor('#332C22');
|
||||
}
|
||||
}
|
||||
getName() {
|
||||
return this.name;
|
||||
setModel(dx, dy) {
|
||||
this.model.point.x+=dx;
|
||||
this.model.point.y+=dy;
|
||||
}
|
||||
}
|
||||
|
@ -12,32 +12,31 @@ import clock8 from '@/assets/ibp_images/clock/clock_8.png';
|
||||
import clock9 from '@/assets/ibp_images/clock/clock_9.png';
|
||||
import clockBg from '@/assets/ibp_images/clock/clock_bg.png';
|
||||
import clockColon from '@/assets/ibp_images/clock/clock_colon.png';
|
||||
import store from '@/store';
|
||||
|
||||
export default class clock extends Group {
|
||||
constructor(device) {
|
||||
super();
|
||||
this.event = device.event;
|
||||
this._type = device.model._type;
|
||||
this._code = device.model.code;
|
||||
this.model = device.model;
|
||||
this.zlevel = device.model.zlevel;
|
||||
this.z = device.model.z;
|
||||
this.event = device.event;
|
||||
this.offsetX = 0;
|
||||
this.offsetY = 0;
|
||||
this.dragging = false;
|
||||
this.initTime = 0;
|
||||
this.name='group';
|
||||
this.create();
|
||||
|
||||
}
|
||||
create() {
|
||||
this.grouper=new Group({
|
||||
id: this.model.code,
|
||||
position: [this.model.point.x, this.model.point.y]
|
||||
});
|
||||
this.clockBg = new Image({
|
||||
zlevel: this.zlevel,
|
||||
z: this.z,
|
||||
style: {
|
||||
image: clockBg,
|
||||
x: this.model.point.x,
|
||||
y: this.model.point.y,
|
||||
x: 0,
|
||||
y: 0,
|
||||
width: this.model.width,
|
||||
height: this.model.width/493*156
|
||||
}
|
||||
@ -47,10 +46,10 @@ export default class clock extends Group {
|
||||
z: this.z,
|
||||
style: {
|
||||
image: this.getImagePic('0'),
|
||||
x: this.model.point.x+this.model.width*0.1,
|
||||
y: this.model.point.y+this.model.width*0.052,
|
||||
width: this.model.width*0.1,
|
||||
height: this.model.width*0.1/37*74
|
||||
x: this.model.width*0.098,
|
||||
y: this.model.width*0.062,
|
||||
width: this.model.width*0.095,
|
||||
height: this.model.width*0.095/37*74
|
||||
}
|
||||
});
|
||||
this.num2 = new Image({
|
||||
@ -58,10 +57,10 @@ export default class clock extends Group {
|
||||
z: this.z,
|
||||
style: {
|
||||
image: this.getImagePic('0'),
|
||||
x: this.model.point.x+this.model.width*0.22,
|
||||
y: this.model.point.y+this.model.width*0.052,
|
||||
width: this.model.width*0.1,
|
||||
height: this.model.width*0.1/37*74
|
||||
x: this.model.width*0.22,
|
||||
y: this.model.width*0.062,
|
||||
width: this.model.width*0.095,
|
||||
height: this.model.width*0.095/37*74
|
||||
}
|
||||
});
|
||||
this.num3 = new Image({
|
||||
@ -69,10 +68,10 @@ export default class clock extends Group {
|
||||
z: this.z,
|
||||
style: {
|
||||
image: this.getImagePic('0'),
|
||||
x: this.model.point.x+this.model.width*0.39,
|
||||
y: this.model.point.y+this.model.width*0.052,
|
||||
width: this.model.width*0.1,
|
||||
height: this.model.width*0.1/37*74
|
||||
x: this.model.width*0.395,
|
||||
y: this.model.width*0.062,
|
||||
width: this.model.width*0.095,
|
||||
height: this.model.width*0.095/37*74
|
||||
}
|
||||
});
|
||||
this.num4 = new Image({
|
||||
@ -80,10 +79,10 @@ export default class clock extends Group {
|
||||
z: this.z,
|
||||
style: {
|
||||
image: this.getImagePic('0'),
|
||||
x: this.model.point.x+this.model.width*0.52,
|
||||
y: this.model.point.y+this.model.width*0.052,
|
||||
width: this.model.width*0.1,
|
||||
height: this.model.width*0.1/37*74
|
||||
x: this.model.width*0.52,
|
||||
y: this.model.width*0.062,
|
||||
width: this.model.width*0.095,
|
||||
height: this.model.width*0.095/37*74
|
||||
}
|
||||
});
|
||||
this.num5 = new Image({
|
||||
@ -91,10 +90,10 @@ export default class clock extends Group {
|
||||
z: this.z,
|
||||
style: {
|
||||
image: this.getImagePic('0'),
|
||||
x: this.model.point.x+this.model.width*0.69,
|
||||
y: this.model.point.y+this.model.width*0.052,
|
||||
width: this.model.width*0.1,
|
||||
height: this.model.width*0.1/37*74
|
||||
x: this.model.width*0.69,
|
||||
y: this.model.width*0.062,
|
||||
width: this.model.width*0.095,
|
||||
height: this.model.width*0.095/37*74
|
||||
}
|
||||
});
|
||||
this.num6 = new Image({
|
||||
@ -102,10 +101,10 @@ export default class clock extends Group {
|
||||
z: this.z,
|
||||
style: {
|
||||
image: this.getImagePic('0'),
|
||||
x: this.model.point.x+this.model.width*0.82,
|
||||
y: this.model.point.y+this.model.width*0.052,
|
||||
width: this.model.width*0.1,
|
||||
height: this.model.width*0.1/37*74
|
||||
x: this.model.width*0.816,
|
||||
y: this.model.width*0.062,
|
||||
width: this.model.width*0.095,
|
||||
height: this.model.width*0.095/37*74
|
||||
}
|
||||
});
|
||||
this.clockColon1 = new Image({
|
||||
@ -113,10 +112,10 @@ export default class clock extends Group {
|
||||
z: this.z,
|
||||
style: {
|
||||
image: clockColon,
|
||||
x: this.model.point.x+this.model.width*0.16,
|
||||
y: this.model.point.y-this.model.width*0.028,
|
||||
width: this.model.width*0.37,
|
||||
height: this.model.width/1*0.37
|
||||
x: +this.model.width*0.183,
|
||||
y: -this.model.width*0.017,
|
||||
width: this.model.width*0.34,
|
||||
height: this.model.width/1*0.34
|
||||
}
|
||||
});
|
||||
this.clockColon2 = new Image({
|
||||
@ -124,21 +123,22 @@ export default class clock extends Group {
|
||||
z: this.z,
|
||||
style: {
|
||||
image: clockColon,
|
||||
x: this.model.point.x+this.model.width*0.46,
|
||||
y: this.model.point.y-this.model.width*0.028,
|
||||
width: this.model.width*0.37,
|
||||
height: this.model.width/1*0.37
|
||||
x: +this.model.width*0.48,
|
||||
y: -this.model.width*0.017,
|
||||
width: this.model.width*0.34,
|
||||
height: this.model.width/1*0.34
|
||||
}
|
||||
});
|
||||
this.add(this.clockBg);
|
||||
this.add(this.num1);
|
||||
this.add(this.num2);
|
||||
this.add(this.num3);
|
||||
this.add(this.num4);
|
||||
this.add(this.num5);
|
||||
this.add(this.num6);
|
||||
this.add(this.clockColon1);
|
||||
this.add(this.clockColon2);
|
||||
this.grouper.add(this.clockBg);
|
||||
this.grouper.add(this.num1);
|
||||
this.grouper.add(this.num2);
|
||||
this.grouper.add(this.num3);
|
||||
this.grouper.add(this.num4);
|
||||
this.grouper.add(this.num5);
|
||||
this.grouper.add(this.num6);
|
||||
this.grouper.add(this.clockColon1);
|
||||
this.grouper.add(this.clockColon2);
|
||||
this.add(this.grouper);
|
||||
}
|
||||
getImagePic(context) {
|
||||
let pic = clock0;
|
||||
@ -176,11 +176,16 @@ export default class clock extends Group {
|
||||
}
|
||||
return pic;
|
||||
}
|
||||
setClockStart() {
|
||||
setClockStart(started) {
|
||||
const _this = this;
|
||||
this.timer = setInterval(() => {
|
||||
_this.handleClock(_this);
|
||||
}, 1000);
|
||||
if (started) {
|
||||
this.timer&&clearInterval(this.timer);
|
||||
this.timer = setInterval(() => {
|
||||
_this.handleClock(_this);
|
||||
}, 1000);
|
||||
} else {
|
||||
this.timer&&clearInterval(this.timer);
|
||||
}
|
||||
}
|
||||
handleClock(_this) {
|
||||
_this.initTime += 1000;
|
||||
@ -249,33 +254,8 @@ export default class clock extends Group {
|
||||
this.setNumPic(2, hours.charAt(1));
|
||||
this.setNumPic(1, hours.charAt(0));
|
||||
}
|
||||
setDraggable() {
|
||||
this.createMouseEvent();
|
||||
}
|
||||
createMouseEvent() {
|
||||
this.on('mousedown', this.mousedown, this);
|
||||
}
|
||||
mousedown(e) {
|
||||
if (e.which == 3) {
|
||||
store.dispatch('ibp/setUpdateDeviceData', this.model);
|
||||
return;
|
||||
}
|
||||
}
|
||||
getName() {
|
||||
return this.name;
|
||||
}
|
||||
setModal(dx, dy) {
|
||||
// debugger;
|
||||
// this.parent.dirty();
|
||||
//
|
||||
// this.model.point.x+=dx;
|
||||
// this.model.point.y+=dy;
|
||||
// this.eachChild(function(child) {
|
||||
// // // debugger;
|
||||
// child.style.x+=dx;
|
||||
// child.style.y+=dy;
|
||||
// // child.dirty();
|
||||
// }, this.parent);
|
||||
|
||||
setModel(dx, dy) {
|
||||
this.model.point.x+=dx;
|
||||
this.model.point.y+=dy;
|
||||
}
|
||||
}
|
||||
|
@ -1,15 +1,14 @@
|
||||
import Group from 'zrender/src/container/Group';
|
||||
import ElevatorBack from './elevatorBack';
|
||||
import ElevatorArrow from './elevatorArrow';
|
||||
import store from '@/store';
|
||||
|
||||
export default class elevator extends Group {
|
||||
|
||||
constructor(device) {
|
||||
super();
|
||||
this.event = device.event;
|
||||
this._type = device.model._type;
|
||||
this._code = device.model.code;
|
||||
this.model = device.model;
|
||||
this.name='group';
|
||||
this.create();
|
||||
}
|
||||
|
||||
@ -18,16 +17,12 @@ export default class elevator extends Group {
|
||||
|
||||
this.grouper=new Group({
|
||||
id: model.code,
|
||||
// width: model.width,
|
||||
// height: model.height,
|
||||
position: [model.point.x, model.point.y]
|
||||
// draggable: model.draggable || false
|
||||
});
|
||||
|
||||
this.elevatorBack = new ElevatorBack({model: {
|
||||
zlevel: model.zlevel,
|
||||
z: model.z,
|
||||
// model.draggable ||
|
||||
draggable: false,
|
||||
point: {
|
||||
x: model.point.x,
|
||||
@ -80,11 +75,6 @@ export default class elevator extends Group {
|
||||
return status==this.model.direction? 'on':'off';
|
||||
}
|
||||
}
|
||||
|
||||
getName() {
|
||||
return this.name;
|
||||
}
|
||||
|
||||
setStatus(model) {
|
||||
if (model.direction=='none') {
|
||||
this.elevatorArrowBottom.setStatus('off');
|
||||
@ -98,11 +88,7 @@ export default class elevator extends Group {
|
||||
}
|
||||
}
|
||||
|
||||
setDraggable() {
|
||||
// this.grouper.attr('draggable', true);
|
||||
// this.createMouseEvent();
|
||||
}
|
||||
setModal(dx, dy) {
|
||||
setModel(dx, dy) {
|
||||
this.model.point.x+=dx;
|
||||
this.model.point.y+=dy;
|
||||
}
|
||||
|
@ -9,7 +9,6 @@ export default class elevatorArrow extends Group {
|
||||
super();
|
||||
this.model = device.model;
|
||||
this.zlevel = device.model.zlevel;
|
||||
this.name='group_child';
|
||||
this.create();
|
||||
}
|
||||
|
||||
@ -88,8 +87,4 @@ export default class elevatorArrow extends Group {
|
||||
}
|
||||
this.imageBg.setStyle({image: imageBack});
|
||||
}
|
||||
|
||||
getName() {
|
||||
return this.name;
|
||||
}
|
||||
}
|
||||
|
@ -7,7 +7,6 @@ export default class elevatorBack extends Group {
|
||||
super();
|
||||
this.event = device.event;
|
||||
this.model = device.model;
|
||||
this.name='group_child';
|
||||
this.create();
|
||||
}
|
||||
|
||||
@ -23,7 +22,7 @@ export default class elevatorBack extends Group {
|
||||
draggable: false,
|
||||
style: {
|
||||
x: model.point.x,
|
||||
y: model.point.y,
|
||||
y: model.point.y,
|
||||
brushType: 'fill',
|
||||
fill: this.model.fillColor || '#313131',
|
||||
lineWidth: 0
|
||||
@ -32,7 +31,4 @@ export default class elevatorBack extends Group {
|
||||
this.add(this.elevatorBack);
|
||||
}
|
||||
|
||||
getName() {
|
||||
return this.name;
|
||||
}
|
||||
}
|
||||
|
@ -1,71 +1,44 @@
|
||||
import Group from 'zrender/src/container/Group';
|
||||
import Line from 'zrender/src/graphic/shape/Line';
|
||||
import store from '@/store';
|
||||
|
||||
export default class ibpLine extends Group {
|
||||
constructor(device) {
|
||||
super();
|
||||
this.model = device.model;
|
||||
this.event = device.event;
|
||||
this._type = device.model._type;
|
||||
this._code = device.model.code;
|
||||
this.zlevel = device.model.zlevel;
|
||||
this.z = device.model.z;
|
||||
this.offsetX = 0;
|
||||
this.offsetY = 0;
|
||||
this.dragging = false;
|
||||
this.name='simple';
|
||||
this.create();
|
||||
}
|
||||
create() {
|
||||
const model = this.model;
|
||||
this.grouper=new Group({
|
||||
id: model.code,
|
||||
position: [model.point1.x, model.point1.y]
|
||||
});
|
||||
this.ibpLine = new Line({
|
||||
zlevel: model.zlevel,
|
||||
z: model.z,
|
||||
draggable: false,
|
||||
shape: {
|
||||
x1: this.model.point1.x,
|
||||
y1: this.model.point1.y,
|
||||
x2: this.model.point2.x,
|
||||
y2: this.model.point2.y
|
||||
x1: 0,
|
||||
y1: 0,
|
||||
x2: model.point2.x-model.point1.x,
|
||||
y2: model.point2.y-model.point1.y
|
||||
},
|
||||
style: {
|
||||
lineWidth: this.model.lineWidth,
|
||||
stroke: this.model.fillColor
|
||||
}
|
||||
});
|
||||
this.add(this.ibpLine);
|
||||
this.grouper.add(this.ibpLine);
|
||||
this.add(this.grouper);
|
||||
}
|
||||
setDraggable() {
|
||||
this.ibpLine.attr('draggable', true);
|
||||
this.createMouseEvent();
|
||||
}
|
||||
createMouseEvent() {
|
||||
this.on('mousedown', this.mousedown, this);
|
||||
this.on('mousemove', this.mousemove, this);
|
||||
this.on('mouseup', this.mouseup, this);
|
||||
}
|
||||
mousedown(e) {
|
||||
this.event.disable();
|
||||
if (e.which == 3) {
|
||||
store.dispatch('ibp/setUpdateDeviceData', this.model);
|
||||
return;
|
||||
}
|
||||
this.offsetX = e.offsetX;
|
||||
this.offsetY = e.offsetY;
|
||||
this.dragging = true;
|
||||
}
|
||||
mousemove() {
|
||||
}
|
||||
mouseup(e) {
|
||||
this.event.enable();
|
||||
if (this.dragging) {
|
||||
this.model.point1.x = this.model.point1.x - this.offsetX + e.offsetX;
|
||||
this.model.point1.y = this.model.point1.y - this.offsetY + e.offsetY;
|
||||
this.model.point2.x = this.model.point2.x - this.offsetX + e.offsetX;
|
||||
this.model.point2.y = this.model.point2.y - this.offsetY + e.offsetY;
|
||||
this.dragging = false;
|
||||
}
|
||||
}
|
||||
getName() {
|
||||
return this.name;
|
||||
setModel(dx, dy) {
|
||||
this.model.point1.x += dx;
|
||||
this.model.point1.y += dy;
|
||||
this.model.point2.x += dx;
|
||||
this.model.point2.y += dy;
|
||||
}
|
||||
}
|
||||
|
@ -1,30 +1,31 @@
|
||||
import Group from 'zrender/src/container/Group';
|
||||
import Text from 'zrender/src/graphic/Text';
|
||||
import store from '@/store';
|
||||
import Rect from 'zrender/src/graphic/shape/Rect';
|
||||
|
||||
export default class ibpText extends Group {
|
||||
constructor(device) {
|
||||
super();
|
||||
this.model = device.model;
|
||||
this.event = device.event;
|
||||
this._type = device.model._type;
|
||||
this._code = device.model.code;
|
||||
this.zlevel = device.model.zlevel;
|
||||
this.z = device.model.z;
|
||||
this.offsetX = 0;
|
||||
this.offsetY = 0;
|
||||
this.dragging = false;
|
||||
this.name='simple';
|
||||
this.create();
|
||||
}
|
||||
create() {
|
||||
const model = this.model;
|
||||
this.grouper=new Group({
|
||||
id: this.model.code,
|
||||
position: [this.model.point.x, this.model.point.y]
|
||||
});
|
||||
this.textName = new Text({
|
||||
zlevel: model.zlevel,
|
||||
z: model.z,
|
||||
silent: model.silent || false,
|
||||
draggable: false,
|
||||
style: {
|
||||
x: model.point.x,
|
||||
y: model.point.y,
|
||||
x: 0,
|
||||
y: 0,
|
||||
fontWeight: model.fontWeight,
|
||||
fontSize: model.fontSize,
|
||||
fontFamily: model.fontFamily,
|
||||
@ -37,38 +38,29 @@ export default class ibpText extends Group {
|
||||
textLineHeight: model.fontSize
|
||||
}
|
||||
});
|
||||
this.add(this.textName);
|
||||
// if ( model.hasRect) {
|
||||
// this.grouper.add(this.tip);
|
||||
// this.tip = new Rect({
|
||||
// zlevel: model.zlevel,
|
||||
// z: model.z-1,
|
||||
// draggable: false,
|
||||
// shape: {
|
||||
// x: model.textRect.x- model.point.x,
|
||||
// y: model.textRect.x - model.point.y,
|
||||
// width: model.textRect.width,
|
||||
// height: model.textRect.height
|
||||
// },
|
||||
// style: {
|
||||
// fill: model.textBackgroundColor
|
||||
// }
|
||||
// });
|
||||
// }
|
||||
this.grouper.add(this.textName);
|
||||
|
||||
this.add(this.grouper);
|
||||
}
|
||||
setDraggable() {
|
||||
this.textName.attr('draggable', true);
|
||||
this.createMouseEvent();
|
||||
}
|
||||
createMouseEvent() {
|
||||
this.on('mousedown', this.mousedown, this);
|
||||
this.on('mousemove', this.mousemove, this);
|
||||
this.on('mouseup', this.mouseup, this);
|
||||
}
|
||||
mousedown(e) {
|
||||
this.event.disable();
|
||||
if (e.which == 3) {
|
||||
store.dispatch('ibp/setUpdateDeviceData', this.model);
|
||||
return;
|
||||
}
|
||||
this.offsetX = e.offsetX;
|
||||
this.offsetY = e.offsetY;
|
||||
this.dragging = true;
|
||||
}
|
||||
mousemove() {
|
||||
}
|
||||
mouseup(e) {
|
||||
this.event.enable();
|
||||
if (this.dragging) {
|
||||
this.model.point.x = this.model.point.x + (e.offsetX - this.offsetX);
|
||||
this.model.point.y = this.model.point.y + (e.offsetY - this.offsetY);
|
||||
this.dragging = false;
|
||||
}
|
||||
}
|
||||
getName() {
|
||||
return this.name;
|
||||
setModel(dx, dy) {
|
||||
this.model.point.x+=dx;
|
||||
this.model.point.y+=dy;
|
||||
}
|
||||
}
|
||||
|
@ -1,29 +1,29 @@
|
||||
import Group from 'zrender/src/container/Group';
|
||||
import Rect from 'zrender/src/graphic/shape/Rect';
|
||||
import store from '@/store';
|
||||
|
||||
export default class ibpTipBox extends Group {
|
||||
constructor(device) {
|
||||
super();
|
||||
this.model = device.model;
|
||||
this.event = device.event;
|
||||
this._type = device.model._type;
|
||||
this._code = device.model.code;
|
||||
this.zlevel = device.model.zlevel;
|
||||
this.z = device.model.z;
|
||||
this.offsetX = 0;
|
||||
this.offsetY = 0;
|
||||
this.dragging = false;
|
||||
this.name='simple';
|
||||
this.create();
|
||||
}
|
||||
create() {
|
||||
const model = this.model;
|
||||
this.grouper=new Group({
|
||||
id: model.code,
|
||||
position: [model.point.x, model.point.y]
|
||||
});
|
||||
this.tipBox = new Rect({
|
||||
zlevel: model.zlevel,
|
||||
z: model.z,
|
||||
draggable: false,
|
||||
shape: {
|
||||
x: this.model.point.x,
|
||||
y: this.model.point.y,
|
||||
x: 0,
|
||||
y: 0,
|
||||
width: this.model.width,
|
||||
height: this.model.height
|
||||
},
|
||||
@ -31,38 +31,11 @@ export default class ibpTipBox extends Group {
|
||||
fill: this.model.fillColor
|
||||
}
|
||||
});
|
||||
this.add(this.tipBox);
|
||||
this.grouper.add(this.tipBox);
|
||||
this.add(this.grouper);
|
||||
}
|
||||
setDraggable() {
|
||||
this.tipBox.attr('draggable', true);
|
||||
this.createMouseEvent();
|
||||
}
|
||||
createMouseEvent() {
|
||||
this.on('mousedown', this.mousedown, this);
|
||||
this.on('mousemove', this.mousemove, this);
|
||||
this.on('mouseup', this.mouseup, this);
|
||||
}
|
||||
mousedown(e) {
|
||||
this.event.disable();
|
||||
if (e.which == 3) {
|
||||
store.dispatch('ibp/setUpdateDeviceData', this.model);
|
||||
return;
|
||||
}
|
||||
this.offsetX = e.offsetX;
|
||||
this.offsetY = e.offsetY;
|
||||
this.dragging = true;
|
||||
}
|
||||
mousemove() {
|
||||
}
|
||||
mouseup(e) {
|
||||
this.event.enable();
|
||||
if (this.dragging) {
|
||||
this.model.point.x = this.model.point.x + (e.offsetX - this.offsetX);
|
||||
this.model.point.y = this.model.point.y + (e.offsetY - this.offsetY);
|
||||
this.dragging = false;
|
||||
}
|
||||
}
|
||||
getName() {
|
||||
return this.name;
|
||||
setModel(dx, dy) {
|
||||
this.model.point.x+=dx;
|
||||
this.model.point.y+=dy;
|
||||
}
|
||||
}
|
||||
|
@ -2,7 +2,6 @@ import Group from 'zrender/src/container/Group';
|
||||
import Image from 'zrender/src/graphic/Image';
|
||||
import keyPic from '@/assets/ibp_images/key.png';
|
||||
import keyPicOn from '@/assets/ibp_images/key_on.png';
|
||||
import store from '@/store';
|
||||
|
||||
export default class key extends Group {
|
||||
|
||||
@ -10,35 +9,37 @@ export default class key extends Group {
|
||||
super();
|
||||
this.model = device.model;
|
||||
this.zlevel = device.model.zlevel;
|
||||
this.event = device.event;
|
||||
this.offsetX = 0;
|
||||
this.offsetY = 0;
|
||||
this.dragging = false;
|
||||
this.name='simple';
|
||||
this._type = device.model._type;
|
||||
this._code = device.model.code;
|
||||
this.create();
|
||||
}
|
||||
|
||||
create() {
|
||||
const model = this.model;
|
||||
this.grouper=new Group({
|
||||
id: model.code,
|
||||
position: [model.point.x, model.point.y]
|
||||
});
|
||||
this.keyImage = new Image({
|
||||
zlevel: this.zlevel,
|
||||
z: model.z,
|
||||
draggable: false,
|
||||
style: {
|
||||
image: this.getRotateColor(),
|
||||
x: model.point.x,
|
||||
y: model.point.y,
|
||||
x: 0,
|
||||
y: 0,
|
||||
width: 314,
|
||||
height: 932
|
||||
}
|
||||
});
|
||||
this.add(this.keyImage);
|
||||
this.grouper.add(this.keyImage);
|
||||
this.add(this.grouper);
|
||||
this.transformScale();
|
||||
}
|
||||
|
||||
/** 缩放按钮 */
|
||||
transformScale() {
|
||||
this.keyImage.origin = [this.model.point.x, this.model.point.y];
|
||||
this.keyImage.origin = [0, 0];
|
||||
this.keyImage.scale =[this.model.width/314, this.model.width/314];
|
||||
this.keyImage.dirty();
|
||||
}
|
||||
@ -89,40 +90,8 @@ export default class key extends Group {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
setDraggable() {
|
||||
this.keyImage.attr('draggable', true);
|
||||
this.createMouseEvent();
|
||||
}
|
||||
createMouseEvent() {
|
||||
this.on('mousedown', this.mousedown, this);
|
||||
this.on('mousemove', this.mousemove, this);
|
||||
this.on('mouseup', this.mouseup, this);
|
||||
}
|
||||
|
||||
mousedown(e) {
|
||||
this.event.disable();
|
||||
if (e.which == 3) {
|
||||
store.dispatch('ibp/setUpdateDeviceData', this.model);
|
||||
return;
|
||||
}
|
||||
this.offsetX = e.offsetX;
|
||||
this.offsetY = e.offsetY;
|
||||
this.dragging = true;
|
||||
}
|
||||
|
||||
mousemove(e) {
|
||||
}
|
||||
|
||||
mouseup(e) {
|
||||
this.event.enable();
|
||||
if (this.dragging) {
|
||||
this.model.point.x = this.model.point.x + (e.offsetX - this.offsetX);
|
||||
this.model.point.y = this.model.point.y + (e.offsetY - this.offsetY);
|
||||
this.dragging = false;
|
||||
}
|
||||
}
|
||||
getName() {
|
||||
return this.name;
|
||||
setModel(dx, dy) {
|
||||
this.model.point.x+=dx;
|
||||
this.model.point.y+=dy;
|
||||
}
|
||||
}
|
||||
|
@ -2,7 +2,6 @@ import Group from 'zrender/src/container/Group';
|
||||
import Image from 'zrender/src/graphic/Image';
|
||||
import rotateBlack from '@/assets/ibp_images/rotate_black.png';
|
||||
import rotateRed from '@/assets/ibp_images/rotate_red.png';
|
||||
import store from '@/store';
|
||||
|
||||
export default class rotateTip extends Group {
|
||||
|
||||
@ -11,35 +10,37 @@ export default class rotateTip extends Group {
|
||||
this.model = device.model;
|
||||
this.zlevel = device.model.zlevel;
|
||||
this.z = device.model.z;
|
||||
this.event = device.event;
|
||||
this.offsetX = 0;
|
||||
this.offsetY = 0;
|
||||
this.dragging = false;
|
||||
this.name='simple';
|
||||
this._type = device.model._type;
|
||||
this._code = device.model.code;
|
||||
this.create();
|
||||
}
|
||||
|
||||
create() {
|
||||
const model = this.model;
|
||||
this.grouper=new Group({
|
||||
id: model.code,
|
||||
position: [model.point.x, model.point.y]
|
||||
});
|
||||
this.imageBg = new Image({
|
||||
zlevel: this.zlevel,
|
||||
z: this.z,
|
||||
draggable: false,
|
||||
style: {
|
||||
image: this.getRotateColor(),
|
||||
x: model.point.x,
|
||||
y: model.point.y,
|
||||
x: 0,
|
||||
y: 0,
|
||||
width: 68,
|
||||
height: 60
|
||||
}
|
||||
});
|
||||
this.add(this.imageBg);
|
||||
this.grouper.add(this.imageBg);
|
||||
this.add(this.grouper);
|
||||
this.transformScale();
|
||||
}
|
||||
|
||||
/** 缩放按钮 */
|
||||
transformScale() {
|
||||
this.imageBg.origin = [this.model.point.x, this.model.point.y];
|
||||
this.imageBg.origin = [0, 0];
|
||||
this.imageBg.scale =[this.model.width/68, this.model.width/68];
|
||||
this.imageBg.dirty();
|
||||
}
|
||||
@ -58,40 +59,8 @@ export default class rotateTip extends Group {
|
||||
return rotateBlack;
|
||||
}
|
||||
}
|
||||
|
||||
setDraggable() {
|
||||
this.imageBg.attr('draggable', true);
|
||||
this.createMouseEvent();
|
||||
}
|
||||
createMouseEvent() {
|
||||
this.on('mousedown', this.mousedown, this);
|
||||
this.on('mousemove', this.mousemove, this);
|
||||
this.on('mouseup', this.mouseup, this);
|
||||
}
|
||||
|
||||
mousedown(e) {
|
||||
this.event.disable();
|
||||
if (e.which == 3) {
|
||||
store.dispatch('ibp/setUpdateDeviceData', this.model);
|
||||
return;
|
||||
}
|
||||
this.offsetX = e.offsetX;
|
||||
this.offsetY = e.offsetY;
|
||||
this.dragging = true;
|
||||
}
|
||||
|
||||
mousemove(e) {
|
||||
}
|
||||
|
||||
mouseup(e) {
|
||||
this.event.enable();
|
||||
if (this.dragging) {
|
||||
this.model.point.x = this.model.point.x + (e.offsetX - this.offsetX);
|
||||
this.model.point.y = this.model.point.y + (e.offsetY - this.offsetY);
|
||||
this.dragging = false;
|
||||
}
|
||||
}
|
||||
getName() {
|
||||
return this.name;
|
||||
setModel(dx, dy) {
|
||||
this.model.point.x+=dx;
|
||||
this.model.point.y+=dy;
|
||||
}
|
||||
}
|
||||
|
@ -1,68 +1,41 @@
|
||||
import Group from 'zrender/src/container/Group';
|
||||
import Image from 'zrender/src/graphic/Image';
|
||||
import Keyhole from '@/assets/ibp_images/keyhole.png';
|
||||
import store from '@/store';
|
||||
|
||||
export default class RotatingButton extends Group {
|
||||
constructor(device) {
|
||||
super();
|
||||
this.model = device.model;
|
||||
this.event = device.event;
|
||||
this._type = device.model._type;
|
||||
this._code = device.model.code;
|
||||
this.zlevel = device.model.zlevel;
|
||||
this.z = device.model.z;
|
||||
this.offsetX = 0;
|
||||
this.offsetY = 0;
|
||||
this.dragging = false;
|
||||
this.name='simple';
|
||||
this.create();
|
||||
}
|
||||
|
||||
create() {
|
||||
const model = this.model;
|
||||
this.grouper=new Group({
|
||||
id: model.code,
|
||||
position: [model.point.x, model.point.y]
|
||||
});
|
||||
this.rotatingButton = new Image({
|
||||
zlevel: this.zlevel,
|
||||
z: this.z,
|
||||
draggable: false,
|
||||
style: {
|
||||
image: Keyhole,
|
||||
x: this.model.point.x,
|
||||
y: this.model.point.y,
|
||||
width: this.model.width,
|
||||
height: this.model.width/434*381
|
||||
x: 0,
|
||||
y: 0,
|
||||
width: model.width,
|
||||
height: model.width/361*336
|
||||
}
|
||||
});
|
||||
this.add(this.rotatingButton);
|
||||
this.grouper.add(this.rotatingButton);
|
||||
this.add(this.grouper);
|
||||
}
|
||||
|
||||
setDraggable() {
|
||||
this.rotatingButton.attr('draggable', true);
|
||||
this.createMouseEvent();
|
||||
}
|
||||
createMouseEvent() {
|
||||
this.on('mousedown', this.mousedown, this);
|
||||
this.on('mousemove', this.mousemove, this);
|
||||
this.on('mouseup', this.mouseup, this);
|
||||
}
|
||||
mousedown(e) {
|
||||
this.event.disable();
|
||||
if (e.which == 3) {
|
||||
store.dispatch('ibp/setUpdateDeviceData', this.model);
|
||||
return;
|
||||
}
|
||||
this.offsetX = e.offsetX;
|
||||
this.offsetY = e.offsetY;
|
||||
this.dragging = true;
|
||||
}
|
||||
mousemove() {
|
||||
}
|
||||
mouseup(e) {
|
||||
this.event.enable();
|
||||
if (this.dragging) {
|
||||
this.model.point.x = this.model.point.x + (e.offsetX - this.offsetX);
|
||||
this.model.point.y = this.model.point.y + (e.offsetY - this.offsetY);
|
||||
this.dragging = false;
|
||||
}
|
||||
}
|
||||
getName() {
|
||||
return this.name;
|
||||
setModel(dx, dy) {
|
||||
this.model.point.x+=dx;
|
||||
this.model.point.y+=dy;
|
||||
}
|
||||
}
|
||||
|
@ -1,81 +1,50 @@
|
||||
import Group from 'zrender/src/container/Group';
|
||||
import Image from 'zrender/src/graphic/Image';
|
||||
import teleTerminalPic from '@/assets/ibp_images/telephone_terminal.png';
|
||||
import store from '@/store';
|
||||
|
||||
export default class alarm extends Group {
|
||||
|
||||
constructor(device) {
|
||||
super();
|
||||
this.event = device.event;
|
||||
this._type = device.model._type;
|
||||
this._code = device.model.code;
|
||||
this.model = device.model;
|
||||
this.zlevel = device.model.zlevel;
|
||||
this.z = device.model.z;
|
||||
this.offsetX = 0;
|
||||
this.offsetY = 0;
|
||||
this.dragging = false;
|
||||
this.name='simple';
|
||||
this.create();
|
||||
}
|
||||
|
||||
create() {
|
||||
const model = this.model;
|
||||
this.grouper=new Group({
|
||||
id: model.code,
|
||||
position: [model.point.x, model.point.y]
|
||||
});
|
||||
this.imageBg = new Image({
|
||||
zlevel: this.zlevel,
|
||||
z: this.z,
|
||||
draggable: false,
|
||||
style: {
|
||||
image: teleTerminalPic,
|
||||
x: model.point.x,
|
||||
y: model.point.y,
|
||||
x: 0,
|
||||
y: 0,
|
||||
width: 150,
|
||||
height: 150
|
||||
}
|
||||
});
|
||||
this.add(this.imageBg);
|
||||
this.grouper.add(this.imageBg);
|
||||
this.add(this.grouper);
|
||||
this.transformScale();
|
||||
}
|
||||
|
||||
/** 缩放按钮 */
|
||||
transformScale() {
|
||||
this.imageBg.origin = [this.model.point.x, this.model.point.y];
|
||||
this.imageBg.origin = [0, 0];
|
||||
this.imageBg.scale =[this.model.width/150, this.model.width/150];
|
||||
this.imageBg.dirty();
|
||||
}
|
||||
|
||||
setDraggable() {
|
||||
this.imageBg.attr('draggable', true);
|
||||
this.createMouseEvent();
|
||||
}
|
||||
createMouseEvent() {
|
||||
this.on('mousedown', this.mousedown, this);
|
||||
this.on('mousemove', this.mousemove, this);
|
||||
this.on('mouseup', this.mouseup, this);
|
||||
}
|
||||
|
||||
mousedown(e) {
|
||||
this.event.disable();
|
||||
if (e.which == 3) {
|
||||
store.dispatch('ibp/setUpdateDeviceData', this.model);
|
||||
return;
|
||||
}
|
||||
this.offsetX = e.offsetX;
|
||||
this.offsetY = e.offsetY;
|
||||
this.dragging = true;
|
||||
}
|
||||
|
||||
mousemove(e) {
|
||||
}
|
||||
|
||||
mouseup(e) {
|
||||
this.event.enable();
|
||||
if (this.dragging) {
|
||||
this.model.point.x = this.model.point.x + (e.offsetX - this.offsetX);
|
||||
this.model.point.y = this.model.point.y + (e.offsetY - this.offsetY);
|
||||
this.dragging = false;
|
||||
}
|
||||
}
|
||||
getName() {
|
||||
return this.name;
|
||||
setModel(dx, dy) {
|
||||
this.model.point.x+=dx;
|
||||
this.model.point.y+=dy;
|
||||
}
|
||||
}
|
||||
|
11
src/ibp/shape/utils.js
Normal file
11
src/ibp/shape/utils.js
Normal file
@ -0,0 +1,11 @@
|
||||
export function arrow(modelX, modelY, length, radius) {
|
||||
return [
|
||||
[modelX, modelY],
|
||||
[modelX + radius /1.5, modelY - radius/1.5],
|
||||
[modelX + radius /1.5, modelY - radius/3],
|
||||
[modelX + length, modelY - radius/3],
|
||||
[modelX + length, modelY + radius/3],
|
||||
[modelX + radius /1.5, modelY + radius/3],
|
||||
[modelX + radius /1.5, modelY + radius/1.5]
|
||||
];
|
||||
}
|
@ -10,6 +10,574 @@ class SkinCode extends defaultStyle {
|
||||
linkColor: '#3F3F3F', // link 线条颜色
|
||||
linkTextColor: '#FFFFFF' // link 字体颜色
|
||||
};
|
||||
|
||||
this[deviceType.Section] = {
|
||||
active: {
|
||||
routeColor: false // 进路触发颜色
|
||||
},
|
||||
text: { // 物理区段名称
|
||||
show: true, // 物理区段名称显示
|
||||
position: -1, // 区段名称位置 1 上面 -1 下面 0 对称
|
||||
distance: 11, // 文字离区段距离
|
||||
fontSize: 11, // 字体大小
|
||||
fontWeight: 'normal', // 字体粗细
|
||||
fontColor: '#FFFFFF', // 字体颜色
|
||||
textAlign: 'center', // 水平对齐方式
|
||||
textPosition: 'inside', // 文字位置
|
||||
textVerticalAlign: 'middle' // 文字垂直对齐方式
|
||||
},
|
||||
logicText: { // 逻辑区段名称
|
||||
show: false, // 逻辑区段名称显示
|
||||
position: -1, // 区段名称位置 1 上面 -1 下面 0 对称
|
||||
distance: 11, // 文字离区段距离
|
||||
fontSize: 11, // 字体大小
|
||||
fontWeight: 'normal', // 字体粗细
|
||||
fontColor: '#FFFFFF', // 字体颜色
|
||||
textAlign: 'center', // 水平对齐方式
|
||||
textPosition: 'inside', // 文字位置
|
||||
textVerticalAlign: 'middle' // 文字垂直对齐方式
|
||||
},
|
||||
standText: { // 站台轨名称
|
||||
show: true, // 站台轨名称显示
|
||||
opposite: true, // 对称相反
|
||||
position: 1, // 区段名称位置 1 上面 -1 下面 0 对称
|
||||
distance: 11, // 文字离区段距离
|
||||
fontSize: 11, // 字体大小
|
||||
fontWeight: 'normal', // 字体粗细
|
||||
fontColor: '#FFFFFF', // 字体颜色
|
||||
textAlign: 'center', // 水平对齐方式
|
||||
textPosition: 'inside', // 文字位置
|
||||
textVerticalAlign: 'middle' // 文字垂直对齐方式
|
||||
},
|
||||
reentryText: { // 折返轨名称
|
||||
show: true, // 折返轨名称显示
|
||||
opposite: true, // 对称相反
|
||||
position: 1, // 区段名称位置 1 上面 -1 下面 0 对称
|
||||
distance: 11, // 文字离区段距离
|
||||
fontSize: 11, // 字体大小
|
||||
fontWeight: 'normal', // 字体粗细
|
||||
fontColor: '#FFFFFF', // 字体颜色
|
||||
textAlign: 'center', // 水平对齐方式
|
||||
textPosition: 'inside', // 文字位置
|
||||
textVerticalAlign: 'middle' // 文字垂直对齐方式
|
||||
},
|
||||
transferText: { // 转换轨名称
|
||||
show: true, // 转换轨名称显示
|
||||
opposite: true, // 对称相反
|
||||
position: 1, // 区段名称位置 1 上面 -1 下面 0 对称
|
||||
distance: 11, // 文字离区段距离
|
||||
fontSize: 11, // 字体大小
|
||||
fontWeight: 'normal', // 字体粗细
|
||||
fontColor: '#FFFFFF', // 字体颜色
|
||||
textAlign: 'center', // 水平对齐方式
|
||||
textPosition: 'inside', // 文字位置
|
||||
textVerticalAlign: 'middle' // 文字垂直对齐方式
|
||||
},
|
||||
destinationText: { // 目的码名称
|
||||
show: true, // 目的码名称显示
|
||||
position: 1, // 区段名称位置 1 上面 -1 下面 0 对称
|
||||
distance: 11, // 文字离区段距离
|
||||
fontSize: 11, // 字体大小
|
||||
fontWeight: 'bold', // 字体粗细
|
||||
fontColor: 'yellow', // 字体颜色
|
||||
textAlign: 'center', // 水平对齐方式
|
||||
textPosition: 'inside', // 文字位置
|
||||
textVerticalAlign: 'middle' // 文字垂直对齐方式
|
||||
},
|
||||
mouseOverStyle: {
|
||||
borderColor: '#fff',
|
||||
borderBackgroundColor: '#22DFDF',
|
||||
textShadowColor: '#22DFDF'
|
||||
},
|
||||
line: {
|
||||
width: 5, // 区段宽度
|
||||
beyondWidth: 0, // 区段宽超出宽度
|
||||
invadeColor: '#EF0C08', // 区段侵入颜色
|
||||
spareColor: '#606060', // 区段空闲颜色
|
||||
communicationOccupiedColor: '#FF0000', // 区段通信车占用颜色
|
||||
unCommunicationOccupiedColor: '#800080', // 区段非通讯车占用颜色
|
||||
routeLockColor: '#FFFFFF', // 区段路由锁定颜色
|
||||
faultLockColor: '#006400', // 区段故障锁定颜色
|
||||
undefinedColor: '#0071C1', // 区段未定义颜色
|
||||
protectionLockedColor: '#FEFF00', // 保护区段锁闭(未用)
|
||||
blockColor: '#800080', // 区段封锁颜色
|
||||
atcExcisionColor: '#A0522D', // 区段atc切除颜色
|
||||
atsExcisionColor: '#A0522D', // 区段ats切除颜色
|
||||
timeReleaseColor: '#3F3F3F', // 区段延时释放颜色
|
||||
protectiveLockColor: '#FFFF00', // 区段保护锁闭
|
||||
protectiveTimeReleaseColor: '#0071C1', // 区段保护延时解锁
|
||||
logicalColor: '#FFFF00', // 逻辑区段颜色 (未用)
|
||||
logicalTextColor: '#C0C0C0' // 逻辑区段名称颜色 (未用)
|
||||
},
|
||||
axle: {
|
||||
radius: 3, // 计轴 半径
|
||||
distance: 5, // 计轴和区段之间的距离 (未用)
|
||||
color: '#C0C0C0', // 区段计轴颜色
|
||||
resetColor: '#00FFFF', // 区段计轴预复位颜色
|
||||
Failure: '#E6A23C' // #FFFF00 计轴失效
|
||||
},
|
||||
speedLimit: { // 限速元素
|
||||
width: 1, // 限速线的宽度
|
||||
distance: 5, // 限速线距离区段距离
|
||||
lineColor: '#FFFF00', // 限速线颜色
|
||||
nameShow: false // 名称显示
|
||||
},
|
||||
separator: {
|
||||
z: 1, // 分割符层级
|
||||
width: 1.5, // 分隔符宽度
|
||||
endWidth: 1.5, // 尽头分隔符宽度
|
||||
endColor: '#7F7F7F', // 尽头分隔符颜色
|
||||
color: '#7F7F7F' // 区段边界符颜色
|
||||
}
|
||||
};
|
||||
|
||||
this[deviceType.Signal] = {
|
||||
distance: 0, // 设备距离区段的距离
|
||||
post: {
|
||||
standardColor: '#5578B6', // 灯灯柱颜色
|
||||
standardWidth: 1.5 // 灯柱宽度
|
||||
},
|
||||
text: {
|
||||
show: true, // 信号机名称显示
|
||||
distance: 3, // 文字和灯杆的距离
|
||||
isNoRotation: true, // 是否禁止旋转
|
||||
isAlignCenter: false, // 信号字体对其方式
|
||||
fontSize: 11, // 信号机名称字体大小
|
||||
fontWeight: 'bold', // 信号机名称字体粗细
|
||||
defaultColor: '#C0C0C0', // 信号灯字体默认色
|
||||
blockColor: '#EF0C08', // 信号灯字体锁定颜色
|
||||
checkColor: '#00FF00' // 信号字体
|
||||
},
|
||||
lamp: {
|
||||
stopWidth: 2, // 禁止线宽度
|
||||
borderVariable: true, // 信号灯边框可变
|
||||
borderWidth: 0.5, // 信号灯边框线宽度
|
||||
borderColor: '#3149C3', // 信号灯边框线颜色
|
||||
radiusR: 5, // 信号机宽度
|
||||
blockColor: '#EF0C08', // 信号灯锁闭
|
||||
grayColor: '#7F7F7F', // 信号灯灰色
|
||||
redColor: '#FF0000', // 信号灯红色
|
||||
greenColor: '#00FF00', // 信号灯绿色
|
||||
yellowColor: '#FFFF00', // 信号灯黄色
|
||||
whiteColor: '#FFFFFF', // 信号灯白色
|
||||
blueColor: '#0070C0' // 信号灯蓝色
|
||||
},
|
||||
route: {
|
||||
direction: false, // 自动进路方向
|
||||
offset: { x: 1, y: -2 }, // 自动进路偏移量
|
||||
routeColor: '#00FF00' // 自动进路
|
||||
},
|
||||
auto: {
|
||||
direction: true, // 自动通过方向
|
||||
offset: { x: 4, y: 0}, // 自动通过偏移量
|
||||
width: 5, // 自动宽度
|
||||
autoRoute: '#00FF00', // 自动进路
|
||||
autoTrigger: '#FFFF00', // 自动触发
|
||||
manualControl: '#FFFF00', // 人工控制
|
||||
outConflict: '#C00808' // 出车冲突
|
||||
},
|
||||
delay: {
|
||||
direction: false, // 延时解锁方向
|
||||
offset: { x: 0, y: -5}, // 延时解锁偏移量
|
||||
fontSize: 9, // 延迟解锁字体大小
|
||||
fontColor: '#FF0000', // 延迟解锁颜色
|
||||
fontWeight: 'bold' // 字体粗细
|
||||
},
|
||||
button: {
|
||||
distance: 5, // 信号灯按钮距离区段的距离
|
||||
borderDashColor: '#FFFFFF', // 信号灯按钮边线
|
||||
buttonColor: 'darkgreen', // 信号灯按钮颜色
|
||||
buttonLightenColor: '#E4EF50' // 信号灯按钮闪烁颜色
|
||||
},
|
||||
mouseOverStyle: {
|
||||
borderLineColor: '#FFFFFF',
|
||||
borderLineDash: [3, 3],
|
||||
nameBackgroundColor: '#22DFDF',
|
||||
lampBorderLineColor: '#22DFDF'
|
||||
}
|
||||
};
|
||||
|
||||
this[deviceType.StationStand] = {
|
||||
common: { // 通用属性
|
||||
textFontSize: 8 // 站台默认字体大小
|
||||
},
|
||||
safetyDoor: { // 屏蔽门
|
||||
height: 1.6, // 站台屏蔽门高度
|
||||
distance: 9, // 站台和屏蔽门之间的距离
|
||||
defaultColor: '#00FF00', // 屏蔽门默认颜色
|
||||
splitDoorColor: '#F61107' // 屏蔽门切除颜色
|
||||
},
|
||||
stand: { // 站台
|
||||
headFontSize: 8, // 站台首端字体大小
|
||||
spareColor: '#606060', // 站台空闲颜色
|
||||
stopColor: '#FEFE00', // 站台列车停站颜色
|
||||
jumpStopColor: '#9A99FF', // 站台跳停颜色
|
||||
designatedJumpStopColor: 'lightSkyBlue' // 站台指定列车跳停颜色
|
||||
},
|
||||
standEmergent: { // 紧急关闭
|
||||
mergentR: 4, // 站台紧急关闭半径
|
||||
offset: {x: 0, y: 0}, // 站台紧急关闭偏移量
|
||||
closeColor: '#F61107' // 站台紧急关闭颜色
|
||||
},
|
||||
reentry: { // 站台折返策略
|
||||
position: 0, // 折返方向
|
||||
offset: {x: -16, y: 18}, // 折返偏移量
|
||||
noHumanColor: '#0F16DA', // 站台无人折返
|
||||
autoChangeEndsColor: '#0BF400' // 站台自动换端
|
||||
},
|
||||
detainCar: { // 扣车
|
||||
text: 'H', // 扣车显示内容
|
||||
position: 1, // 扣车方向
|
||||
offset: {x: -8, y: 13}, // 扣车偏移量
|
||||
trainColor: '#E4EF50', // 车站扣车颜色
|
||||
centerTrainColor: '#FFFFFF', // 中心扣车颜色
|
||||
andCenterTrainColor: '#F61107', // 车站+中心扣车颜色
|
||||
detainTrainTextColor: '#E4EF50' // 车站扣除文字颜色
|
||||
},
|
||||
stopTime: { // 停站时间
|
||||
position: 1, // 运行时间方向
|
||||
offset: {x: -8, y: 3}, // 运行时间偏移量
|
||||
textColor: '#FFFFFF' // 停站时间字体颜色
|
||||
},
|
||||
level: { // 运行等级
|
||||
position: 1, // 运行等级方向
|
||||
offset: {x: -8, y: 22}, // 运行等级偏移量
|
||||
textColor: '#FFFFFF' // 停站等级字体颜色
|
||||
},
|
||||
mouseOverStyle: {
|
||||
borderLineColor: '#FFFFFF',
|
||||
borderLineDash: [3, 3]
|
||||
}
|
||||
};
|
||||
|
||||
this[deviceType.StationControl] = {
|
||||
text: {
|
||||
distance: 2, // 灯和文字之间的距离
|
||||
fontSize: 10, // 控制模式字体大小
|
||||
fontFormat: 'consolas', // 控制模式字体格式
|
||||
fontColor: '#ffffff', // 控制模式字体颜色
|
||||
fontWeight: 'normal', // 控制模式字体粗细
|
||||
textAlign: 'middle', // 控制模式水平对齐
|
||||
textVerticalAlign: 'top' // 控制模式垂直对齐
|
||||
},
|
||||
lamp: {
|
||||
count: 3, // 控制模式灯个数
|
||||
offset: { x: 20, y: 0 }, // 偏移量
|
||||
radiusR: 6, // 控制模式灯的半径
|
||||
distance: 36, // 控制模式之间灯之间的距离
|
||||
grayColor: '#7F7F7F', // 控制模式灰色
|
||||
greenColor: '#00FF00', // 控制模式绿色
|
||||
redColor: '#FF0000', // 控制模式红色
|
||||
yellowColor: '#FFFF00', // 控制模式黄色
|
||||
emergencyControlShow: true, // 紧急站控显示
|
||||
centerControlShow: true, // 中控显示
|
||||
substationControlShow: true, // 站控按钮显示
|
||||
interconnectedControlShow: false // 联锁控显示
|
||||
},
|
||||
arrow: {
|
||||
show: false // 控制模式箭头显隐
|
||||
},
|
||||
mouseOverStyle: { // 鼠标悬浮样式
|
||||
fontSize: 10,
|
||||
fontFormat: 'consolas',
|
||||
fontColor: '#FFF000',
|
||||
fontWeight: 'normal',
|
||||
textAlign: 'middle',
|
||||
textVerticalAlign: 'top'
|
||||
}
|
||||
};
|
||||
|
||||
this[deviceType.StationCounter] = {
|
||||
text: {
|
||||
distance: 2, // 计数器名称和文字的距离
|
||||
fontColor: '#FFFFFF', // 计数器字体颜色
|
||||
borderColor: '#E4EF50' // 计数器边框颜色
|
||||
}
|
||||
};
|
||||
|
||||
this[deviceType.StationDelayUnlock] = {
|
||||
text: {
|
||||
distance: 3, // 延迟解锁和设备之间的距离
|
||||
fontColor: '#FFFFFF', // 延时解锁字体颜色
|
||||
borderColor: '#FFFFFF' // 延迟解锁边框颜色
|
||||
}
|
||||
};
|
||||
|
||||
this[deviceType.Station] = {
|
||||
// text: {
|
||||
// show: true // 公里标名称显示
|
||||
// },
|
||||
kmPostShow: true, // 公里标显示
|
||||
kilometerPosition: 'down', // 公里标位置
|
||||
fontWeight: 'bold' // 文字错细
|
||||
};
|
||||
|
||||
this[deviceType.Switch] = {
|
||||
text: {
|
||||
show: true, // 道岔名称显示
|
||||
position: 0, // 区段名称位置 1 上面 -1 下面 0 对称
|
||||
offset: {x: -15, y: -10}, // 道岔名称与区段距离
|
||||
fontSize: 10, // 字体大小
|
||||
fontColor: '#C0C0C0', // 道岔名称颜色
|
||||
fontWeight: 'normal', // 字体粗细
|
||||
borderColor: '#FE0000', // 道岔边框颜色
|
||||
lossColor: '#FFFFFF', // 道岔失去颜色
|
||||
locateColor: '#00FF00', // 道岔定位颜色
|
||||
inversionColor: '#9C9D09', // 道岔反位颜色
|
||||
monolockColor: '#870E10' // 道岔单锁颜色
|
||||
},
|
||||
core: {
|
||||
length: 6 // 道岔单边长度
|
||||
},
|
||||
monolock: { // 道岔单锁配置
|
||||
locationColor: '#870E10', // 道岔单锁定位颜色 (红色)
|
||||
inversionColor: '#870E10', // 道岔单锁反位颜色 (红色)
|
||||
rectShow: false // 道岔单锁 矩形框是否显示
|
||||
},
|
||||
block: { // 道岔封锁配置
|
||||
nameBorderShow: true, // 道岔名称是否有包围框 显示
|
||||
contentRectShow: false // 道岔封锁显示
|
||||
},
|
||||
mouseOverStyle: {
|
||||
borderBackgroundColor: '#22DFDF', // 边框背景色
|
||||
borderColor: '#fff', // 边框颜色
|
||||
textShadowColor: '#22DFDF' // 字体阴影颜色
|
||||
}
|
||||
};
|
||||
|
||||
this[deviceType.LcControl] = {
|
||||
text: {
|
||||
fontSize: 10, // 灯字体大小
|
||||
fontWeight: 'normal', // 字体粗细
|
||||
distance: 5 // 灯跟文字距离
|
||||
},
|
||||
lamp: {
|
||||
radiusR: 6, // 灯大小
|
||||
controlColor: '#FFFF00' // 灯颜色
|
||||
},
|
||||
mouseOverStyle: {
|
||||
fontSize: 10,
|
||||
fontFormat: 'consolas',
|
||||
fontColor: '#FFF000',
|
||||
fontWeight: 'normal',
|
||||
textAlign: 'middle',
|
||||
textVerticalAlign: 'top',
|
||||
arcColor: '#00FFFF',
|
||||
textColor: '#000000'
|
||||
}
|
||||
};
|
||||
|
||||
this[deviceType.ZcControl] = {
|
||||
text: {
|
||||
fontSize: 10, // 字体大小
|
||||
fontWeight: 'normal', // 字体粗细
|
||||
distance: 5 // 灯跟文字距离
|
||||
},
|
||||
lamp: {
|
||||
radiusR: 6, // 灯大小
|
||||
controlColor: '#00FF00' // 灯颜色
|
||||
},
|
||||
mouseOverStyle: {
|
||||
fontSize: 10,
|
||||
fontFormat: 'consolas',
|
||||
fontColor: '#FFF000',
|
||||
fontWeight: 'normal',
|
||||
textAlign: 'middle',
|
||||
textVerticalAlign: 'top',
|
||||
arcColor: '#00FFFF',
|
||||
textColor: '#000000'
|
||||
}
|
||||
};
|
||||
|
||||
this[deviceType.LimitControl] = {
|
||||
text: {
|
||||
fontSize: 10, // 字体大小
|
||||
fontWeight: 'normal', // 字体粗细
|
||||
distance: 5 // 灯跟文字距离
|
||||
},
|
||||
lamp: {
|
||||
radiusR: 6, // 灯大小
|
||||
controlColor: '#ECE9D8' // 灯颜色
|
||||
},
|
||||
mouseOverStyle: {
|
||||
fontSize: 10,
|
||||
fontFormat: 'consolas',
|
||||
fontColor: '#FFF000',
|
||||
fontWeight: 'normal',
|
||||
textAlign: 'middle',
|
||||
textVerticalAlign: 'top',
|
||||
textColor: '#000000',
|
||||
arcColor: '#00FFFF'
|
||||
}
|
||||
};
|
||||
|
||||
this[deviceType.Line] = {
|
||||
lineColor: '#FFFFFF' // 线条颜色
|
||||
};
|
||||
|
||||
this[deviceType.TrainWindow] = {
|
||||
lineColor: '#FFF', // 车次窗颜色
|
||||
lineDash: [3, 3], // 车次窗虚线间隔
|
||||
lineWidth: 1, // 车次窗线宽
|
||||
trainWindowSmooth: 0.01 // 车次窗矩形圆滑程度
|
||||
};
|
||||
|
||||
this[deviceType.Train] = {
|
||||
trainBody: {
|
||||
trainBodyLineWidth: 0.1, // 车身line宽
|
||||
changeTrainWidth: false, // 是否根据车身上车组号、服务号、车次号、目的地码显示情况改变列车长度
|
||||
specialTrainType: [
|
||||
{
|
||||
type: '03',
|
||||
serviceNumber: 'M0',
|
||||
nameFormat: 'serviceNumber:groupNumber'
|
||||
},
|
||||
{
|
||||
type: '02',
|
||||
nameFormat: 'targetCode:groupNumber'
|
||||
}
|
||||
], // 特殊列车类型需设置显示格式
|
||||
lrPadding: 4, // 两边间隔
|
||||
upPadding: 4, // 上边距离
|
||||
trainBodyFillColor: '#725A64', // 列车车身填充颜色
|
||||
trainNameFormat: 'serviceNumber:tripNumber'// 列车显示格式
|
||||
},
|
||||
hsda: {
|
||||
lrPaddingHSDA: 3, // HSDA两边间隔
|
||||
upPaddingHSDA: 4, // HSDA上边距离
|
||||
trainHSDATextFontSize: 9, // 列车HDSA字号
|
||||
textHContent: 'H', // textH文本
|
||||
textSContent: 'S', // textS文本
|
||||
textDContent: 'D', // textD文本
|
||||
textAContent: 'A'// textA文本
|
||||
},
|
||||
trainNumber: {
|
||||
trainNumberOffset: { x: 0, y: 1}// 目的地码偏移量
|
||||
},
|
||||
trainServer: {
|
||||
serviceNumberPrefix: '00', // 服务号(表号)前缀
|
||||
defaultServiceNumber: 'AA', // 默认服务号(表号)
|
||||
trainServerOffset: { x: 4, y: 4}// 列车服务号偏移
|
||||
},
|
||||
trainTarget: {
|
||||
tripNumberPrefix: '000', // 车次号前缀
|
||||
defaultTripNumber: 'DDD', // 默认车次号2
|
||||
trainTargetOffset: { x: 36, y: 4}, // 列车车次号偏移
|
||||
trainTargetTextAlign: 'left'// 车次号文字显示位置
|
||||
},
|
||||
trainTargetNumber: {
|
||||
trainTargetNumberOffset: {x: 0, y: 0}// 车组号偏移量
|
||||
},
|
||||
trainHead: {
|
||||
trainMoreLength: 0, // 列车车头比车身高出的长度,上下相比车体伸出去的边框
|
||||
trainHeadTriangleFirst: { x: 7, y: 1}, // 列车车头三角坐标1偏移量
|
||||
trainHeadTriangleSecond: { x: 13, y: 10}, // 列车车头三角坐标2偏移量
|
||||
trainHeadTriangleThird: { x: 7, y: 19}, // 列车车头三角坐标3偏移量
|
||||
trainHeadRectHeight: 20, // 列车车头矩形高度
|
||||
trainConntWidth: 3, // 列车竖杠的宽度
|
||||
trainHeadFillColor: '#000000'// 列车车头矩形填充颜色
|
||||
},
|
||||
common: {
|
||||
trainHeight: 20, // 列车高度
|
||||
trainHeadDistance: 4, // 列车和车头之间的间距
|
||||
trainWidth: 40, // 列车长度
|
||||
trainTextFontSize: 12, // 列车字号
|
||||
fontFamily: 'consolas', // 默认字体 族类
|
||||
haveTextHSDA: true, // 是否需创建textHSDA对象
|
||||
haveArrowText: true, // 是否需创建arrowText对象
|
||||
haveTrainBorder: false, // 是否需创建trainBorder对象
|
||||
textOffset: 4, // 字体偏移(用以控制字体据车头的距离)
|
||||
trainWidthMoreText: 8, // 计算列车长度时--列车长比text多出尺寸
|
||||
useSelfFormat: true, // 使用配置项的nameFormat
|
||||
useSelfText: true // 使用配置项的字体大小
|
||||
},
|
||||
trainStatusStyle: {
|
||||
destinationStatus: [
|
||||
{status: '01', showColor: '#FFFFFF'},
|
||||
{status: '02', showColor: '#00FF00'},
|
||||
{status: '03', showColor: '#A0522D'},
|
||||
{status: '04', showColor: '#FFFF00'}
|
||||
], // 目的地状态 01准点 02早点 03晚点 04头码车
|
||||
defaultDestinationColor: '#FFFFFF', // 默认目的地状态显示颜色
|
||||
destinationStatusSetText: 'trainTarget', // 目的地状态设置的对应哪个text的颜色
|
||||
directionType: [
|
||||
{
|
||||
type: '01',
|
||||
lineLShow: true,
|
||||
lineRShow: true,
|
||||
arrowLShow: false,
|
||||
arrowRShow: false
|
||||
},
|
||||
{
|
||||
type: '02',
|
||||
lineLShow: false,
|
||||
lineRShow: true,
|
||||
arrowLShow: false,
|
||||
arrowRShow: true
|
||||
},
|
||||
{
|
||||
type: '03',
|
||||
lineLShow: true,
|
||||
lineRShow: false,
|
||||
arrowLShow: true,
|
||||
arrowRShow: false
|
||||
}
|
||||
], // 列车运行方向状态类型对应车头显示状态 01未知方向 02从左往右 上行 03从右往左 下行
|
||||
directionStopType: [
|
||||
{type: '01', lineLShow: false, lineRShow: false},
|
||||
{type: '02', lineLShow: false, lineRShow: true},
|
||||
{type: '03', lineLShow: true, lineRShow: false}
|
||||
], // 列车停止方向类型对应车头显示状态 01未知方向 02从左往右 上行 03从右往左 下行
|
||||
runModeStatus: [
|
||||
{
|
||||
status: '01',
|
||||
trainLColor: '#FFFFFF',
|
||||
trainRColor: '#FFFFFF'
|
||||
},
|
||||
{
|
||||
status: '02',
|
||||
trainLColor: '#00FF00',
|
||||
trainRColor: '#00FF00'
|
||||
},
|
||||
{
|
||||
status: '03',
|
||||
trainLColor: '#FFFF00',
|
||||
trainRColor: '#FFFF00'},
|
||||
{
|
||||
status: '04',
|
||||
trainLColor: '#A0522D',
|
||||
trainRColor: '#A0522D'
|
||||
},
|
||||
{
|
||||
status: '05',
|
||||
trainLColor: '#A0522D',
|
||||
trainRColor: '#A0522D'
|
||||
}
|
||||
], // 列车运行模式对应车头颜色 01未知 02 ATO自动驾驶模式AM 03 ATP监控下的人工驾驶模式CM 04 限制人工驾驶模式RM 05 非限制人工驾驶模式RM
|
||||
runControlStatus: [
|
||||
{status: '01', hShow: false, sShow: false},
|
||||
{status: '02', hShow: true, sShow: false},
|
||||
{status: '03', hShow: false, sShow: true}
|
||||
], // 设置运行控制状态类型 01正常 02扣车 03停跳
|
||||
doorStatus: [
|
||||
{status: '01', dShow: false},
|
||||
{status: '02', dShow: true}
|
||||
], // 设置车门状态类型 01关门 02开门
|
||||
communicationStatus: [
|
||||
{status: '01', trainColor: '#725A64'},
|
||||
{status: '02', trainColor: '#C0C0C0'}
|
||||
], // 设置通信状态 01正常 02故障
|
||||
alarmStatus: [
|
||||
{status: '01', aShow: false},
|
||||
{status: '02', aShow: true}
|
||||
], // 设置报警状态 01不报警 02报警
|
||||
serverNoType: [
|
||||
{type: '01', showColor: '#FFFFFF'},
|
||||
{type: '02', showColor: '#FFF000'}
|
||||
], // 服务号状态类型 01显示服务号 计划车 02显示车组号: 头码车与人工车
|
||||
defaultServerNoColor: '#FFFFFF' // 默认服务号状态显示颜色
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -154,6 +154,7 @@ class Jlmap {
|
||||
const oDevice = this.mapDevice[code] || deviceFactory(type, elem);
|
||||
const nDevice = Object.assign(oDevice || {}, elem);
|
||||
this.$painter.delete(oDevice);
|
||||
delete this.mapDevice[code];
|
||||
if (!elem._dispose) {
|
||||
this.mapDevice[code] = nDevice;
|
||||
this.$painter.add(nDevice);
|
||||
|
@ -135,7 +135,7 @@ class MouseController extends Eventful {
|
||||
scale = -1;
|
||||
}
|
||||
|
||||
this.trigger(this.events.__Zoom, {type: 'zoom', scale, originX, originY });
|
||||
this.trigger(this.events.__Zoom, {type: this.events.__Zoom, scale, originX, originY });
|
||||
}
|
||||
}
|
||||
|
||||
@ -192,10 +192,6 @@ class MouseController extends Eventful {
|
||||
|
||||
return newEm;
|
||||
}
|
||||
|
||||
updateDatazoom(zoom) {
|
||||
this.trigger(this.events.Datazoom, zoom);
|
||||
}
|
||||
}
|
||||
|
||||
export default MouseController;
|
||||
|
39
src/jmap/shape/Link/EMouse.js
Normal file
39
src/jmap/shape/Link/EMouse.js
Normal file
@ -0,0 +1,39 @@
|
||||
import Group from 'zrender/src/container/Group';
|
||||
import Rect from 'zrender/src/graphic/shape/Rect';
|
||||
// import Vue from 'vue';
|
||||
// import store from '@/store';
|
||||
|
||||
class EMouse extends Group {
|
||||
constructor(device) {
|
||||
super();
|
||||
this.device = device;
|
||||
this.create();
|
||||
}
|
||||
create() {
|
||||
if (this.device.link) {
|
||||
const rect = this.device.link.getBoundingRect();
|
||||
this.lineBorder = new Rect({
|
||||
zlevel: this.device.zlevel,
|
||||
z: this.device.z - 1,
|
||||
shape: rect,
|
||||
style: {
|
||||
lineDash: [3, 3],
|
||||
stroke: '#fff',
|
||||
fill: this.device.style.transparentColor
|
||||
}
|
||||
});
|
||||
|
||||
this.add(this.lineBorder);
|
||||
this.lineBorder.hide();
|
||||
}
|
||||
}
|
||||
|
||||
mouseover(e) {
|
||||
this.lineBorder && this.lineBorder.show();
|
||||
}
|
||||
|
||||
mouseout(e) {
|
||||
this.lineBorder && this.lineBorder.hide();
|
||||
}
|
||||
}
|
||||
export default EMouse;
|
@ -1,5 +1,6 @@
|
||||
import Line from 'zrender/src/graphic/shape/Line';
|
||||
import Group from 'zrender/src/container/Group';
|
||||
import EMouse from './EMouse';
|
||||
|
||||
class Link extends Group {
|
||||
constructor(model, style) {
|
||||
@ -20,7 +21,7 @@ class Link extends Group {
|
||||
if (model.lp.x !== model.rp.x && model.lp.y !== model.rp.y) {
|
||||
textPosition = model.lp.y > model.rp.y ? 'insideLeft' : 'insideRight';
|
||||
}
|
||||
|
||||
// 标准link
|
||||
this.link = new Line({
|
||||
zlevel: this.zlevel,
|
||||
z: 0,
|
||||
@ -43,6 +44,14 @@ class Link extends Group {
|
||||
}
|
||||
});
|
||||
this.add(this.link);
|
||||
const path = window.location.href;
|
||||
if (path.includes('/map/draw')) {
|
||||
// 鼠标事件
|
||||
this.mouseEvent = new EMouse(this);
|
||||
this.add(this.mouseEvent);
|
||||
this.on('mouseout', (e) => { this.mouseEvent.mouseout(e); });
|
||||
this.on('mouseover', (e) => { this.mouseEvent.mouseover(e); });
|
||||
}
|
||||
}
|
||||
|
||||
setState(model) {
|
||||
|
@ -1,11 +1,12 @@
|
||||
<template>
|
||||
<div class="menus" :style="{width: width + 'px'}">
|
||||
<menu-cancel ref="menuCancel" />
|
||||
<template v-if="!isScreen">
|
||||
<menu-bar v-show="isShowMenu" ref="menuBar" :selected="selected" />
|
||||
<menu-tool v-show="isShowMenu" ref="menuTool" :selected="selected" />
|
||||
<status-bar v-show="isShowMenu" ref="statusBar" :selected="selected" />
|
||||
|
||||
<template v-show="!isScreen">
|
||||
<template v-show="isShowMenu">
|
||||
<menu-bar ref="menuBar" :selected="selected" />
|
||||
<menu-tool ref="menuTool" :selected="selected" />
|
||||
<status-bar ref="statusBar" :selected="selected" />
|
||||
</template>
|
||||
<menu-station-control ref="menuStationControl" :selected="selected" />
|
||||
<menu-station-stand ref="menuStationStand" :selected="selected" />
|
||||
<menu-switch ref="menuSwitch" :selected="selected" />
|
||||
@ -68,7 +69,8 @@ export default {
|
||||
'width'
|
||||
]),
|
||||
isScreen() {
|
||||
return this.$route.params.mode == 'dp';
|
||||
return this.$route.params.mode == 'dp' ||
|
||||
this.$store.state.training.roles == 'BigScreen';
|
||||
},
|
||||
isShowMenu() {
|
||||
return this.$store.state.training.prdType != '';
|
||||
|
@ -6,12 +6,10 @@
|
||||
|
||||
<script>
|
||||
import PopMenu from '@/components/PopMenu';
|
||||
// import OperateHandler from '@/scripts/plugin/trainingOperateHandler';
|
||||
import { mapGetters } from 'vuex';
|
||||
import { DeviceMenu } from '@/scripts/ConstDic';
|
||||
import { exitFullscreen } from '@/utils/screen';
|
||||
import { runDiagramQuit } from '@/api/simulation';
|
||||
// import { screenTopic, clearSubscribe } from '@/utils/stomp';
|
||||
import { EventBus } from '@/scripts/event-bus';
|
||||
|
||||
export default {
|
||||
@ -47,7 +45,8 @@ export default {
|
||||
'stationList'
|
||||
]),
|
||||
isScreen() { // 大屏隐藏所有菜单
|
||||
return this.$route.params.mode === 'dp';
|
||||
return this.$route.params.mode === 'dp' ||
|
||||
this.$store.state.training.roles == 'BigScreen';
|
||||
},
|
||||
group() {
|
||||
return this.$route.query.group;
|
||||
@ -56,8 +55,8 @@ export default {
|
||||
watch: {
|
||||
'$store.state.menuOperation.buttonOperation': function (val, old) {
|
||||
if (!this.isScreen && this.menu && this.menu.length > 1) {
|
||||
this.menu[0].disabled = (this.menu[0] && val) ? true : true;
|
||||
this.menu[1].disabled = !((this.menu[1] && val));
|
||||
// this.menu[0].disabled = (this.menu[0] && val) ? true : true;
|
||||
// this.menu[1].disabled = !((this.menu[1] && val));
|
||||
}
|
||||
},
|
||||
'$store.state.menuOperation.menuCount': function (val) {
|
||||
|
@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<div class="menus" :style="{width: width + 'px'}">
|
||||
<menu-cancel ref="menuCancel" />
|
||||
<template v-if="isShowAll">
|
||||
<template v-show="isShowAll">
|
||||
<menu-bar v-show="isShowBar" ref="menuBar" :selected="selected" />
|
||||
<menu-button ref="menuButton" />
|
||||
<menu-station-control ref="menuStationControl" :selected="selected" />
|
||||
@ -68,7 +68,8 @@ export default {
|
||||
]),
|
||||
isShowAll() {
|
||||
return this.$route.params.mode !== 'dp' &&
|
||||
this.$route.params.mode !== 'plan';
|
||||
this.$route.params.mode !== 'plan' &&
|
||||
this.$store.state.training.roles != 'BigScreen';
|
||||
},
|
||||
isShowBar() {
|
||||
return this.$store.state.training.prdType != '';
|
||||
|
@ -45,7 +45,8 @@ export default {
|
||||
'stationList'
|
||||
]),
|
||||
isScreen() { // 大屏隐藏所有菜单
|
||||
return this.$route.params.mode === 'dp';
|
||||
return this.$route.params.mode === 'dp' ||
|
||||
this.$store.state.training.roles == 'BigScreen';
|
||||
},
|
||||
group() {
|
||||
return this.$route.query.group;
|
||||
@ -75,33 +76,33 @@ export default {
|
||||
},
|
||||
initMenu() {
|
||||
this.menuNormal = [];
|
||||
// this.stationList.forEach(station => {
|
||||
// if (station.code === station.concentrateStationCode) {
|
||||
// let node = {
|
||||
// label: station.name,
|
||||
// children: []
|
||||
// }
|
||||
//
|
||||
// this.stationList.forEach(elem => {
|
||||
// if (elem.visible) {
|
||||
// let next = elem;
|
||||
// while (next.code != next.concentrateStationCode || !next.concentrateStationCode) {
|
||||
// next = this.$store.getters['map/getDeviceByCode'](next.concentrateStationCode);
|
||||
// }
|
||||
//
|
||||
// if (station.code == next.code) {
|
||||
// node.children.push({
|
||||
// code: elem.code,
|
||||
// label: elem.name,
|
||||
// handler: this.mapLocation,
|
||||
// });
|
||||
// }
|
||||
// }
|
||||
// })
|
||||
//
|
||||
// this.menuNormal.push(node);
|
||||
// }
|
||||
// });
|
||||
// this.stationList.forEach(station => {
|
||||
// if (station.code === station.concentrateStationCode) {
|
||||
// let node = {
|
||||
// label: station.name,
|
||||
// children: []
|
||||
// }
|
||||
//
|
||||
// this.stationList.forEach(elem => {
|
||||
// if (elem.visible) {
|
||||
// let next = elem;
|
||||
// while (next.code != next.concentrateStationCode || !next.concentrateStationCode) {
|
||||
// next = this.$store.getters['map/getDeviceByCode'](next.concentrateStationCode);
|
||||
// }
|
||||
//
|
||||
// if (station.code == next.code) {
|
||||
// node.children.push({
|
||||
// code: elem.code,
|
||||
// label: elem.name,
|
||||
// handler: this.mapLocation,
|
||||
// });
|
||||
// }
|
||||
// }
|
||||
// })
|
||||
//
|
||||
// this.menuNormal.push(node);
|
||||
// }
|
||||
// });
|
||||
if (this.isScreen) {
|
||||
this.menu = [...this.menuScreen];
|
||||
}
|
||||
|
@ -1,8 +1,8 @@
|
||||
<template>
|
||||
<div class="menus" :style="{width: width + 'px'}">
|
||||
<menu-cancel ref="menuCancel" />
|
||||
<template v-if="isShowAll">
|
||||
<template v-if="isShowBar">
|
||||
<template v-show="isShowAll">
|
||||
<template v-show="isShowBar">
|
||||
<menu-bar ref="menuBar" :selected="selected" />
|
||||
</template>
|
||||
<menu-station-control ref="menuStationControl" :selected="selected" />
|
||||
@ -67,7 +67,8 @@ export default {
|
||||
]),
|
||||
isShowAll() {
|
||||
return this.$route.params.mode !== 'dp' &&
|
||||
this.$route.params.mode !== 'plan';
|
||||
this.$route.params.mode !== 'plan' &&
|
||||
this.$store.state.training.roles != 'BigScreen';
|
||||
},
|
||||
isShowBar() {
|
||||
return this.$store.state.training.prdType != '';
|
||||
|
@ -103,7 +103,6 @@
|
||||
<script>
|
||||
import { mapGetters } from 'vuex';
|
||||
import { TrainingMode, OperationEvent } from '@/scripts/ConstDic';
|
||||
// import { OperateMode } from '@/scripts/ConstDic';
|
||||
import { menuBarConvert, SystemType } from './utils/menuItemStatus';
|
||||
import StationControlConvert from './menuDialog/stationControlConvert';
|
||||
import TrainAdd from './menuDialog/trainAdd';
|
||||
|
@ -6,12 +6,10 @@
|
||||
|
||||
<script>
|
||||
import PopMenu from '@/components/PopMenu';
|
||||
// import OperateHandler from '@/scripts/plugin/trainingOperateHandler';
|
||||
import { mapGetters } from 'vuex';
|
||||
import { DeviceMenu } from '@/scripts/ConstDic';
|
||||
import { exitFullscreen } from '@/utils/screen';
|
||||
import { runDiagramQuit } from '@/api/simulation';
|
||||
// import { screenTopic, clearSubscribe } from '@/utils/stomp';
|
||||
import { EventBus } from '@/scripts/event-bus';
|
||||
|
||||
export default {
|
||||
@ -47,7 +45,8 @@ export default {
|
||||
'stationList'
|
||||
]),
|
||||
isScreen() { // 大屏隐藏所有菜单
|
||||
return this.$route.params.mode === 'dp';
|
||||
return this.$route.params.mode === 'dp' ||
|
||||
this.$store.state.training.roles == 'BigScreen';
|
||||
},
|
||||
group() {
|
||||
return this.$route.query.group;
|
||||
@ -56,8 +55,8 @@ export default {
|
||||
watch: {
|
||||
'$store.state.menuOperation.buttonOperation': function (val, old) {
|
||||
if (!this.isScreen && this.menu && this.menu.length > 1) {
|
||||
this.menu[0].disabled = (this.menu[0] && val) ? true : true;
|
||||
this.menu[1].disabled = !((this.menu[1] && val));
|
||||
// this.menu[0].disabled = (this.menu[0] && val) ? true : true;
|
||||
// this.menu[1].disabled = !((this.menu[1] && val));
|
||||
}
|
||||
},
|
||||
'$store.state.menuOperation.menuCount': function (val) {
|
||||
@ -83,14 +82,14 @@ export default {
|
||||
// label: station.name,
|
||||
// children: []
|
||||
// }
|
||||
//
|
||||
//
|
||||
// this.stationList.forEach(elem => {
|
||||
// if (elem.visible) {
|
||||
// let next = elem;
|
||||
// while (next.code != next.concentrateStationCode || !next.concentrateStationCode) {
|
||||
// next = this.$store.getters['map/getDeviceByCode'](next.concentrateStationCode);
|
||||
// }
|
||||
//
|
||||
//
|
||||
// if (station.code == next.code) {
|
||||
// node.children.push({
|
||||
// code: elem.code,
|
||||
@ -100,7 +99,7 @@ export default {
|
||||
// }
|
||||
// }
|
||||
// })
|
||||
//
|
||||
//
|
||||
// this.menuNormal.push(node);
|
||||
// }
|
||||
// });
|
||||
|
@ -1,8 +1,8 @@
|
||||
<template>
|
||||
<div class="menus" :style="{width: width + 'px'}">
|
||||
<menu-cancel ref="menuCancel" />
|
||||
<template v-if="isShowAll">
|
||||
<template v-if="isShowBar">
|
||||
<template v-show="isShowAll">
|
||||
<template v-show="isShowBar">
|
||||
<menu-bar ref="menuBar" :selected="selected" />
|
||||
</template>
|
||||
<menu-station-control ref="menuStationControl" :selected="selected" />
|
||||
@ -67,7 +67,8 @@ export default {
|
||||
]),
|
||||
isShowAll() {
|
||||
return this.$route.params.mode !== 'dp' &&
|
||||
this.$route.params.mode !== 'plan';
|
||||
this.$route.params.mode !== 'plan' &&
|
||||
this.$store.state.training.roles != 'BigScreen';
|
||||
},
|
||||
isShowBar() {
|
||||
return this.$store.state.training.prdType != '';
|
||||
|
@ -6,12 +6,10 @@
|
||||
|
||||
<script>
|
||||
import PopMenu from '@/components/PopMenu';
|
||||
// import OperateHandler from '@/scripts/plugin/trainingOperateHandler';
|
||||
import { mapGetters } from 'vuex';
|
||||
import { DeviceMenu } from '@/scripts/ConstDic';
|
||||
import { exitFullscreen } from '@/utils/screen';
|
||||
import { runDiagramQuit } from '@/api/simulation';
|
||||
// import { screenTopic, clearSubscribe } from '@/utils/stomp';
|
||||
import { EventBus } from '@/scripts/event-bus';
|
||||
|
||||
export default {
|
||||
@ -47,7 +45,8 @@ export default {
|
||||
'stationList'
|
||||
]),
|
||||
isScreen() { // 大屏隐藏所有菜单
|
||||
return this.$route.params.mode === 'dp';
|
||||
return this.$route.params.mode === 'dp' ||
|
||||
this.$store.state.training.roles == 'BigScreen';
|
||||
},
|
||||
group() {
|
||||
return this.$route.query.group;
|
||||
@ -56,8 +55,8 @@ export default {
|
||||
watch: {
|
||||
'$store.state.menuOperation.buttonOperation': function (val, old) {
|
||||
if (!this.isScreen && this.menu && this.menu.length > 1) {
|
||||
this.menu[0].disabled = (this.menu[0] && val) ? true : true;
|
||||
this.menu[1].disabled = !((this.menu[1] && val));
|
||||
// this.menu[0].disabled = (this.menu[0] && val) ? true : true;
|
||||
// this.menu[1].disabled = !((this.menu[1] && val));
|
||||
}
|
||||
},
|
||||
'$store.state.menuOperation.menuCount': function (val) {
|
||||
|
@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<div class="menus" :style="{width: width + 'px'}">
|
||||
<menu-cancel ref="menuCancel" />
|
||||
<template v-if="isShowAll">
|
||||
<template v-show="isShowAll">
|
||||
<menu-bar v-show="isShowBar" ref="menuBar" :selected="selected" />
|
||||
<menu-station-control ref="menuStationControl" :selected="selected" />
|
||||
<menu-station-stand ref="menuStationStand" :selected="selected" />
|
||||
@ -61,8 +61,9 @@ export default {
|
||||
'width'
|
||||
]),
|
||||
isShowAll() {
|
||||
return this.$route.params.mode !== 'dp' &&
|
||||
this.$route.params.mode !== 'plan';
|
||||
return this.$route.params.mode != 'dp' &&
|
||||
this.$route.params.mode != 'plan' &&
|
||||
this.$store.state.training.roles != 'BigScreen';
|
||||
},
|
||||
isShowBar() {
|
||||
return this.$store.state.training.prdType != '';
|
||||
|
@ -1,145 +1,144 @@
|
||||
<template>
|
||||
<div>
|
||||
<pop-menu ref="popMenu" :menu="menu"></pop-menu>
|
||||
</div>
|
||||
<div>
|
||||
<pop-menu ref="popMenu" :menu="menu" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import PopMenu from '@/components/PopMenu';
|
||||
import OperateHandler from '@/scripts/plugin/trainingOperateHandler';
|
||||
import { Notification } from 'element-ui';
|
||||
import { mapGetters } from 'vuex';
|
||||
import { MapDeviceType, OperationEvent, DeviceMenu } from '@/scripts/ConstDic';
|
||||
import { exitFullscreen } from '@/utils/screen';
|
||||
import { screenTopic, clearSubscribe } from '@/utils/stomp';
|
||||
import PopMenu from '@/components/PopMenu';
|
||||
import { Notification } from 'element-ui';
|
||||
import { mapGetters } from 'vuex';
|
||||
import { DeviceMenu } from '@/scripts/ConstDic';
|
||||
import { exitFullscreen } from '@/utils/screen';
|
||||
|
||||
export default {
|
||||
name: 'CancelMenu',
|
||||
components: {
|
||||
PopMenu
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
menu: [],
|
||||
menuNormal: [],
|
||||
menuScreen: [
|
||||
{
|
||||
label: '放大地图',
|
||||
handler: this.magnifyMap,
|
||||
disabled: false
|
||||
},
|
||||
{
|
||||
label: '缩小地图',
|
||||
handler: this.shrinkMap,
|
||||
disabled: false
|
||||
},
|
||||
{
|
||||
label: '返回',
|
||||
handler: this.back,
|
||||
disabled: false
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
...mapGetters('map', [
|
||||
'stationList',
|
||||
]),
|
||||
isScreen() { // 大屏隐藏所有菜单
|
||||
return this.$route.params.mode === 'dp'
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
'$store.state.menuOperation.buttonOperation': function (val, old) {
|
||||
if (!this.isScreen && this.menu && this.menu.length > 1) {
|
||||
this.menu[0].disabled = (this.menu[0] && val) ? true : true;
|
||||
this.menu[1].disabled = (this.menu[1] && val) ? false : true;
|
||||
}
|
||||
},
|
||||
'$store.state.menuOperation.menuCount': function (val) {
|
||||
if (this.$store.getters['menuOperation/checkDialogIsOpen'](DeviceMenu.Cancel)) {
|
||||
this.doShow(this.$store.state.menuOperation.menuPosition);
|
||||
} else {
|
||||
this.doClose();
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
clickEvent() {
|
||||
let self = this;
|
||||
window.onclick = function (e) {
|
||||
self.doClose();
|
||||
}
|
||||
},
|
||||
initMenu() {
|
||||
this.menuNormal = [];
|
||||
this.stationList.forEach(station => {
|
||||
if (station.code === station.concentrateStationCode) {
|
||||
let node = {
|
||||
label: station.name,
|
||||
children: []
|
||||
}
|
||||
export default {
|
||||
name: 'CancelMenu',
|
||||
components: {
|
||||
PopMenu
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
menu: [],
|
||||
menuNormal: [],
|
||||
menuScreen: [
|
||||
{
|
||||
label: '放大地图',
|
||||
handler: this.magnifyMap,
|
||||
disabled: false
|
||||
},
|
||||
{
|
||||
label: '缩小地图',
|
||||
handler: this.shrinkMap,
|
||||
disabled: false
|
||||
},
|
||||
{
|
||||
label: '返回',
|
||||
handler: this.back,
|
||||
disabled: false
|
||||
}
|
||||
]
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
...mapGetters('map', [
|
||||
'stationList'
|
||||
]),
|
||||
isScreen() { // 大屏隐藏所有菜单
|
||||
return this.$route.params.mode === 'dp' ||
|
||||
this.$store.state.training.roles == 'BigScreen';
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
'$store.state.menuOperation.buttonOperation': function (val, old) {
|
||||
if (!this.isScreen && this.menu && this.menu.length > 1) {
|
||||
// this.menu[0].disabled = (this.menu[0] && val) ? true : true;
|
||||
// this.menu[1].disabled = !((this.menu[1] && val));
|
||||
}
|
||||
},
|
||||
'$store.state.menuOperation.menuCount': function (val) {
|
||||
if (this.$store.getters['menuOperation/checkDialogIsOpen'](DeviceMenu.Cancel)) {
|
||||
this.doShow(this.$store.state.menuOperation.menuPosition);
|
||||
} else {
|
||||
this.doClose();
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
clickEvent() {
|
||||
const self = this;
|
||||
window.onclick = function (e) {
|
||||
self.doClose();
|
||||
};
|
||||
},
|
||||
initMenu() {
|
||||
this.menuNormal = [];
|
||||
this.stationList.forEach(station => {
|
||||
if (station.code === station.concentrateStationCode) {
|
||||
const node = {
|
||||
label: station.name,
|
||||
children: []
|
||||
};
|
||||
|
||||
this.stationList.forEach(elem => {
|
||||
if (elem.visible) {
|
||||
let next = elem;
|
||||
while (next.code != next.concentrateStationCode || !next.concentrateStationCode) {
|
||||
next = this.$store.getters['map/getDeviceByCode'](next.concentrateStationCode);
|
||||
}
|
||||
this.stationList.forEach(elem => {
|
||||
if (elem.visible) {
|
||||
let next = elem;
|
||||
while (next.code != next.concentrateStationCode || !next.concentrateStationCode) {
|
||||
next = this.$store.getters['map/getDeviceByCode'](next.concentrateStationCode);
|
||||
}
|
||||
|
||||
if (station.code == next.code) {
|
||||
node.children.push({
|
||||
code: elem.code,
|
||||
label: elem.name,
|
||||
handler: this.mapLocation,
|
||||
});
|
||||
}
|
||||
}
|
||||
})
|
||||
if (station.code == next.code) {
|
||||
node.children.push({
|
||||
code: elem.code,
|
||||
label: elem.name,
|
||||
handler: this.mapLocation
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
this.menuNormal.push(node);
|
||||
}
|
||||
});
|
||||
this.menuNormal.push(node);
|
||||
}
|
||||
});
|
||||
|
||||
if (this.isScreen) {
|
||||
this.menu = [...this.menuScreen];
|
||||
} else {
|
||||
this.menu = [...this.menuNormal];
|
||||
}
|
||||
},
|
||||
doShow(point) {
|
||||
this.clickEvent();
|
||||
this.initMenu();
|
||||
if (this.$refs && this.$refs.popMenu && this.menu && this.menu.length) {
|
||||
this.$refs.popMenu.resetShowPosition(point);
|
||||
}
|
||||
},
|
||||
doClose() {
|
||||
if (this.$refs && this.$refs.popMenu) {
|
||||
this.$refs.popMenu.close();
|
||||
}
|
||||
},
|
||||
// 设置地图定位
|
||||
mapLocation(item) {
|
||||
if (item) {
|
||||
this.$store.dispatch('training/updateOffsetStationCode', { offsetStationCode: item.code });
|
||||
this.doClose();
|
||||
}
|
||||
},
|
||||
// 放大地图
|
||||
magnifyMap() {
|
||||
this.$store.dispatch('menuOperation/handleMagnifyCount');
|
||||
},
|
||||
// 缩小地图
|
||||
shrinkMap() {
|
||||
this.$store.dispatch('menuOperation/handleShrinkCount');
|
||||
},
|
||||
// 返回
|
||||
async back() {
|
||||
history.go(-1);
|
||||
Notification.closeAll();
|
||||
exitFullscreen();
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.isScreen) {
|
||||
this.menu = [...this.menuScreen];
|
||||
} else {
|
||||
this.menu = [...this.menuNormal];
|
||||
}
|
||||
},
|
||||
doShow(point) {
|
||||
this.clickEvent();
|
||||
this.initMenu();
|
||||
if (this.$refs && this.$refs.popMenu && this.menu && this.menu.length) {
|
||||
this.$refs.popMenu.resetShowPosition(point);
|
||||
}
|
||||
},
|
||||
doClose() {
|
||||
if (this.$refs && this.$refs.popMenu) {
|
||||
this.$refs.popMenu.close();
|
||||
}
|
||||
},
|
||||
// 设置地图定位
|
||||
mapLocation(item) {
|
||||
if (item) {
|
||||
this.$store.dispatch('training/updateOffsetStationCode', { offsetStationCode: item.code });
|
||||
this.doClose();
|
||||
}
|
||||
},
|
||||
// 放大地图
|
||||
magnifyMap() {
|
||||
this.$store.dispatch('menuOperation/handleMagnifyCount');
|
||||
},
|
||||
// 缩小地图
|
||||
shrinkMap() {
|
||||
this.$store.dispatch('menuOperation/handleShrinkCount');
|
||||
},
|
||||
// 返回
|
||||
async back() {
|
||||
history.go(-1);
|
||||
Notification.closeAll();
|
||||
exitFullscreen();
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
@ -167,3 +167,51 @@ export function parser(data, skinCode) {
|
||||
|
||||
return mapDevice;
|
||||
}
|
||||
|
||||
// 同步绘制数据到原始数据
|
||||
export function updateForList(model, map, liststr) {
|
||||
const list = map[liststr];
|
||||
if (list && list instanceof Array) {
|
||||
const i = list.findIndex(elem => { return elem.code == model.code; });
|
||||
if (model._dispose) {
|
||||
i >= 0 && list.splice(i, 1);
|
||||
} else if (!list[i]) {
|
||||
list.push(Object.assign({}, model));
|
||||
} else if (i >= 0) {
|
||||
const item = list[i];
|
||||
Object.keys(model).forEach(key => {
|
||||
if (key != 'instance') {
|
||||
item[key] = model[key];
|
||||
}
|
||||
});
|
||||
}
|
||||
} else {
|
||||
map[liststr] = [model];
|
||||
}
|
||||
}
|
||||
|
||||
export function updateMapData(state, model) {
|
||||
const map = state.map;
|
||||
if (map && model) {
|
||||
switch (model._type) {
|
||||
case deviceType.Link: updateForList(model, map, 'linkList'); break;
|
||||
case deviceType.Section: updateForList(model, map, 'sectionList'); break;
|
||||
case deviceType.Switch: updateForList(model, map, 'switchList'); break;
|
||||
case deviceType.Signal: updateForList(model, map, 'signalList'); break;
|
||||
case deviceType.Station: updateForList(model, map, 'stationList'); break;
|
||||
case deviceType.StationStand: updateForList(model, map, 'stationStandList'); break;
|
||||
case deviceType.StationControl: updateForList(model, map, 'stationControlList'); break;
|
||||
case deviceType.StationCounter: updateForList(model, map, 'stationCounterList'); break;
|
||||
case deviceType.ZcControl: updateForList(model, map, 'zcControlList'); break;
|
||||
case deviceType.StationDelayUnlock:updateForList(model, map, 'stationDelayUnlockList'); break;
|
||||
case deviceType.LcControl: updateForList(model, map, 'lcControlList'); break;
|
||||
case deviceType.ButtonControl: updateForList(model, map, 'buttonList'); break;
|
||||
case deviceType.LimitControl: updateForList(model, map, 'tempSpeedLimitList'); break;
|
||||
case deviceType.ImageControl: updateForList(model, map, 'imageControl'); break;
|
||||
case deviceType.Train: updateForList(model, map, 'trainList'); break;
|
||||
case deviceType.TrainWindow: updateForList(model, map, 'trainWindowList'); break;
|
||||
case deviceType.Line: updateForList(model, map, 'lineList'); break;
|
||||
case deviceType.Text: updateForList(model, map, 'textList'); break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -74,7 +74,7 @@ const ibp = {
|
||||
commit('setUpdateDeviceData', models);
|
||||
},
|
||||
deleteIbpDevices: ({ commit }, models ) => {
|
||||
models = Object.assign(models, {dispose: true});
|
||||
models = Object.assign(models, {_dispose: true});
|
||||
if (!(models instanceof Array)) {
|
||||
models = [models];
|
||||
}
|
||||
|
@ -1,5 +1,5 @@
|
||||
import deviceType from '@/jmap/constant/deviceType';
|
||||
import { parser } from '@/jmap/utils/parser';
|
||||
import { parser, updateMapData } from '@/jmap/utils/parser';
|
||||
import Vue from 'vue';
|
||||
/**
|
||||
* 查询向上受影响的Devices
|
||||
@ -191,53 +191,6 @@ function saveMapDeviceDefaultRelations(state) {
|
||||
}
|
||||
}
|
||||
|
||||
// 同步绘制数据到原始数据
|
||||
function dataSync(model, map) {
|
||||
var prop = null;
|
||||
var type = model._type;
|
||||
var code = model.code;
|
||||
|
||||
switch (type) {
|
||||
case deviceType.Link: prop = 'linkList'; break;
|
||||
case deviceType.Section: prop = 'sectionList'; break;
|
||||
case deviceType.Switch: prop = 'switchList'; break;
|
||||
case deviceType.Signal: prop = 'signalList'; break;
|
||||
case deviceType.Station: prop = 'stationList'; break;
|
||||
case deviceType.StationStand: prop = 'stationStandList'; break;
|
||||
case deviceType.StationControl: prop = 'stationControlList'; break;
|
||||
case deviceType.StationCounter: prop = 'stationCounterList'; break;
|
||||
case deviceType.ZcControl: prop = 'zcControlList'; break;
|
||||
case deviceType.StationDelayUnlock: prop = 'stationDelayUnlockList'; break;
|
||||
case deviceType.LcControl: prop = 'lcControlList'; break;
|
||||
case deviceType.ButtonControl: prop = 'buttonList'; break;
|
||||
case deviceType.LimitControl: prop = 'tempSpeedLimitList'; break;
|
||||
case deviceType.ImageControl: prop = 'imageControl'; break;
|
||||
case deviceType.Train: prop = 'trainList'; break;
|
||||
case deviceType.TrainWindow: prop = 'trainWindowList'; break;
|
||||
case deviceType.Line: prop = 'lineList'; break;
|
||||
case deviceType.Text: prop = 'textList'; break;
|
||||
}
|
||||
|
||||
const list = map[prop] || [];
|
||||
const idex = list.findIndex(elem => { return elem.code == code; });
|
||||
if (list) {
|
||||
if (model._dispose) {
|
||||
idex >= 0 && list.splice(idex, 1);
|
||||
} else {
|
||||
const elem = list[idex];
|
||||
if (elem) {
|
||||
Object.keys(model).forEach(key => {
|
||||
if (key != 'instance') {
|
||||
elem[key] = model[key];
|
||||
}
|
||||
});
|
||||
} else {
|
||||
list.push(Object.assign({}, model));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 实训状态数据
|
||||
*/
|
||||
@ -483,7 +436,7 @@ const map = {
|
||||
},
|
||||
mapRender: (state, devices) => {
|
||||
if (state.map) {
|
||||
devices.forEach(elem => { dataSync(elem, state.map); });
|
||||
devices.forEach(elem => { updateMapData(state, elem); });
|
||||
}
|
||||
|
||||
if (Vue.prototype.$jlmap) {
|
||||
|
@ -127,3 +127,19 @@ export function getCountTime(data) {
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
// 对象 深拷贝
|
||||
export function deepClone(item) {
|
||||
const target = item.constructor === Array ? [] : {}; // 判断复制的目标是数组还是对象
|
||||
for (const keys in item) {
|
||||
if (item.hasOwnProperty(keys) && keys != 'instance') { // instance 对面不拷贝
|
||||
if (item[keys] && typeof item[keys] === 'object') { // 如果值是对象,就递归一下
|
||||
target[keys] = item[keys].constructor === Array ? [] : {};
|
||||
target[keys] = deepClone(item[keys]);
|
||||
} else {
|
||||
target[keys] = item[keys];
|
||||
}
|
||||
}
|
||||
}
|
||||
return target;
|
||||
}
|
||||
|
@ -18,7 +18,8 @@
|
||||
style="padding: 5px"
|
||||
:style="{ height: height-160 +'px' }"
|
||||
>
|
||||
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: height-170 +'px' }">
|
||||
<div>
|
||||
<!-- <el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: height-170 +'px' }"> -->
|
||||
<p class="list-item">
|
||||
<span class="list-label">{{ $t('demonstration.productDescription') }}</span>
|
||||
<span class="list-elem">{{ courseModel.remarks }}</span>
|
||||
@ -27,7 +28,8 @@
|
||||
<span class="list-label">{{ $t('global.permissionList') }}</span>
|
||||
</p>
|
||||
<limit-list :ref="`limit_${item.code}`" :course-model="courseModel" @initLoadPage="initLoadPage" />
|
||||
</el-scrollbar>
|
||||
<!-- </el-scrollbar> -->
|
||||
</div>
|
||||
</el-tab-pane>
|
||||
<div v-if="hasProduct" class="btn-buy">
|
||||
<el-button type="success" @click="buy">{{ $t('global.buy') }}</el-button>
|
||||
|
@ -50,8 +50,6 @@
|
||||
|
||||
<script>
|
||||
import { getScriptPageListOnline, getScriptById } from '@/api/script';
|
||||
import { listPublishMap } from '@/api/jmap/map';
|
||||
// import { roleType } from '@/scripts/ConstConfig';
|
||||
|
||||
export default {
|
||||
name: 'AddQuest',
|
||||
@ -73,7 +71,6 @@ export default {
|
||||
return {
|
||||
show: false,
|
||||
roleShow: false,
|
||||
mapList: [],
|
||||
pagerConfig: {
|
||||
pageSize: 'pageSize',
|
||||
pageIndex: 'pageNum'
|
||||
@ -100,13 +97,6 @@ export default {
|
||||
title: '任务名称',
|
||||
prop: 'name'
|
||||
},
|
||||
{
|
||||
title: '地图',
|
||||
prop: 'mapId',
|
||||
type: 'tag',
|
||||
columnValue: (row) => { return this.$convertField(row.mapId, this.mapList, ['id', 'name']); },
|
||||
tagType: (row) => { return 'success'; }
|
||||
},
|
||||
{
|
||||
title: '创建时间',
|
||||
prop: 'createTime'
|
||||
@ -152,15 +142,11 @@ export default {
|
||||
this.show = false;
|
||||
},
|
||||
listQuest(params) {
|
||||
params['skinCode'] = this.$route.query.skinCode;
|
||||
params['mapId'] = this.$route.query.mapId;
|
||||
return getScriptPageListOnline(params);
|
||||
},
|
||||
async loadInitData() {
|
||||
// 皮肤类型
|
||||
this.mapList = [];
|
||||
listPublishMap().then(response => {
|
||||
this.mapList = response.data;
|
||||
});
|
||||
|
||||
},
|
||||
async handleLoad(index, row) {
|
||||
this.row = row;
|
||||
|
@ -146,9 +146,7 @@ export default {
|
||||
}
|
||||
});
|
||||
});
|
||||
const resp = await generateExamList(this.examDetails.id);
|
||||
this.examList = resp.data.userExamQuestionsVOs;
|
||||
this.userExam = resp.data;
|
||||
|
||||
}
|
||||
},
|
||||
buy() {
|
||||
@ -168,6 +166,7 @@ export default {
|
||||
const data = this.examDetails;
|
||||
try {
|
||||
const response = await generateExamList(data.id);
|
||||
this.examList = response.data.userExamQuestionsVOs;
|
||||
this.userExam = response.data;
|
||||
const list = response.data.userExamQuestionsVOs;
|
||||
await this.$store.dispatch('exam/setUsedTime', this.userExam.usedTime);
|
||||
@ -191,9 +190,9 @@ export default {
|
||||
}
|
||||
}
|
||||
},
|
||||
exmaStart() {
|
||||
async exmaStart() {
|
||||
this.loading = true;
|
||||
this.examDetail();
|
||||
await this.examDetail();
|
||||
if (this.examList.length) {
|
||||
examNotify({ examId: this.$route.params.examId }).then(resp => {
|
||||
const query = {
|
||||
|
@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<div>
|
||||
<el-form ref="form" :rules="rules" :model="form" label-width="80px">
|
||||
<el-form ref="form" :rules="rules" :model="form" label-width="100px">
|
||||
<el-form-item label="箭头编号" prop="code">
|
||||
<el-input :disabled="true" v-model="form.code" >
|
||||
<el-button slot="append" :disabled="isUpdate" type="primary" @click="generateCode">生成编号</el-button>
|
||||
@ -23,6 +23,12 @@
|
||||
<el-form-item label="箭头颜色" prop="fillColor">
|
||||
<el-input v-model="form.fillColor"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="顶点X轴坐标">
|
||||
<el-input-number v-model="form.x" controls-position="right" :min="1"></el-input-number>
|
||||
</el-form-item>
|
||||
<el-form-item label="顶点Y轴坐标">
|
||||
<el-input-number v-model="form.y" controls-position="right" :min="1"></el-input-number>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" @click="onSubmit('form')">{{ buttonText }}</el-button>
|
||||
<el-button v-show="showDeleteButton" @click="deleteDevice" type="danger">删除</el-button>
|
||||
@ -42,16 +48,14 @@
|
||||
isUpdate: false,
|
||||
buttonText: '立即创建',
|
||||
showDeleteButton: false,
|
||||
point: {
|
||||
x: 10,
|
||||
y: 10
|
||||
},
|
||||
form: {
|
||||
code: '',
|
||||
orientation: '',
|
||||
arrowWidth: '',
|
||||
arrowLength: '',
|
||||
fillColor: ''
|
||||
fillColor: '',
|
||||
x: 10,
|
||||
y: 10
|
||||
},
|
||||
rules: {
|
||||
code: [
|
||||
@ -87,7 +91,8 @@
|
||||
this.form.arrowLength = model.length;
|
||||
this.form.arrowWidth = model.width;
|
||||
this.form.fillColor = model.fill;
|
||||
this.point = model.point;
|
||||
this.form.x = model.point.x;
|
||||
this.form.y = model.point.y;
|
||||
}
|
||||
}
|
||||
},
|
||||
@ -98,7 +103,10 @@
|
||||
this.$refs[form].validate((valid) => {
|
||||
if (valid){
|
||||
const arrowModel = {
|
||||
point: this.point,
|
||||
point: {
|
||||
x: this.form.x,
|
||||
y: this.form.y
|
||||
},
|
||||
_type: 'Arrow',
|
||||
code: this.form.code,
|
||||
orientation: this.form.orientation,
|
||||
@ -116,7 +124,10 @@
|
||||
},
|
||||
deleteDevice() {
|
||||
const arrowModel = {
|
||||
point: this.point,
|
||||
point: {
|
||||
x: this.form.x,
|
||||
y: this.form.y
|
||||
},
|
||||
_type: 'Arrow',
|
||||
code: this.form.code,
|
||||
orientation: this.form.orientation,
|
||||
@ -136,9 +147,7 @@
|
||||
orientation: '',
|
||||
arrowWidth: '',
|
||||
arrowLength: '',
|
||||
fillColor: ''
|
||||
};
|
||||
this.point = {
|
||||
fillColor: '',
|
||||
x: 10,
|
||||
y: 10
|
||||
};
|
||||
|
@ -41,7 +41,13 @@
|
||||
|
||||
},
|
||||
watch: {
|
||||
|
||||
'$store.state.ibp.rightClickCount': function (val) {
|
||||
const model = this.$store.getters['ibp/updateDeviceData'];
|
||||
if (model._type === 'Background' ){
|
||||
this.form.bgWidth = model.width;
|
||||
this.form.bgHeight = model.height;
|
||||
}
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
},
|
||||
|
@ -15,6 +15,12 @@
|
||||
<el-form-item label="Y轴坐标">
|
||||
<el-input-number v-model="form.y" controls-position="right" :min="1"></el-input-number>
|
||||
</el-form-item>
|
||||
<el-form-item label="提示颜色" prop="rotateTipColor">
|
||||
<el-select v-model="form.rotateTipColor" placeholder="请选择按钮颜色">
|
||||
<el-option label="红色" value="red"></el-option>
|
||||
<el-option label="黑色" value="black"></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" @click="onSubmit('form')">{{ buttonText }}</el-button>
|
||||
<el-button v-show="showDeleteButton" @click="deleteDevice" type="danger">删除</el-button>
|
||||
@ -37,6 +43,7 @@
|
||||
form: {
|
||||
code: '',
|
||||
rotateTipWidth: '',
|
||||
rotateTipColor: 'black',
|
||||
x: 10,
|
||||
y: 10
|
||||
},
|
||||
@ -46,6 +53,9 @@
|
||||
],
|
||||
rotateTipWidth: [
|
||||
{ required: true, message: '请输入旋转提示宽度', trigger: 'blur' },
|
||||
],
|
||||
rotateTipColor: [
|
||||
{ required: true, message: '请选择按钮颜色', trigger: 'change'}
|
||||
]
|
||||
}
|
||||
};
|
||||
@ -62,6 +72,7 @@
|
||||
this.isUpdate = true;
|
||||
this.form.code = model.code;
|
||||
this.form.rotateTipWidth = model.width;
|
||||
this.form.rotateTipColor = model.color?model.color:'black';
|
||||
this.form.x = model.point.x;
|
||||
this.form.y = model.point.y;
|
||||
}
|
||||
@ -82,6 +93,7 @@
|
||||
_type: 'RotateTip',
|
||||
code: this.form.code,
|
||||
width: this.form.rotateTipWidth,
|
||||
color: this.form.rotateTipColor
|
||||
};
|
||||
this.$emit('createRotateTip', rotateTipModel);
|
||||
this.initPage();
|
||||
@ -98,9 +110,10 @@
|
||||
y: this.form.y
|
||||
},
|
||||
draggable: true,
|
||||
_type: 'Key',
|
||||
_type: 'RotateTip',
|
||||
code: this.form.code,
|
||||
width: this.form .rotateTipWidth,
|
||||
color: this.form.rotateTipColor
|
||||
};
|
||||
this.$emit('deleteDataModel',rotateTipModel);
|
||||
this.initPage();
|
||||
@ -112,6 +125,7 @@
|
||||
this.form = {
|
||||
code: '',
|
||||
rotateTipWidth: '',
|
||||
rotateTipColor: 'black',
|
||||
x: 10,
|
||||
y: 10
|
||||
};
|
||||
|
@ -24,6 +24,24 @@
|
||||
<el-form-item label="Y轴坐标">
|
||||
<el-input-number v-model="form.y" controls-position="right" :min="1"></el-input-number>
|
||||
</el-form-item>
|
||||
<!--<el-form-item label="文字背景">-->
|
||||
<!--<el-switch v-model="form.hasRect" @change="handleChange"></el-switch>-->
|
||||
<!--</el-form-item>-->
|
||||
<!--<el-form-item v-show="form.hasRect" label="背景X轴坐标">-->
|
||||
<!--<el-input-number v-model="form.xBg" controls-position="right" :min="0"></el-input-number>-->
|
||||
<!--</el-form-item>-->
|
||||
<!--<el-form-item v-show="form.hasRect" label="背景Y轴坐标">-->
|
||||
<!--<el-input-number v-model="form.yBg" controls-position="right" :min="0"></el-input-number>-->
|
||||
<!--</el-form-item>-->
|
||||
<!--<el-form-item v-show="form.hasRect" label="背景宽度">-->
|
||||
<!--<el-input-number v-model="form.bgWidth" controls-position="right" :min="1"></el-input-number>-->
|
||||
<!--</el-form-item>-->
|
||||
<!--<el-form-item v-show="form.hasRect" label="背景高度">-->
|
||||
<!--<el-input-number v-model="form.bgHeight" controls-position="right" :min="1"></el-input-number>-->
|
||||
<!--</el-form-item>-->
|
||||
<!--<el-form-item v-show="form.hasRect" label="背景颜色" prop="elevatorColor">-->
|
||||
<!--<el-color-picker v-model="form.textBackgroundColor"></el-color-picker>-->
|
||||
<!--</el-form-item>-->
|
||||
<el-form-item>
|
||||
<el-button type="primary" @click="onSubmit('form')">{{ buttonText }}</el-button>
|
||||
<el-button v-show="showDeleteButton" @click="deleteDevice" type="danger">删除</el-button>
|
||||
@ -50,7 +68,13 @@
|
||||
fontSize: '',
|
||||
fontWeight: '',
|
||||
x: 10,
|
||||
y: 10
|
||||
y: 10,
|
||||
// hasRect: false,
|
||||
// xBg: 10,
|
||||
// yBg: 10,
|
||||
// bgWidth: 0,
|
||||
// bgHeight: 0,
|
||||
// textBackgroundColor: ''
|
||||
},
|
||||
rules: {
|
||||
code: [
|
||||
@ -88,6 +112,12 @@
|
||||
this.form.fontWeight = model.fontWeight;
|
||||
this.form.x = model.point.x;
|
||||
this.form.y = model.point.y;
|
||||
// this.form.hasRect = model.hasRect;
|
||||
// this.form.xBg = model.textRect ? model.textRect.x : 10;
|
||||
// this.form.yBg = model.textRect ? model.textRect.y : 10;
|
||||
// this.form.bgWidth = model.textRect ? model.textRect.width : 0;
|
||||
// this.form.bgHeight = model.textRect ? model.textRect.height : 0;
|
||||
// this.form.textBackgroundColor = model.textRect ? model.textRect.textBackgroundColor : '';
|
||||
}
|
||||
}
|
||||
},
|
||||
@ -108,7 +138,16 @@
|
||||
textFill: this.form.textFill,
|
||||
fontSize: this.form.fontSize ,
|
||||
fontWeight: this.form.fontWeight,
|
||||
fontFamily: 'consolas'
|
||||
fontFamily: 'consolas',
|
||||
// hasRect: this.form.hasRect,
|
||||
// textRect: this.form.hasRect ?
|
||||
// {
|
||||
// x: this.form.xBg,
|
||||
// y: this.form.yBg,
|
||||
// width: this.form.bgWidth,
|
||||
// height: this.form.bgHeight
|
||||
// }:'',
|
||||
// textBackgroundColor: this.form.hasRect?this.form.textBackgroundColor: ''
|
||||
};
|
||||
this.$emit('createText', textModel);
|
||||
this.initPage();
|
||||
@ -116,21 +155,6 @@
|
||||
return false;
|
||||
}
|
||||
});
|
||||
const textModel = {
|
||||
point: {
|
||||
x: this.form.x,
|
||||
y: this.form.y
|
||||
},
|
||||
code: this.form.code,
|
||||
_type: 'IbpText',
|
||||
context: this.form.context,
|
||||
textFill: this.form.textFill,
|
||||
fontSize: this.form.fontSize ,
|
||||
fontWeight: this.form.fontWeight,
|
||||
fontFamily: 'consolas'
|
||||
};
|
||||
this.$emit('createText', textModel);
|
||||
this.initPage();
|
||||
},
|
||||
deleteDevice() {
|
||||
const textModel = {
|
||||
@ -146,7 +170,16 @@
|
||||
textFill: this.form.textFill,
|
||||
fontSize: this.form.fontSize ,
|
||||
fontWeight: this.form.fontWeight,
|
||||
fontFamily: 'consolas'
|
||||
fontFamily: 'consolas',
|
||||
// hasRect: this.form.hasRect,
|
||||
// textRect: this.form.hasRect ?
|
||||
// {
|
||||
// x: this.form.xBg,
|
||||
// y: this.form.yBg,
|
||||
// width: this.form.bgWidth,
|
||||
// height: this.form.bgHeight
|
||||
// }:'',
|
||||
// textBackgroundColor: this.form.hasRect?this.form.textBackgroundColor: ''
|
||||
};
|
||||
this.$emit('deleteDataModel',textModel);
|
||||
this.initPage();
|
||||
@ -168,7 +201,12 @@
|
||||
generateCode() {
|
||||
const mydate = new Date();
|
||||
this.form.code = "text_"+mydate.getDay()+ mydate.getHours()+ mydate.getMinutes()+mydate.getSeconds()+mydate.getMilliseconds()+ Math.round(Math.random() * 10000);
|
||||
}
|
||||
},
|
||||
// handleChange(e) {
|
||||
// this.form.hasRect = e;
|
||||
// // this.form.hasRect = !this.form.hasRect;
|
||||
// console.log('-------',e,this.form.hasRect);
|
||||
// }
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
@ -3,10 +3,15 @@
|
||||
<div class="map-control">
|
||||
<el-card type="border-card">
|
||||
<div slot="header" class="clearfix">
|
||||
<span>
|
||||
车站名称
|
||||
<b>请选择车站</b>
|
||||
</span>
|
||||
<span>车站名称</span>
|
||||
<el-select v-model="stationCode" @change="changeStationCode" placeholder="请选择车站">
|
||||
<el-option
|
||||
v-for="item in stationOptions"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value">
|
||||
</el-option>
|
||||
</el-select>
|
||||
<el-button
|
||||
type="text"
|
||||
style="float: right; padding: 3px 0; margin-right: 5px;"
|
||||
@ -153,7 +158,22 @@
|
||||
data() {
|
||||
return {
|
||||
enabledTab: 'BgImage',
|
||||
data: ''
|
||||
data: '',
|
||||
stationOptions:[
|
||||
{
|
||||
value: 'Station_203_0.07533',
|
||||
label: '通化门站'
|
||||
},
|
||||
{
|
||||
value: 'Station_209_0.95175',
|
||||
label: '后卫寨站'
|
||||
},
|
||||
{
|
||||
value: 'Station_207_0.62282',
|
||||
label: '枣园站'
|
||||
}
|
||||
],
|
||||
stationCode: ''
|
||||
};
|
||||
},
|
||||
watch: {
|
||||
@ -182,9 +202,12 @@
|
||||
this.$store.dispatch('ibp/deleteIbpDevices', model);
|
||||
},
|
||||
handleSave() {
|
||||
const data = JSON.stringify(this.$store.state.ibp.ibp)
|
||||
const data = JSON.stringify(this.$store.state.ibp.ibp);
|
||||
console.log(data);
|
||||
},
|
||||
changeStationCode(e) {
|
||||
this.$emit('ibpChange',e);
|
||||
},
|
||||
handleTabClick() {
|
||||
this.$refs.ibpline.initPage();
|
||||
this.$refs.ibptext.initPage();
|
||||
|
@ -5,7 +5,7 @@
|
||||
<ibp-plate ref="ibpPlate" :size="size"/>
|
||||
</div>
|
||||
<div class="map-draft">
|
||||
<ibp-operate ref="ibpOperate" />
|
||||
<ibp-operate ref="ibpOperate" @ibpChange="ibpChange" />
|
||||
</div>
|
||||
</div>
|
||||
</transition>
|
||||
@ -52,7 +52,11 @@ export default {
|
||||
},
|
||||
selectViewDraft(data) {
|
||||
this.viewDraft = data;
|
||||
}
|
||||
},
|
||||
ibpChange(stationCode) {
|
||||
this.$refs.ibpPlate.show(stationCode);
|
||||
this.$refs.ibpPlate.drawIbpInit();
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<div>
|
||||
<div :id="ibpId" :style="{ width: '100%', height: '100%' }" class="ibp-canvas" />
|
||||
<div :id="ibpId" :style="{ width: '100%', height: '100%',background:'#000' }" class="ibp-canvas" />
|
||||
<el-button v-if="showBackButton" class="ibp-button" type="primary" @click="back">返回</el-button>
|
||||
</div>
|
||||
</template>
|
||||
@ -76,16 +76,18 @@ export default {
|
||||
this.setWindowSize();
|
||||
},
|
||||
beforeDestroy() {
|
||||
if (this.$ibp) {
|
||||
this.$ibp.dispose();
|
||||
}
|
||||
this.ibpDestroy();
|
||||
},
|
||||
methods: {
|
||||
show () {
|
||||
show (deviceCode) {
|
||||
if (!deviceCode) {
|
||||
return;
|
||||
}
|
||||
document.getElementById(this.ibpId).oncontextmenu = function (e) {
|
||||
return false;
|
||||
};
|
||||
const data = parser(ibpData, {width: this.canvasWidth, height: this.canvasHeight});
|
||||
this.ibpDestroy();
|
||||
const data = parser(ibpData[deviceCode], {width: this.canvasWidth, height: this.canvasHeight});
|
||||
this.$ibp = new IbpPan({
|
||||
dom: document.getElementById(this.ibpId),
|
||||
config: {
|
||||
@ -105,27 +107,27 @@ export default {
|
||||
}
|
||||
});
|
||||
Vue.prototype.$ibp = this.$ibp;
|
||||
this.setMap(data);
|
||||
this.$store.dispatch('ibp/setIbpData', ibpData);
|
||||
this.$ibp.on('contextmenu', this.onContextMenu, this);
|
||||
this.setMap(data,ibpData[deviceCode]);
|
||||
this.$store.dispatch('ibp/setIbpData', ibpData[deviceCode]);
|
||||
this.initClockTime(this.initTime);
|
||||
window.document.oncontextmenu = function () {
|
||||
return false;
|
||||
};
|
||||
},
|
||||
setMap(data) {
|
||||
this.$ibp.setMap(ibpData, data);
|
||||
setMap(data,oldData) {
|
||||
this.$ibp.setMap(oldData, data);
|
||||
},
|
||||
// 点击选择事件
|
||||
onSelected(em) {
|
||||
this.$emit('onSelect', em);
|
||||
},
|
||||
// 右键点击事件
|
||||
onContextMenu(em) {
|
||||
this.$emit('onMenu', em);
|
||||
this.$store.dispatch('ibp/setUpdateDeviceData', em.eventTarget.model);
|
||||
},
|
||||
// 绘图时调用,元素可拖拽
|
||||
drawIbpInit() {
|
||||
this.$ibp.drawIbpInit();
|
||||
this.$ibp&&this.$ibp.drawIbpInit();
|
||||
this.showBackButton = false;
|
||||
},
|
||||
// 初始化电子表时间
|
||||
@ -140,7 +142,6 @@ export default {
|
||||
this.$nextTick(() => {
|
||||
this.width = this.$store.state.config.width;
|
||||
this.height = this.$store.state.config.height;
|
||||
|
||||
this.$ibp && this.$ibp.resize({ width: this.width, height: this.height });
|
||||
});
|
||||
},
|
||||
@ -153,7 +154,14 @@ export default {
|
||||
},
|
||||
back() {
|
||||
this.$emit('hideIbp');
|
||||
}
|
||||
},
|
||||
ibpDestroy() {
|
||||
if (this.$ibp) {
|
||||
this.$ibp.dispose();
|
||||
this.$ibp = '';
|
||||
Vue.prototype.$ibp = '';
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
@ -70,7 +70,7 @@ export default {
|
||||
return false;
|
||||
},
|
||||
isScreen() {
|
||||
return this.$route.params.mode === 'dp';
|
||||
return this.$route.params.mode == 'dp' || this.$store.state.training.roles == 'BigScreen';
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
|
@ -1,12 +1,12 @@
|
||||
<template>
|
||||
<div class="main" :style="{width: canvasWidth+'px'}" @mousemove="mousemove">
|
||||
<Jl3d-Drive v-show="drivingShow" ref="Jl3dDrive" :panel-show="drivingShow" @showdriving="showdriving" />
|
||||
<ibp-plate v-show="ibpShow" ref="ibpPlate" @hideIbp="hideIbp" />
|
||||
<ibp-plate v-show="ibpShow" ref="ibpPlate" @hideIbp="hideIbp"/>
|
||||
<div v-show="panelShow" :panelShow="panelShow">
|
||||
<transition name="el-zoom-in-bottom">
|
||||
<map-system-draft ref="mapCanvas" @back="back" />
|
||||
</transition>
|
||||
<menu-demon-joint ref="demonMenu" :group="group" :user-role="userRole" @getUserRole="getUserRole" @hidepanel="hidepanel" @showIbp="showIbp" />
|
||||
<menu-demon-joint ref="demonMenu" :group="group" :user-role="userRole" :deviceCode="deviceCode" @getUserRole="getUserRole" @hidepanel="hidepanel" @showIbp="showIbp" />
|
||||
<menu-demon-schema
|
||||
ref="menuSchema"
|
||||
:group="group"
|
||||
@ -16,7 +16,7 @@
|
||||
@runPlanViewShow="runPlanViewShow"
|
||||
@faultChooseShow="faultChooseShow"
|
||||
/>
|
||||
|
||||
IBP
|
||||
<join-fault-choose ref="faultChoose" :group="group" />
|
||||
<join-run-plan-Load ref="runPlanLoad" :group="group" />
|
||||
<join-run-plan-view ref="runPlanView" :group="group" />
|
||||
@ -43,6 +43,7 @@ import { getUserRoles, deljointTrainRoom } from '@/api/chat';
|
||||
import { runDiagramOver, getSimulationInfo } from '@/api/simulation';
|
||||
import Jl3dDrive from '@/views/jlmap3d/drive/jl3ddrive';
|
||||
import { EventBus } from '@/scripts/event-bus';
|
||||
import ibpData from '@/ibp/constant/ibpData';
|
||||
|
||||
export default {
|
||||
name: 'JointTrainingDraft',
|
||||
@ -69,6 +70,7 @@ export default {
|
||||
mapBox: null,
|
||||
mapBoxP: null,
|
||||
userRole: '',
|
||||
deviceCode: '',
|
||||
group: '',
|
||||
mapId: '',
|
||||
skinCode: '',
|
||||
@ -278,6 +280,7 @@ export default {
|
||||
async getUserRole() {
|
||||
const res = await getUserRoles(this.group);
|
||||
this.userRole = res.data.userRole;
|
||||
this.deviceCode = res.data.deviceCode;
|
||||
return res;
|
||||
},
|
||||
// 仿真系统
|
||||
@ -300,6 +303,7 @@ export default {
|
||||
case 'Driver': this.$store.dispatch('training/setPrdType', ''); this.$store.dispatch('training/setRoles', 'Driver'); break;
|
||||
case 'Repair': this.$store.dispatch('training/setPrdType', ''); this.$store.dispatch('training/setRoles', 'Repair'); break;
|
||||
case 'IBP': this.$store.dispatch('training/setPrdType', ''); this.$store.dispatch('training/setRoles', 'IBP'); break;
|
||||
case 'BigScreen': this.$store.dispatch('training/setPrdType', ''); this.$store.dispatch('training/setRoles', 'BigScreen'); break;
|
||||
}
|
||||
}
|
||||
await this.getTrainDetail(this.skinCode);
|
||||
@ -333,11 +337,15 @@ export default {
|
||||
this.drivingShow = false;
|
||||
this.ibpShow =false;
|
||||
},
|
||||
showIbp() {
|
||||
showIbp(deviceCode) {
|
||||
if (!deviceCode || !ibpData[deviceCode]){
|
||||
this.$messageBox(`未绑定车站或该车站IBP盘暂未绘制!`);
|
||||
return;
|
||||
}
|
||||
this.drivingShow = false;
|
||||
this.panelShow = false;
|
||||
this.ibpShow = true;
|
||||
this.$refs.ibpPlate.show();
|
||||
this.$refs.ibpPlate.show(deviceCode);
|
||||
},
|
||||
hidepanel() {
|
||||
this.panelShow = false;
|
||||
|
@ -8,7 +8,7 @@
|
||||
<el-button type="success" :disabled="isDisable" @click="selectBeginTime">按计划行车</el-button>
|
||||
<el-button type="danger" :disabled="!isDisable" @click="end">退出计划</el-button>
|
||||
</template>
|
||||
<el-button type="primary" @click="back">返回</el-button>
|
||||
<el-button v-if="!isBigScreen" type="primary" @click="back">返回</el-button>
|
||||
</el-button-group>
|
||||
</div>
|
||||
<qr-code ref="qrCode" />
|
||||
@ -39,7 +39,13 @@ export default {
|
||||
userRole: {
|
||||
type: String,
|
||||
required: true
|
||||
}
|
||||
},
|
||||
deviceCode: {
|
||||
type: String,
|
||||
default() {
|
||||
return '';
|
||||
}
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
@ -75,6 +81,9 @@ export default {
|
||||
},
|
||||
isIBP() {
|
||||
return this.userRole == 'IBP';
|
||||
},
|
||||
isBigScreen() {
|
||||
return this.userRole == 'BigScreen';
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
@ -242,6 +251,14 @@ export default {
|
||||
this.$store.dispatch('training/setPrdType', ''); this.$store.dispatch('training/setRoles', 'Repair');
|
||||
this.$emit('getUserRole');
|
||||
break;
|
||||
case 'IBP':
|
||||
this.$store.dispatch('training/setPrdType', ''); this.$store.dispatch('training/setRoles', 'IBP');
|
||||
this.$emit('getUserRole');
|
||||
break;
|
||||
case 'BigScreen':
|
||||
this.$store.dispatch('training/setPrdType', ''); this.$store.dispatch('training/setRoles', 'BigScreen');
|
||||
this.$emit('getUserRole');
|
||||
break;
|
||||
default:
|
||||
this.$store.dispatch('training/setPrdType', ''); this.$store.dispatch('training/setRoles', 'Audience');
|
||||
this.$emit('getUserRole');
|
||||
@ -294,7 +311,7 @@ export default {
|
||||
this.$emit('hidepanel');
|
||||
},
|
||||
jumpIbp() {
|
||||
this.$emit('showIbp');
|
||||
this.$emit('showIbp',this.deviceCode);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
@ -226,6 +226,7 @@ export default {
|
||||
|
||||
this.mapSaveing = true;
|
||||
this.$store.dispatch('map/saveMapDeviceDefaultRelations').then(() => {
|
||||
// map.sectionList = [];
|
||||
saveMap(Object.assign(map, { mapId: this.$route.params.mapId })).then(response => {
|
||||
this.$message.success(this.$t('tip.saveSuccessfully'));
|
||||
this.mapSaveing = false;
|
||||
|
@ -290,7 +290,24 @@ export default {
|
||||
this.$refs.make.resetFields();
|
||||
this.activeName = 'first';
|
||||
if (selected && selected._type.toUpperCase() === 'Link'.toUpperCase()) {
|
||||
Object.assign(this.editModel, selected);
|
||||
this.editModel.name = selected.name;
|
||||
this.editModel.code = this.addModel.code = selected.code;
|
||||
this.editModel.type = selected.type;
|
||||
this.editModel.lengthShow = Math.sqrt(Math.pow(selected.rp.x - selected.lp.x, 2) + Math.pow(selected.rp.y - selected.lp.y, 2));
|
||||
this.editModel.lengthFact = selected.lengthFact;
|
||||
this.editModel.color = selected.color;
|
||||
this.editModel.leftFdCode = selected.leftFdCode;
|
||||
this.editModel.leftSdCode = selected.leftSdCode;
|
||||
this.editModel.rightFdCode = selected.rightFdCode;
|
||||
this.editModel.rightSdCode = selected.rightSdCode;
|
||||
this.editModel.lp = {
|
||||
x: selected.lp.x,
|
||||
y: selected.lp.y
|
||||
};
|
||||
this.editModel.rp = {
|
||||
x: selected.rp.x,
|
||||
y: selected.rp.y
|
||||
};
|
||||
}
|
||||
});
|
||||
},
|
||||
@ -439,58 +456,49 @@ export default {
|
||||
edit() {
|
||||
this.$refs['dataform'].validate((valid) => {
|
||||
if (valid) {
|
||||
const model = Object.assign({_type: 'Link'}, this.editModel);
|
||||
this.$emit('addOrUpdateMapModel', model);
|
||||
const data = Object.assign({_type: 'Link'}, this.editModel);
|
||||
this.$emit('addOrUpdateMapModel', data);
|
||||
}
|
||||
});
|
||||
},
|
||||
// 删除对象
|
||||
updateRelatedModel(node, code) {
|
||||
if (node.leftFdCode == code) {
|
||||
return { _type: 'Link', code: node.code, leftFdCode: '' };
|
||||
}
|
||||
|
||||
if (node.leftSdCode == code) {
|
||||
return { _type: 'Link', code: node.code, leftSdCode: '' };
|
||||
}
|
||||
if (node.rightFdCode == code) {
|
||||
return { _type: 'Link', code: node.code, rightFdCode: '' };
|
||||
}
|
||||
|
||||
if (node.rightSdCode == code) {
|
||||
return { _type: 'Link', code: node.code, rightSdCode: '' };
|
||||
}
|
||||
return { _type: 'Link', code: node.code };
|
||||
},
|
||||
deleteObj() {
|
||||
const selected = this.$store.getters['map/getDeviceByCode'](this.editModel.code);
|
||||
if (selected && selected._type.toUpperCase() === 'Link'.toUpperCase()) {
|
||||
var node = null;
|
||||
var _that = this;
|
||||
var updates = [];
|
||||
|
||||
if (selected.leftFdCode) {
|
||||
node = this.findLinkData(selected.leftFdCode);
|
||||
if (node) {
|
||||
if (selected.lp.y === selected.rp.y) {
|
||||
updates.push({ _type: 'Link', code: node.code, rightFdCode: '' });
|
||||
} else {
|
||||
updates.push({ _type: 'Link', code: node.code, rightSdCode: '' });
|
||||
}
|
||||
}
|
||||
node && updates.push(this.updateRelatedModel(node, selected.code));
|
||||
}
|
||||
if (selected.leftSdCode) {
|
||||
node = this.findLinkData(selected.leftSdCode);
|
||||
if (node) {
|
||||
if (selected.lp.y === selected.rp.y) {
|
||||
updates.push({ _type: 'Link', code: node.code, rightFdCode: '' });
|
||||
} else {
|
||||
updates.push({ _type: 'Link', code: node.code, rightSdCode: '' });
|
||||
}
|
||||
}
|
||||
node && updates.push(this.updateRelatedModel(node, selected.code));
|
||||
}
|
||||
if (selected.rightFdCode) {
|
||||
node = this.findLinkData(selected.rightFdCode);
|
||||
if (node) {
|
||||
if (selected.lp.y === selected.rp.y) {
|
||||
updates.push({ _type: 'Link', code: node.code, leftFdCode: '' });
|
||||
} else {
|
||||
updates.push({ _type: 'Link', code: node.code, leftSdCode: '' });
|
||||
}
|
||||
}
|
||||
node && updates.push(this.updateRelatedModel(node, selected.code));
|
||||
}
|
||||
if (selected.rightSdCode) {
|
||||
node = this.findLinkData(selected.rightSdCode);
|
||||
if (node) {
|
||||
if (selected.lp.y === selected.rp.y) {
|
||||
updates.push({ _type: 'Link', code: node.code, leftFdCode: '' });
|
||||
} else {
|
||||
updates.push({ _type: 'Link', code: node.code, leftSdCode: '' });
|
||||
}
|
||||
}
|
||||
node && updates.push(this.updateRelatedModel(node, selected.code));
|
||||
}
|
||||
|
||||
this.$confirm(this.$t('tip.confirmDeletion'), this.$t('tip.hint'), {
|
||||
|
@ -13,25 +13,16 @@
|
||||
</div>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane class="view-control" :label="$t('map.bothCreate')" name="second">
|
||||
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
|
||||
<el-form ref="make">
|
||||
<el-form-item>
|
||||
<el-transfer
|
||||
v-model="linksCollection"
|
||||
filterable
|
||||
:filter-method="filterLinks"
|
||||
:filter-placeholder="$t('rules.linkSelectName')"
|
||||
:data="DatasCollection"
|
||||
:titles="[$t('map.linkSet'), $t('map.selectLink')]"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</el-scrollbar>
|
||||
<div class="button_box">
|
||||
<el-button-group class="map-draft-group">
|
||||
<el-button type="primary" size="small" @click="create">{{ $t('map.create') }}</el-button>
|
||||
</el-button-group>
|
||||
<div class="flex_box">
|
||||
<el-button type="primary" @click="create">一键生成区段</el-button>
|
||||
</div>
|
||||
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
|
||||
<el-card v-if="questionList.length" class="box-card">
|
||||
<div v-for="(item, index) in questionList" :key="index" class="text item">
|
||||
{{ item }}
|
||||
</div>
|
||||
</el-card>
|
||||
</el-scrollbar>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane class="view-control" :label="$t('map.splitMerge')" name="three">
|
||||
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight+60+'px' }">
|
||||
@ -51,8 +42,8 @@
|
||||
@click="hover('splitSection')"
|
||||
>{{ $t('map.activate') }}</el-button>
|
||||
</el-form-item>
|
||||
<el-form-item :label="$t('map.splitOffset')" prop="splitOffset">
|
||||
<el-input-number v-model="addModel.splitOffset" :min="20" :max="addModel.splitOffsetMax" />px
|
||||
<el-form-item label="拆分数量" prop="splitNumber">
|
||||
<el-input-number v-model="addModel.splitNumber" :min="1" :max="addModel.splitOffsetMax" />
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button-group>
|
||||
@ -100,7 +91,7 @@
|
||||
</el-scrollbar>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane class="view-control" :label="$t('map.logicBlock')" name="four">
|
||||
<el-scrollbar wrap-class="scrollbar-wrapper" :style="{ height: cardHeight +'px' }">
|
||||
<el-scrollbar :style="{ height: cardHeight +'px' }">
|
||||
<el-table :data="tableData" style="width: 80%; margin: 0 auto;">
|
||||
<el-table-column :label="$t('map.sectionPolyline')" width="150">
|
||||
<template slot-scope="scope">
|
||||
@ -165,6 +156,7 @@ export default {
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
questionList: [],
|
||||
linksCollection: [],
|
||||
activeName: 'first',
|
||||
SectionTypeList: [],
|
||||
@ -217,7 +209,7 @@ export default {
|
||||
tableData: [],
|
||||
addModel: {
|
||||
code: '',
|
||||
splitOffset: 0,
|
||||
splitNumber: 2,
|
||||
splitOffsetMax: 0
|
||||
},
|
||||
mergeModel: {
|
||||
@ -231,9 +223,9 @@ export default {
|
||||
code: [
|
||||
{ required: true, message: this.$t('rules.pleaseSelectSectionName'), trigger: 'change' }
|
||||
],
|
||||
splitOffset: [
|
||||
{ required: true, message: this.$t('rules.pleaseFillOffset'), trigger: 'blur' },
|
||||
{ type: 'number', message: this.$t('rules.pleaseFillValue'), min: '20' }
|
||||
splitNumber: [
|
||||
{ required: true, message: '请输入拆分数量', trigger: 'blur' },
|
||||
{ type: 'number', message: '请输入合理的拆分数量', min: '20' }
|
||||
]
|
||||
},
|
||||
mergeRules: {
|
||||
@ -312,8 +304,6 @@ export default {
|
||||
{ prop: 'destinationCodePoint.y', firstLevel: 'destinationCodePoint', secondLevel: 'y', label: 'y:', type: 'number', labelWidth: '20px'}
|
||||
] },
|
||||
{ prop: 'destinationCodeShow', label: this.$t('map.destinationCodeShow'), type: 'checkbox', isHidden: !this.isdestinationCode },
|
||||
{ prop: 'leftStopPointOffset', label: this.$t('map.leftStopPointOffset'), type: 'number', min: 0, isHidden: !this.isStopPointOffset },
|
||||
{ prop: 'rightStopPointOffset', label: this.$t('map.rightStopPointOffset'), type: 'number', min: 0, isHidden: !this.isStopPointOffset },
|
||||
|
||||
{ prop: 'isSwitchSection', label: this.$t('map.isSwitchSection'), type: 'checkbox', isHidden: !this.isSectionType },
|
||||
{ prop: 'relSwitchCode', label: this.$t('map.relSwitchCode'), type: 'select', optionLabel: 'code&&name', optionValue: 'code', options: this.switchList, change: true, deviceChange: this.deviceChange, isHidden: !this.isRelSwitchCode, disabled: true },
|
||||
@ -340,6 +330,8 @@ export default {
|
||||
{ prop: 'stationCode', label: this.$t('map.equipmentStation'), type: 'select', mode: true, optionLabel: 'name&&code', optionValue: 'code', disabled: this.isStationCodeDisabled, options: this.stationList },
|
||||
{ prop: 'offsetLeft', label: this.$t('map.sectionOffsetLeft'), type: 'number', min: 0, placeholder: '米', isHidden: !this.isSectionType },
|
||||
{ prop: 'offsetRight', label: this.$t('map.sectionOffsetRight'), type: 'number', min: 0, placeholder: '米', isHidden: !this.isSectionType },
|
||||
{ prop: 'leftStopPointOffset', label: this.$t('map.leftStopPointOffset'), type: 'number', min: 0, isHidden: !this.isStopPointOffset },
|
||||
{ prop: 'rightStopPointOffset', label: this.$t('map.rightStopPointOffset'), type: 'number', min: 0, isHidden: !this.isStopPointOffset },
|
||||
{ prop: 'region', label: this.$t('map.sectionColon'), type: 'select', optionLabel: 'label', optionValue: 'value', options: this.regionList, isHidden: !this.sectionColonShow },
|
||||
{ prop: 'kmRangeLeft', label: this.$t('map.leftKilometerMark'), type: 'number', min: 0 },
|
||||
{ prop: 'kmRangeRight', label: this.$t('map.rightKilometerMark'), type: 'number', min: 0 },
|
||||
@ -514,6 +506,7 @@ export default {
|
||||
this.regionList = this.$ConstSelect.RegionTypeList;
|
||||
},
|
||||
methods: {
|
||||
// 计算逻辑区段数量列表展示
|
||||
computedLogicSectionNumList(logicSectionNum) {
|
||||
this.tableData = [];
|
||||
this.logicSectionNums = [...logicSectionNum];
|
||||
@ -541,22 +534,89 @@ export default {
|
||||
if (!this.fieldS) { // 判断是否激活选择站台
|
||||
this.editModel.points = [];
|
||||
this.$refs.dataform.clearValidate();
|
||||
this.activeName = 'first';
|
||||
if (selected && selected._type.toUpperCase() === 'Section'.toUpperCase()) {
|
||||
Object.assign(this.editModel, selected);
|
||||
this.editModel.logicSectionNum = selected.type === '01' ? selected.logicSectionNum : [0];
|
||||
this.editModel.points = selected.points.slice();
|
||||
this.activeName = 'first';
|
||||
this.editModel.code = selected.code;
|
||||
this.editModel.name = selected.name;
|
||||
this.editModel.type = selected.type;
|
||||
this.editModel.namePosition = {
|
||||
x: selected.namePosition.x,
|
||||
y: selected.namePosition.y
|
||||
};
|
||||
this.editModel.nameShow = selected.nameShow;
|
||||
this.editModel.axleShow = selected.axleShow;
|
||||
this.editModel.relStandCode = selected.relStandCode;
|
||||
this.editModel.leftStopPointOffset = selected.leftStopPointOffset;
|
||||
this.editModel.rightStopPointOffset = selected.rightStopPointOffset;
|
||||
this.editModel.destinationCode = selected.destinationCode;
|
||||
if (selected.destinationCodePoint) {
|
||||
this.editModel.destinationCodePoint = {
|
||||
x: selected.destinationCodePoint.x,
|
||||
y: selected.destinationCodePoint.y
|
||||
};
|
||||
}
|
||||
this.editModel.kmRangeRight = selected.kmRangeRight;
|
||||
this.editModel.kmRangeLeft = selected.kmRangeLeft;
|
||||
this.editModel.region = selected.region;
|
||||
|
||||
this.editModel.destinationCodeShow = selected.destinationCodeShow;
|
||||
|
||||
this.editModel.logicSectionNum = selected.type === '01' ? selected.logicSectionNum : [0];
|
||||
this.editModel.logicSectionShow = selected.logicSectionShow;
|
||||
this.editModel.logicSectionNameShow = selected.logicSectionNameShow;
|
||||
this.editModel.isStandTrack = selected.isStandTrack;
|
||||
this.editModel.standTrackName = selected.standTrackName;
|
||||
this.editModel.standTrackNamePosition = {
|
||||
x: selected.standTrackNamePosition.x,
|
||||
y: selected.standTrackNamePosition.y
|
||||
};
|
||||
this.editModel.isReentryTrack = selected.isReentryTrack;
|
||||
this.editModel.reentryTrackName = selected.reentryTrackName;
|
||||
this.editModel.reentryTrackNamePosition = {
|
||||
x: selected.reentryTrackNamePosition.x,
|
||||
y: selected.reentryTrackNamePosition.y
|
||||
};
|
||||
this.editModel.isTransferTrack = selected.isTransferTrack;
|
||||
this.editModel.transferTrackName = selected.transferTrackName;
|
||||
this.editModel.transferTrackNamePosition = {
|
||||
x: selected.transferTrackNamePosition.x,
|
||||
y: selected.transferTrackNamePosition.y
|
||||
};
|
||||
this.editModel.isSegmentation = selected.isSegmentation || false;
|
||||
if (selected.segmentationPosition) {
|
||||
this.editModel.segmentationPosition = {
|
||||
x: selected.segmentationPosition.x,
|
||||
y: selected.segmentationPosition.y
|
||||
};
|
||||
} else {
|
||||
this.editModel.segmentationPosition = { x: 0, y: 0 };
|
||||
}
|
||||
|
||||
this.editModel.logicSectionNameSort = selected.logicSectionNameSort;
|
||||
this.editModel.isSwitchSection = selected.isSwitchSection;
|
||||
this.editModel.relSwitchCode = selected.relSwitchCode;
|
||||
this.editModel.linkCode = selected.linkCode;
|
||||
this.editModel.sepTypeLeft = selected.sepTypeLeft;
|
||||
this.editModel.offsetLeft = selected.offsetLeft;
|
||||
this.editModel.sepTypeRight = selected.sepTypeRight;
|
||||
this.editModel.offsetRight = selected.offsetRight;
|
||||
this.editModel.stationCode = selected.stationCode;
|
||||
this.editModel.trainPosType = selected.trainPosType;
|
||||
this.editModel.parentCode = selected.parentCode;
|
||||
this.editModel.points = selected.points.slice();
|
||||
this.editModel.isCurve = selected.isCurve;
|
||||
this.addModel.splitOffsetMax = Math.sqrt(new JTriangle(selected.points[0], selected.points[selected.points.length - 1]).abspowz);
|
||||
this.addModel.splitOffset = this.addModel.splitOffsetMax / 2;
|
||||
this.computedLogicSectionNumList(this.editModel.logicSectionNum);
|
||||
|
||||
if (this.field.toUpperCase() === 'splitSection'.toUpperCase()) {
|
||||
this.addModel.code = selected.code;
|
||||
this.activeName = 'three';
|
||||
} else if (this.field.toUpperCase() === 'leftSection'.toUpperCase()) {
|
||||
this.mergeModel.lsectioncode = selected.code;
|
||||
this.activeName = 'three';
|
||||
} else if (this.field.toUpperCase() === 'rightSection'.toUpperCase()) {
|
||||
this.mergeModel.rsectioncode = selected.code;
|
||||
this.activeName = 'three';
|
||||
}
|
||||
} else {
|
||||
this.tableData = [];
|
||||
@ -684,94 +744,100 @@ export default {
|
||||
filterLinks(query, item) {
|
||||
return item.pinyin.indexOf(query) > -1;
|
||||
},
|
||||
// 一键生成区段
|
||||
create() {
|
||||
const models = [];
|
||||
const remove = [];
|
||||
this.linksCollection.forEach(elem => {
|
||||
this.linkList.forEach(link => {
|
||||
if (elem === link.code) {
|
||||
const uid = getUID('Section');
|
||||
const uname = 'Section_' + link.name.replace('Link_', '');
|
||||
const model = {
|
||||
_type: 'Section',
|
||||
code: uid,
|
||||
name: uname,
|
||||
type: '01',
|
||||
axleShow: false,
|
||||
isStandTrack: false,
|
||||
standTrackName: '',
|
||||
standTrackNamePosition: { x: 0, y: 0 },
|
||||
isReentryTrack: false,
|
||||
reentryTrackName: '',
|
||||
reentryTrackNamePosition: { x: 0, y: 0 },
|
||||
isTransferTrack: false,
|
||||
transferTrackName: '',
|
||||
transferTrackNamePosition: { x: 0, y: 0 },
|
||||
isSwitchSection: false,
|
||||
isSegmentation: false,
|
||||
segmentationPosition: { x: 0, y: 0 },
|
||||
relSwitchCode: '',
|
||||
kmRangeRight: '',
|
||||
kmRangeLeft: '',
|
||||
region: '',
|
||||
namePosition: { x: 0, y: 0 },
|
||||
logicSectionNum: [0],
|
||||
logicSectionShow: true,
|
||||
logicSectionNameSort: true,
|
||||
linkCode: link.code,
|
||||
sepTypeLeft: '01',
|
||||
offsetLeft: 0,
|
||||
sepTypeRight: '01',
|
||||
trainPosType: '01',
|
||||
offsetRight: link.lengthFact,
|
||||
parentCode: '',
|
||||
relStandCode: '',
|
||||
rightStopPointOffset: 0,
|
||||
leftStopPointOffset: 0,
|
||||
destinationCode: '',
|
||||
destinationCodePoint: { x: 0, y: 0 },
|
||||
destinationCodeShow: false,
|
||||
points: [
|
||||
{ x: link.lp.x, y: link.lp.y },
|
||||
{ x: link.rp.x, y: link.rp.y }
|
||||
],
|
||||
isCurve: false
|
||||
};
|
||||
// 判断左分隔符类型
|
||||
if (!link.leftFdCode && !link.leftSdcode) {
|
||||
model.sepTypeLeft = '03';
|
||||
} else if (link.leftFdCode && link.leftSdCode) {
|
||||
model.sepTypeLeft = '00';
|
||||
} else if (link.leftFdCode) {
|
||||
const node = this.findLinkData(link.leftFdCode);
|
||||
if (node && node.rightFdCode && node.rightSdCode) {
|
||||
model.sepTypeLeft = '00';
|
||||
}
|
||||
}
|
||||
// 判断右分隔符类型
|
||||
if (!link.rightFdCode && !link.rightSdCode) {
|
||||
model.sepTypeRight = '03';
|
||||
} else if (link.rightFdCode && link.rightSdCode) {
|
||||
model.sepTypeRight = '00';
|
||||
} else if (link.rightFdCode) {
|
||||
const node = this.findLinkData(link.rightFdCode);
|
||||
if (node && node.leftFdCode && node.leftSdCode) {
|
||||
model.sepTypeRight = '00';
|
||||
}
|
||||
}
|
||||
|
||||
models.push(model);
|
||||
const sectionList = this.findSectionListDataByLinkCode(link.code);
|
||||
if (sectionList) {
|
||||
sectionList.forEach(section => {
|
||||
remove.push({ _type: 'Section', code: section.code });
|
||||
if (section.type === '02' && section.parentCode === elem.code) {
|
||||
remove.push(section);
|
||||
}
|
||||
});
|
||||
}
|
||||
this.linkList.forEach(link => {
|
||||
let count = 0;
|
||||
this.sectionList.forEach(setction => {
|
||||
count++;
|
||||
if (setction.linkCode == link.code) {
|
||||
count = 0;
|
||||
}
|
||||
});
|
||||
if (count == this.sectionList.length) {
|
||||
const uid = getUID('Section');
|
||||
const uname = 'Section_' + link.name.replace('Link_', '');
|
||||
const model = {
|
||||
_type: 'Section',
|
||||
code: uid,
|
||||
name: uname,
|
||||
type: '01',
|
||||
axleShow: false,
|
||||
isStandTrack: false,
|
||||
standTrackName: '',
|
||||
standTrackNamePosition: { x: 0, y: 0 },
|
||||
isReentryTrack: false,
|
||||
reentryTrackName: '',
|
||||
reentryTrackNamePosition: { x: 0, y: 0 },
|
||||
isTransferTrack: false,
|
||||
transferTrackName: '',
|
||||
transferTrackNamePosition: { x: 0, y: 0 },
|
||||
isSwitchSection: false, // 是否道岔管理区段
|
||||
isSegmentation: false,
|
||||
segmentationPosition: { x: 0, y: 0 },
|
||||
relSwitchCode: '',
|
||||
kmRangeRight: '',
|
||||
kmRangeLeft: '',
|
||||
region: '',
|
||||
namePosition: { x: 0, y: 0 },
|
||||
logicSectionNum: [0],
|
||||
logicSectionShow: true,
|
||||
logicSectionNameSort: true,
|
||||
linkCode: link.code,
|
||||
sepTypeLeft: '01', // 分隔符类型
|
||||
offsetLeft: 0,
|
||||
sepTypeRight: '01',
|
||||
trainPosType: '01',
|
||||
offsetRight: link.lengthFact,
|
||||
parentCode: '',
|
||||
relStandCode: '',
|
||||
rightStopPointOffset: 0,
|
||||
leftStopPointOffset: 0,
|
||||
destinationCode: '',
|
||||
destinationCodePoint: { x: 0, y: 0 },
|
||||
destinationCodeShow: false,
|
||||
points: [
|
||||
{ x: link.lp.x, y: link.lp.y },
|
||||
{ x: link.rp.x, y: link.rp.y }
|
||||
],
|
||||
isCurve: false
|
||||
};
|
||||
// 判断左分隔符类型
|
||||
if (!link.leftFdCode && !link.leftSdcode) {
|
||||
model.sepTypeLeft = '03';
|
||||
} else if (link.leftFdCode && link.leftSdCode) {
|
||||
model.sepTypeLeft = '00';
|
||||
} else if (link.leftFdCode) {
|
||||
const node = this.findLinkData(link.leftFdCode);
|
||||
if (node && node.rightFdCode && node.rightSdCode) {
|
||||
model.sepTypeLeft = '00';
|
||||
}
|
||||
}
|
||||
// 判断右分隔符类型
|
||||
if (!link.rightFdCode && !link.rightSdCode) {
|
||||
model.sepTypeRight = '03';
|
||||
} else if (link.rightFdCode && link.rightSdCode) {
|
||||
model.sepTypeRight = '00';
|
||||
} else if (link.rightFdCode) {
|
||||
const node = this.findLinkData(link.rightFdCode);
|
||||
if (node && node.leftFdCode && node.leftSdCode) {
|
||||
model.sepTypeRight = '00';
|
||||
}
|
||||
}
|
||||
|
||||
models.push(model);
|
||||
const sectionList = this.findSectionListDataByLinkCode(link.code);
|
||||
if (sectionList) {
|
||||
sectionList.forEach(section => {
|
||||
remove.push({ _type: 'Section', code: section.code });
|
||||
if (section.type === '02' && section.parentCode) {
|
||||
remove.push(section);
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
const _that = this;
|
||||
@ -781,7 +847,11 @@ export default {
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
_that.$emit('delMapModel', remove);
|
||||
_that.$emit('addOrUpdateMapModel', models);
|
||||
if (models.length) {
|
||||
_that.$emit('addOrUpdateMapModel', models);
|
||||
} else {
|
||||
_that.$message.info('所有link都有相关区段,所以未生成任何区段');
|
||||
}
|
||||
}).catch(() => {
|
||||
this.$message({
|
||||
type: 'info',
|
||||
@ -789,78 +859,15 @@ export default {
|
||||
});
|
||||
});
|
||||
},
|
||||
buildEditModel() {
|
||||
const pointArr = JSON.stringify(this.editModel.points);
|
||||
const model = {
|
||||
_type: 'Section',
|
||||
code: this.editModel.code,
|
||||
name: this.editModel.name,
|
||||
type: this.editModel.type,
|
||||
relStandCode: this.editModel.relStandCode,
|
||||
leftStopPointOffset: Number(this.editModel.leftStopPointOffset),
|
||||
rightStopPointOffset: Number(this.editModel.rightStopPointOffset),
|
||||
axleShow: this.editModel.axleShow,
|
||||
namePosition: {
|
||||
x: this.editModel.namePosition.x,
|
||||
y: this.editModel.namePosition.y
|
||||
},
|
||||
kmRangeRight: this.editModel.kmRangeRight,
|
||||
kmRangeLeft: this.editModel.kmRangeLeft,
|
||||
region: this.editModel.region,
|
||||
isStandTrack: this.editModel.isStandTrack,
|
||||
standTrackName: this.editModel.standTrackName,
|
||||
standTrackNamePosition: {
|
||||
x: this.editModel.standTrackNamePosition.x,
|
||||
y: this.editModel.standTrackNamePosition.y
|
||||
},
|
||||
isReentryTrack: this.editModel.isReentryTrack,
|
||||
reentryTrackName: this.editModel.reentryTrackName,
|
||||
reentryTrackNamePosition: {
|
||||
x: this.editModel.reentryTrackNamePosition.x,
|
||||
y: this.editModel.reentryTrackNamePosition.y
|
||||
},
|
||||
isSegmentation: this.editModel.isSegmentation,
|
||||
segmentationPosition: {
|
||||
x: this.editModel.segmentationPosition.x,
|
||||
y: this.editModel.segmentationPosition.y
|
||||
},
|
||||
isTransferTrack: this.editModel.isTransferTrack,
|
||||
transferTrackName: this.editModel.transferTrackName,
|
||||
transferTrackNamePosition: {
|
||||
x: this.editModel.transferTrackNamePosition.x,
|
||||
y: this.editModel.transferTrackNamePosition.y
|
||||
},
|
||||
logicSectionNameSort: this.editModel.logicSectionNameSort,
|
||||
isSwitchSection: this.editModel.isSwitchSection,
|
||||
relSwitchCode: this.editModel.relSwitchCode,
|
||||
points: JSON.parse(pointArr),
|
||||
logicSectionNum: this.editModel.logicSectionNum,
|
||||
logicSectionShow: this.editModel.logicSectionShow,
|
||||
sepTypeLeft: this.editModel.sepTypeLeft,
|
||||
offsetLeft: this.editModel.offsetLeft,
|
||||
sepTypeRight: this.editModel.sepTypeRight,
|
||||
offsetRight: this.editModel.offsetRight,
|
||||
stationCode: this.editModel.stationCode,
|
||||
trainPosType: this.editModel.trainPosType,
|
||||
linkCode: this.editModel.linkCode,
|
||||
isCurve: this.editModel.isCurve,
|
||||
destinationCodeShow: false
|
||||
};
|
||||
if (model.isReentryTrack || this.editModel.isTransferTrack) {
|
||||
model.destinationCode = this.editModel.destinationCode;
|
||||
model.destinationCodePoint = {
|
||||
x: this.editModel.destinationCodePoint.x,
|
||||
y: this.editModel.destinationCodePoint.y
|
||||
};
|
||||
model.destinationCodeShow = this.editModel.destinationCodeShow;
|
||||
}
|
||||
return model;
|
||||
},
|
||||
// 修改区段属性
|
||||
edit() {
|
||||
this.$refs['dataform'].validate((valid) => {
|
||||
if (valid) {
|
||||
const edits = [];
|
||||
const model = this.buildEditModel();
|
||||
const model = Object.assign({_type: 'Section'}, this.editModel);
|
||||
// model.points = JSON.parse(JSON.stringify(model.points));
|
||||
model.leftStopPointOffset = Number(model.leftStopPointOffset);
|
||||
model.rightStopPointOffset = Number(model.rightStopPointOffset);
|
||||
this.sectionList.forEach(section => {
|
||||
if (section.parentCode == model.code) {
|
||||
section.logicSectionShow = model.logicSectionShow;
|
||||
@ -899,117 +906,72 @@ export default {
|
||||
});
|
||||
}
|
||||
},
|
||||
// 拆分
|
||||
// 拆分区段
|
||||
split() {
|
||||
this.$refs['oprt'].validate((valid) => {
|
||||
if (valid) {
|
||||
const selected = this.$store.getters['map/getDeviceByCode'](this.addModel.code);
|
||||
if (selected && selected._type === 'Section' && selected.type === '01') {
|
||||
const triangle = new JTriangle(selected.points[0], selected.points[selected.points.length - 1]);
|
||||
const remove = [];
|
||||
const models = [];
|
||||
const uidL = selected.name + '_l';
|
||||
const uidR = selected.name + '_r';
|
||||
const modelL = {
|
||||
_type: 'Section',
|
||||
code: getUID('Section'),
|
||||
name: uidL,
|
||||
type: '01',
|
||||
parentCode: '',
|
||||
axleShow: selected.axleShow,
|
||||
isStandTrack: false,
|
||||
kmRangeRight: '',
|
||||
kmRangeLeft: '',
|
||||
region: '',
|
||||
standTrackName: '',
|
||||
standTrackNamePosition: { x: 0, y: 0 },
|
||||
isReentryTrack: false,
|
||||
reentryTrackName: '',
|
||||
reentryTrackNamePosition: { x: 0, y: 0 },
|
||||
isTransferTrack: false,
|
||||
transferTrackName: '',
|
||||
transferTrackNamePosition: { x: 0, y: 0 },
|
||||
isSwitchSection: false,
|
||||
isSegmentation: false,
|
||||
segmentationPosition: { x: 0, y: 0 },
|
||||
relSwitchCode: '',
|
||||
logicSectionNameSort: selected.logicSectionNameSort,
|
||||
logicSectionNum: selected.logicSectionNum,
|
||||
logicSectionShow: selected.logicSectionShow,
|
||||
sepTypeLeft: selected.sepTypeLeft,
|
||||
offsetLeft: selected.offsetLeft,
|
||||
sepTypeRight: '01',
|
||||
offsetRight: selected.offsetRight,
|
||||
linkCode: selected.linkCode,
|
||||
trainPosType: selected.trainPosType,
|
||||
isCurve: selected.isCurve,
|
||||
points: [
|
||||
{
|
||||
x: selected.points[0].x,
|
||||
y: selected.points[0].y
|
||||
},
|
||||
{
|
||||
x: selected.points[0].x + triangle.getCos(this.addModel.splitOffset * 10000) / 10000,
|
||||
y: selected.points[0].y + triangle.getSin(this.addModel.splitOffset * 10000) / 10000
|
||||
}
|
||||
],
|
||||
namePosition: { x: 0, y: 0 }
|
||||
};
|
||||
const modelR = {
|
||||
_type: 'Section',
|
||||
code: getUID('Section'),
|
||||
name: uidR,
|
||||
type: '01',
|
||||
parentCode: '',
|
||||
axleShow: selected.axleShow,
|
||||
isStandTrack: false,
|
||||
kmRangeRight: '',
|
||||
kmRangeLeft: '',
|
||||
region: '',
|
||||
standTrackName: '',
|
||||
standTrackNamePosition: { x: 0, y: 0 },
|
||||
isReentryTrack: false,
|
||||
reentryTrackName: '',
|
||||
reentryTrackNamePosition: { x: 0, y: 0 },
|
||||
isTransferTrack: false,
|
||||
transferTrackName: '',
|
||||
transferTrackNamePosition: { x: 0, y: 0 },
|
||||
isSegmentation: false,
|
||||
segmentationPosition: { x: 0, y: 0 },
|
||||
isSwitchSection: false,
|
||||
relSwitchCode: '',
|
||||
logicSectionNameSort: selected.logicSectionNameSort,
|
||||
logicSectionNum: selected.logicSectionNum,
|
||||
logicSectionShow: selected.logicSectionShow,
|
||||
sepTypeLeft: '01',
|
||||
offsetLeft: selected.offsetLeft,
|
||||
sepTypeRight: selected.sepTypeRight,
|
||||
offsetRight: selected.offsetRight,
|
||||
linkCode: selected.linkCode,
|
||||
trainPosType: selected.trainPosType,
|
||||
isCurve: selected.isCurve,
|
||||
points: [
|
||||
{
|
||||
x: selected.points[0].x + triangle.getCos(this.addModel.splitOffset * 10000) / 10000,
|
||||
y: selected.points[0].y + triangle.getSin(this.addModel.splitOffset * 10000) / 10000
|
||||
},
|
||||
{
|
||||
x: selected.points[selected.points.length - 1].x,
|
||||
y: selected.points[selected.points.length - 1].y
|
||||
}
|
||||
],
|
||||
namePosition: { x: 0, y: 0 }
|
||||
};
|
||||
|
||||
const modelX = (selected.points[selected.points.length - 1].x - selected.points[0].x) / this.addModel.splitNumber;
|
||||
const modelY = (selected.points[selected.points.length - 1].y - selected.points[0].y) / this.addModel.splitNumber;
|
||||
for (let index = 1; index <= this.addModel.splitNumber; index++) {
|
||||
const model = {
|
||||
_type: 'Section',
|
||||
code: getUID('Section'),
|
||||
name: `${selected.name}_${index}`,
|
||||
type: '01',
|
||||
parentCode: '',
|
||||
axleShow: selected.axleShow,
|
||||
isStandTrack: false,
|
||||
kmRangeRight: '',
|
||||
kmRangeLeft: '',
|
||||
region: '',
|
||||
standTrackName: '',
|
||||
standTrackNamePosition: { x: 0, y: 0 },
|
||||
isReentryTrack: false,
|
||||
reentryTrackName: '',
|
||||
reentryTrackNamePosition: { x: 0, y: 0 },
|
||||
isTransferTrack: false,
|
||||
transferTrackName: '',
|
||||
transferTrackNamePosition: { x: 0, y: 0 },
|
||||
isSwitchSection: false,
|
||||
isSegmentation: false,
|
||||
segmentationPosition: { x: 0, y: 0 },
|
||||
relSwitchCode: '',
|
||||
logicSectionNameSort: selected.logicSectionNameSort,
|
||||
logicSectionNum: selected.logicSectionNum,
|
||||
logicSectionShow: selected.logicSectionShow,
|
||||
sepTypeLeft: index == 0 ? selected.sepTypeLeft : '01', // 左侧分隔符类型 (起始左侧按原来区段类型走 其余 默认 01)
|
||||
offsetLeft: selected.offsetLeft,
|
||||
sepTypeRight: index == this.addModel.splitNumber ? selected.sepTypeRight : '01', // 右侧分隔符类型 (终点右侧按原来区段类型走 其余 默认 01)
|
||||
offsetRight: selected.offsetRight,
|
||||
linkCode: selected.linkCode,
|
||||
trainPosType: selected.trainPosType,
|
||||
isCurve: selected.isCurve,
|
||||
points: [
|
||||
{
|
||||
x: selected.points[0].x + ((index - 1) * modelX),
|
||||
y: selected.points[0].y + ((index - 1) * modelY)
|
||||
},
|
||||
{
|
||||
x: selected.points[0].x + (index * modelX),
|
||||
y: selected.points[0].y + (index * modelY)
|
||||
}
|
||||
],
|
||||
namePosition: { x: 0, y: 0 }
|
||||
};
|
||||
models.push(model);
|
||||
}
|
||||
remove.push(selected);
|
||||
models.push(modelL);
|
||||
models.push(modelR);
|
||||
this.$emit('delMapModel', remove);
|
||||
this.$emit('addOrUpdateMapModel', models);
|
||||
this.$emit('delMapModel', remove); // 删除原区段
|
||||
this.$emit('addOrUpdateMapModel', models); // 添加新增拆分区段
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
// 合并区段
|
||||
merge() {
|
||||
this.$refs['oprt1'].validate((valid) => {
|
||||
if (valid) {
|
||||
@ -1121,6 +1083,7 @@ export default {
|
||||
}
|
||||
});
|
||||
},
|
||||
// 一键删除道岔区段
|
||||
removeSwitchSection() {
|
||||
const remove = [];
|
||||
if (this.sectionList && this.sectionList.length) {
|
||||
@ -1135,6 +1098,7 @@ export default {
|
||||
this.$emit('delMapModel', remove);
|
||||
}
|
||||
},
|
||||
// 一键生成道岔区段
|
||||
createSwitchSection() {
|
||||
const models = [];
|
||||
|
||||
@ -1268,6 +1232,24 @@ export default {
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
.flex_box{
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.box-card {
|
||||
width: calc(100% - 80px);
|
||||
margin: 20px auto 0;
|
||||
padding: 0 20px;
|
||||
.text {
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.item {
|
||||
padding: 18px 0;
|
||||
}
|
||||
}
|
||||
|
||||
/deep/ {
|
||||
.card .el-transfer-panel__filter{
|
||||
margin: 5px 15px;
|
||||
|
@ -291,9 +291,34 @@ export default {
|
||||
this.$refs.make.resetFields();
|
||||
this.activeName = 'first';
|
||||
if (selected && selected._type.toUpperCase() === 'Signal'.toUpperCase()) {
|
||||
Object.assign(this.editModel, selected);
|
||||
this.editModel.code = selected.code;
|
||||
this.editModel.name = selected.name;
|
||||
this.editModel.uniqueName = selected.uniqueName;
|
||||
this.editModel.nameShow = selected.nameShow;
|
||||
this.editModel.lampPostType = selected.lampPostType;
|
||||
this.editModel.lampPositionType = selected.lampPositionType;
|
||||
this.editModel.potLampType = selected.potLampType || '01';
|
||||
this.editModel.directionType = selected.directionType;
|
||||
this.editModel.positionType = selected.positionType;
|
||||
this.editModel.useType = selected.useType;
|
||||
this.editModel.stationCode = selected.stationCode;
|
||||
this.editModel.linkCode = selected.linkCode;
|
||||
this.editModel.offset = selected.offset;
|
||||
this.editModel.rotate = selected.rotate || 0; // 角度
|
||||
this.editModel.guideShow = selected.guideShow;
|
||||
this.editModel.buttonShow = selected.buttonShow;
|
||||
if (selected.position) {
|
||||
this.editModel.position = { x: selected.position.x, y: selected.position.y };
|
||||
}
|
||||
if (selected.namePosition) {
|
||||
this.editModel.namePosition = { x: selected.namePosition.x, y: selected.namePosition.y };
|
||||
}
|
||||
if (selected.buttonPosition) {
|
||||
this.editModel.buttonPosition = { x: selected.buttonPosition.x, y: selected.buttonPosition.y };
|
||||
}
|
||||
if (selected.guidePosition) {
|
||||
this.editModel.guidePosition = { x: selected.guidePosition.x, y: selected.guidePosition.y };
|
||||
}
|
||||
} else if (selected && selected._type.toUpperCase() === 'Section'.toUpperCase()) {
|
||||
// 获取逻辑区段关联的物理区段
|
||||
if (selected.type === '02') {
|
||||
@ -366,8 +391,8 @@ export default {
|
||||
edit() {
|
||||
this.$refs['dataform'].validate((valid) => {
|
||||
if (valid) {
|
||||
const model = Object.assign({_type: 'Signal'}, this.editModel);
|
||||
this.$emit('addOrUpdateMapModel', model);
|
||||
const data = Object.assign({_type: 'Link'}, this.editModel);
|
||||
this.$emit('addOrUpdateMapModel', data);
|
||||
}
|
||||
});
|
||||
},
|
||||
|
@ -187,9 +187,25 @@ export default {
|
||||
this.$refs.make.resetFields();
|
||||
this.activeName = 'first';
|
||||
if (selected && selected._type.toUpperCase() === 'Station'.toUpperCase()) {
|
||||
Object.assign(this.editModel, selected);
|
||||
this.editModel.runPlanName = selected.runPlanName || '';
|
||||
this.editModel.centralized = selected.centralized;
|
||||
this.editModel.concentrateStationCode = selected.concentrateStationCode;
|
||||
this.editModel.code = selected.code;
|
||||
this.editModel.zcCode = selected.zcCode;
|
||||
this.editModel.visible = selected.visible || false;
|
||||
this.editModel.runPlanName = selected.runPlanName || '';
|
||||
this.editModel.name = selected.name;
|
||||
this.editModel.nameFont = selected.nameFont;
|
||||
this.editModel.nameFontColor = selected.nameFontColor;
|
||||
this.editModel.kmPostShow = selected.kmPostShow;
|
||||
this.editModel.kmRange = selected.kmRange;
|
||||
this.editModel.kmPost = selected.kmPost;
|
||||
this.editModel.kmPostFont = selected.kmPostFont;
|
||||
this.editModel.kmPostFontColor = selected.kmPostFontColor;
|
||||
this.editModel.isShowControlMode = selected.isShowControlMode;
|
||||
if (selected.position) {
|
||||
this.editModel.position = { x: selected.position.x, y: selected.position.y };
|
||||
}
|
||||
} else if (selected && selected._type.toUpperCase() === 'Section'.toUpperCase()) {
|
||||
// 获取逻辑区段关联的物理区段
|
||||
if (selected.type !== '01') {
|
||||
@ -241,11 +257,36 @@ export default {
|
||||
edit() {
|
||||
this.$refs['dataform'].validate((valid) => {
|
||||
if (valid) {
|
||||
const model = Object.assign({_type: 'Station'}, this.editModel);
|
||||
this.$emit('addOrUpdateMapModel', model);
|
||||
this.$emit('addOrUpdateMapModel', this.buildEditModel());
|
||||
}
|
||||
});
|
||||
},
|
||||
buildEditModel() {
|
||||
var model = {
|
||||
_type: 'Station',
|
||||
code: this.editModel.code,
|
||||
visible: this.editModel.visible,
|
||||
runPlanName: this.editModel.runPlanName,
|
||||
name: this.editModel.name,
|
||||
zcCode: this.editModel.zcCode,
|
||||
nameFont: this.editModel.nameFont,
|
||||
nameFontColor: this.editModel.nameFontColor,
|
||||
kmPostShow: this.editModel.kmPostShow,
|
||||
kmRange: this.editModel.kmRange,
|
||||
kmPost: this.editModel.kmPost,
|
||||
kmPostFontColor: this.editModel.kmPostFontColor,
|
||||
kmPostFont: this.editModel.kmPostFont,
|
||||
isShowControlMode: this.editModel.isShowControlMode,
|
||||
centralized: this.editModel.centralized,
|
||||
concentrateStationCode: this.editModel.concentrateStationCode,
|
||||
position: {
|
||||
x: this.editModel.position.x,
|
||||
y: this.editModel.position.y
|
||||
}
|
||||
};
|
||||
|
||||
return model;
|
||||
},
|
||||
// 删除对象
|
||||
deleteObj() {
|
||||
const selected = this.$store.getters['map/getDeviceByCode'](this.editModel.code);
|
||||
|
@ -179,12 +179,16 @@ export default {
|
||||
this.$refs.make.resetFields();
|
||||
this.activeName = 'first';
|
||||
if (selected && selected._type.toUpperCase() === 'StationControl'.toUpperCase()) {
|
||||
Object.assign(this.editModel, selected);
|
||||
if (selected.hasOwnProperty('position')) {
|
||||
this.editModel.position = {
|
||||
x: selected.position.x,
|
||||
y: selected.position.y
|
||||
};
|
||||
this.editModel.name = selected.name;
|
||||
this.editModel.code = selected.code;
|
||||
this.editModel.zokContent = selected.zokContent;
|
||||
this.editModel.zakContent = selected.zakContent;
|
||||
this.editModel.jjzkContent = selected.jjzkContent;
|
||||
this.editModel.zzkContent = selected.zzkContent;
|
||||
this.editModel.stationCode = selected.stationCode;
|
||||
this.editModel.zbjkContent = selected.zbjkContent;
|
||||
if (selected.position) {
|
||||
this.editModel.position = { x: selected.position.x, y: selected.position.y };
|
||||
}
|
||||
} else if (selected && selected._type.toUpperCase() === 'Station'.toUpperCase()) {
|
||||
this.addModel.stationCode = selected.code;
|
||||
@ -224,11 +228,27 @@ export default {
|
||||
edit() {
|
||||
this.$refs['dataform'].validate((valid) => {
|
||||
if (valid) {
|
||||
const model = Object.assign({_type: 'StationControl'}, this.editModel);
|
||||
this.$emit('addOrUpdateMapModel', model);
|
||||
this.$emit('addOrUpdateMapModel', this.buildEditModel());
|
||||
}
|
||||
});
|
||||
},
|
||||
buildEditModel() {
|
||||
const model = {
|
||||
_type: 'StationControl',
|
||||
code: this.editModel.code,
|
||||
zokContent: this.editModel.zokContent,
|
||||
zbjkContent: this.editModel.zbjkContent,
|
||||
zakContent: this.editModel.zakContent,
|
||||
jjzkContent: this.editModel.jjzkContent,
|
||||
zzkContent: this.editModel.zzkContent,
|
||||
stationCode: this.editModel.stationCode,
|
||||
position: {
|
||||
x: this.editModel.position.x,
|
||||
y: this.editModel.position.y
|
||||
}
|
||||
};
|
||||
return model;
|
||||
},
|
||||
// 删除对象
|
||||
deleteObj() {
|
||||
const selected = this.$store.getters['map/getDeviceByCode'](this.editModel.code);
|
||||
|
@ -246,7 +246,7 @@ export default {
|
||||
this.editModel.stationCode = selected.stationCode;
|
||||
this.editModel.doorLocationType = selected.doorLocationType;
|
||||
this.editModel.deviceStationCode = selected.deviceStationCode;
|
||||
if (selected.hasOwnProperty('position')) {
|
||||
if (selected.position) {
|
||||
this.editModel.position = {
|
||||
x: selected.position.x,
|
||||
y: selected.position.y
|
||||
|
@ -86,17 +86,16 @@ export default {
|
||||
const list = [];
|
||||
if (this.sectionList && this.sectionList.length) {
|
||||
this.sectionList.forEach(elem => {
|
||||
if (elem.type === '01' && elem.isSwitchSection) {
|
||||
const link = this.findLinkData(elem.linkCode);
|
||||
if ((link.leftFdCode && link.leftSdCode) || (link.rightFdCode && link.rightSdCode)) {
|
||||
list.push({
|
||||
label: elem.name,
|
||||
key: elem.code,
|
||||
pinyin: elem.name
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
// if (elem.type === '01' && elem.isSwitchSection) {
|
||||
// const link = this.findLinkData(elem.linkCode);
|
||||
// if ((link.leftFdCode && link.leftSdCode) || (link.rightFdCode && link.rightSdCode)) {
|
||||
list.push({
|
||||
label: elem.name,
|
||||
key: elem.code,
|
||||
pinyin: elem.name
|
||||
});
|
||||
// }
|
||||
// }
|
||||
});
|
||||
}
|
||||
return list;
|
||||
|
@ -5,9 +5,7 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// import Vue from 'vue';
|
||||
import MapCommon from './common/index';
|
||||
// import StompClient from '@/utils/sock';
|
||||
import { handleToken } from '@/utils/auth';
|
||||
import { creatSubscribe, clearSubscribe, displayTopic, screenTopic, planTopic } from '@/utils/stomp';
|
||||
import { sendCommand } from '@/api/jmap/training';
|
||||
|
@ -43,7 +43,7 @@ export default {
|
||||
permissionType: '',
|
||||
mapId: '',
|
||||
lessonId: '',
|
||||
mapProductCode: '',
|
||||
prdCode: '',
|
||||
date: '',
|
||||
amount: 0,
|
||||
ownerId: '',
|
||||
@ -68,7 +68,7 @@ export default {
|
||||
items: [
|
||||
{ prop: 'permissionType', label: this.$t('permission.permissionType'), type: 'select', required: false, disabled: !this.isAdd, options: this.permissionTypeList, change: true, onChange: this.permissionTypeChange },
|
||||
{ prop: 'mapId', label: this.$t('permission.mapName'), type: 'select', required: false, disabled: !this.isAdd, show: this.isShowMap, options: this.publishMapList, change: true, onChange: this.mapChange },
|
||||
{ prop: 'mapProductCode', label: this.$t('permission.mapProductName'), type: 'select', required: false, disabled: !this.isAdd, show: this.isShowMapProduct, options: this.mapProductList, change: true, onChange: this.mapProductChange },
|
||||
{ prop: 'prdCode', label: this.$t('permission.mapProductName'), type: 'select', required: false, disabled: !this.isAdd, show: this.isShowMapProduct, options: this.mapProductList, change: true, onChange: this.mapProductChange },
|
||||
{ prop: 'lessonId', label: this.$t('permission.lessonName'), type: 'select', required: false, disabled: !this.isAdd, show: this.isShowLesson, options: this.filterPublisLessonList },
|
||||
{ prop: 'roleName', label: this.$t('permission.belonger'), type: 'complete', required: false, disabled: !this.isAdd && this.isAdministrator, show: this.isShowRole, querySearchAsync: this.querySearchAsync, handleSelect: this.prdSelect, placeholder: '请输入昵称/名字/手机号' },
|
||||
{ prop: 'date', label: this.$t('permission.selectDate'), type: 'daterange', required: false, viewFormat: 'yyyy-MM-dd HH:mm:ss', valueFormat: 'yyyy-MM-dd HH:mm:ss' },
|
||||
@ -86,7 +86,7 @@ export default {
|
||||
mapId: [
|
||||
{ required: true, message: this.$t('rules.selectMapName'), trigger: 'change' }
|
||||
],
|
||||
mapProductCode: [
|
||||
prdCode: [
|
||||
{ required: true, message: this.$t('rules.selectMapProductName'), trigger: 'change' }
|
||||
],
|
||||
lessonId: [
|
||||
@ -159,9 +159,9 @@ export default {
|
||||
}
|
||||
|
||||
var validator = {};
|
||||
validator[PermissionType.LESSON] = () => { return this.formModel.lessonId && this.formModel.mapId && this.formModel.mapProductCode; };
|
||||
validator[PermissionType.EXAM] = () => { return this.formModel.lessonId && this.formModel.mapId && this.formModel.mapProductCode; };
|
||||
validator[PermissionType.SIMULATION] = () => { return this.formModel.mapId && this.formModel.mapProductCode; };
|
||||
validator[PermissionType.LESSON] = () => { return this.formModel.lessonId && this.formModel.mapId && this.formModel.prdCode; };
|
||||
validator[PermissionType.EXAM] = () => { return this.formModel.lessonId && this.formModel.mapId && this.formModel.prdCode; };
|
||||
validator[PermissionType.SIMULATION] = () => { return this.formModel.mapId && this.formModel.prdCode; };
|
||||
validator[PermissionType.SCREEN] = () => { return true; };
|
||||
|
||||
if (endTime && startTime && this.formModel.permissionType && validator[this.formModel.permissionType]()) {
|
||||
@ -176,10 +176,10 @@ export default {
|
||||
if (this.formModel.permissionType == PermissionType.LESSON || this.formModel.permissionType == PermissionType.EXAM) {
|
||||
model['lessonId'] = this.formModel.lessonId;
|
||||
model['mapId'] = this.formModel.mapId;
|
||||
model['prdCode'] = this.formModel.mapProductCode;
|
||||
model['prdCode'] = this.formModel.prdCode;
|
||||
} else if (this.formModel.permissionType == PermissionType.SIMULATION) {
|
||||
model['mapId'] = this.formModel.mapId;
|
||||
model['prdCode'] = this.formModel.mapProductCode;
|
||||
model['prdCode'] = this.formModel.prdCode;
|
||||
}
|
||||
|
||||
getTotalRemains(model).then(response => {
|
||||
@ -201,11 +201,11 @@ export default {
|
||||
},
|
||||
permissionTypeChange() {
|
||||
this.formModel.mapId = '';
|
||||
this.formModel.mapProductCode = '';
|
||||
this.formModel.prdCode = '';
|
||||
this.formModel.lessonId = '';
|
||||
},
|
||||
mapChange(mapId) {
|
||||
this.formModel.mapProductCode = '';
|
||||
this.formModel.prdCode = '';
|
||||
this.formModel.lessonId = '';
|
||||
this.mapProductList = [];
|
||||
getPublishMapInfo(mapId).then(resp => {
|
||||
@ -217,9 +217,9 @@ export default {
|
||||
});
|
||||
});
|
||||
},
|
||||
mapProductChange(mapProductCode) {
|
||||
mapProductChange(prdCode) {
|
||||
this.formModel.lessonId = '';
|
||||
this.filterPublisLessonList = this.publisLessonList.filter(elem => { return elem.mapId == this.formModel.mapId && elem.prdCode == this.formModel.mapProductCode; });
|
||||
this.filterPublisLessonList = this.publisLessonList.filter(elem => { return elem.mapId == this.formModel.mapId && elem.prdCode == this.formModel.prdCode; });
|
||||
},
|
||||
// 搜索查询input
|
||||
async querySearchAsync(queryString, cb) {
|
||||
@ -259,7 +259,7 @@ export default {
|
||||
permissionType: model.permissionType,
|
||||
mapId: model.mapId,
|
||||
lessonId: model.lessonId,
|
||||
mapProductCode: model.mapProductCode,
|
||||
prdCode: model.prdCode,
|
||||
date: [model.startTime, model.endTime],
|
||||
amount: model.amount,
|
||||
ownerId: this.formModel.ownerId,
|
||||
@ -281,7 +281,7 @@ export default {
|
||||
permissionType: this.formModel.permissionType,
|
||||
mapId: this.isShowMap ? this.formModel.mapId : '',
|
||||
lessonId: this.isShowLesson ? this.formModel.lessonId : '',
|
||||
mapProductCode: this.isShowMapProduct ? this.formModel.mapProductCode : '',
|
||||
prdCode: this.isShowMapProduct ? this.formModel.prdCode : '',
|
||||
startTime: this.formModel.date[0],
|
||||
endTime: this.formModel.date[1],
|
||||
amount: this.formModel.amount,
|
||||
@ -294,7 +294,7 @@ export default {
|
||||
permissionType: this.formModel.permissionType,
|
||||
mapId: this.isShowMap ? this.formModel.mapId : '',
|
||||
lessonId: this.isShowLesson ? this.formModel.lessonId : '',
|
||||
mapProductCode: this.isShowMapProduct ? this.formModel.mapProductCode : '',
|
||||
prdCode: this.isShowMapProduct ? this.formModel.prdCode : '',
|
||||
startTime: this.formModel.date[0],
|
||||
endTime: this.formModel.date[1],
|
||||
amount: this.formModel.amount,
|
||||
|
@ -140,8 +140,8 @@ export default {
|
||||
this.$message.success('创建空运行图成功!');
|
||||
this.jump(resp.data, this.newModel.name);
|
||||
this.doClose();
|
||||
}).catch(() => {
|
||||
this.$messageBox('创建空运行图失败');
|
||||
}).catch((error) => {
|
||||
this.$messageBox('创建运行图失败:' + error.message);
|
||||
this.doClose();
|
||||
});
|
||||
}
|
||||
@ -155,8 +155,8 @@ export default {
|
||||
this.$message.success('创建运行图成功!');
|
||||
this.jump(resp.data, this.pullModel.name);
|
||||
this.doClose();
|
||||
}).catch(() => {
|
||||
this.$messageBox('创建运行图失败');
|
||||
}).catch((error) => {
|
||||
this.$messageBox('创建运行图失败:' + error.message);
|
||||
this.doClose();
|
||||
});
|
||||
}
|
||||
|
@ -47,7 +47,7 @@ export default {
|
||||
},
|
||||
computed: {
|
||||
title() {
|
||||
return '新建运行图';
|
||||
return '修改运行图名称';
|
||||
},
|
||||
rules() {
|
||||
return {
|
||||
|
@ -126,16 +126,22 @@ export default {
|
||||
},
|
||||
// 删除运行图
|
||||
handleDelete() {
|
||||
deleteRunPlan(this.planId).then(Response => {
|
||||
this.$message.success(`删除成功!`);
|
||||
if (this.planId === this.$route.query.planId) {
|
||||
const query = { skinCode: this.$route.query.skinCode, mapId: this.$route.query.mapId };
|
||||
this.$router.push({ path: `${UrlConfig.plan.tool}`, query: query });
|
||||
}
|
||||
this.doClose();
|
||||
}).catch(() => {
|
||||
this.$messageBox(this.$t('tip.deleteOperationGraphFailed'));
|
||||
});
|
||||
this.$confirm('您确认是否删除此运行图?', this.$t('tip.hint'), {
|
||||
confirmButtonText: this.$t('tip.confirm'),
|
||||
cancelButtonText: this.$t('tip.cancel'),
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
deleteRunPlan(this.planId).then(Response => {
|
||||
this.$message.success(`删除成功!`);
|
||||
if (this.planId === this.$route.query.planId) {
|
||||
const query = { skinCode: this.$route.query.skinCode, mapId: this.$route.query.mapId };
|
||||
this.$router.push({ path: `${UrlConfig.plan.tool}`, query: query });
|
||||
}
|
||||
this.doClose();
|
||||
}).catch(() => {
|
||||
this.$messageBox(this.$t('tip.deleteOperationGraphFailed'));
|
||||
});
|
||||
}).catch(() => { });
|
||||
},
|
||||
// 修改运行图名称
|
||||
handleEdit() {
|
||||
|
@ -6,7 +6,7 @@
|
||||
|
||||
<script>
|
||||
import { superAdmin } from '@/router';
|
||||
import { getRunPlanLoadList, runPlanTemplateList, listAllTempLateRunPlan } from '@/api/runplan';
|
||||
import { getRunPlanLoadList, listAllTempLateRunPlan, deleteDailyRunPlanLoad, postDailyRunPlanLoadGenerate } from '@/api/runplan';
|
||||
import { UrlConfig } from '@/router/index';
|
||||
import { listPublishMap } from '@/api/jmap/map';
|
||||
|
||||
@ -58,15 +58,20 @@ export default {
|
||||
width: '350',
|
||||
hide: () => { return this.$store.state.user.roles.indexOf(superAdmin) < 0; },
|
||||
buttons: [
|
||||
// {
|
||||
// name: this.$t('global.delete'),
|
||||
// handleClick: this.handleDelete,
|
||||
// type: 'danger',
|
||||
// },
|
||||
{
|
||||
name: this.$t('global.preview'),
|
||||
handleClick: this.handleView,
|
||||
type: ''
|
||||
},
|
||||
{
|
||||
name: '生成每日运行图',
|
||||
handleClick: this.createActionChart,
|
||||
type: ''
|
||||
},
|
||||
{
|
||||
name: this.$t('global.delete'),
|
||||
handleClick: this.handleDelete,
|
||||
type: 'danger'
|
||||
}
|
||||
]
|
||||
}
|
||||
@ -104,24 +109,32 @@ export default {
|
||||
this.$router.push({ path: `${UrlConfig.publish.runPlanCommon}/add` });
|
||||
},
|
||||
// 删除
|
||||
// handleDelete(index, row) {
|
||||
// this.$confirm('此操作将删除此通用运行图, 是否继续?', this.$t('global.tips'), {
|
||||
// confirmButtonText: this.$t('global.confirm'),
|
||||
// cancelButtonText: this.$t('global.cancel'),
|
||||
// type: 'warning'
|
||||
// }).then(() => {
|
||||
|
||||
// }).catch(() => { })
|
||||
// },
|
||||
handleDelete(index, row) {
|
||||
this.$confirm('此操作将删除此运行图, 是否继续?', this.$t('global.tips'), {
|
||||
confirmButtonText: this.$t('global.confirm'),
|
||||
cancelButtonText: this.$t('global.cancel'),
|
||||
type: 'warning'
|
||||
}).then(async () => {
|
||||
await deleteDailyRunPlanLoad(row.id);
|
||||
this.reloadTable();
|
||||
this.$message.success('删除加载计划成功!');
|
||||
}).catch(() => { });
|
||||
},
|
||||
// 生成每日运行图
|
||||
createActionChart(index, row) {
|
||||
this.$confirm('此操作将生成每日运行图, 是否继续?', this.$t('global.tips'), {
|
||||
confirmButtonText: this.$t('global.confirm'),
|
||||
cancelButtonText: this.$t('global.cancel'),
|
||||
type: 'warning'
|
||||
}).then(async () => {
|
||||
await postDailyRunPlanLoadGenerate(row.id);
|
||||
this.$message.success('加载计划创建每日计划成功!');
|
||||
}).catch(() => { });
|
||||
},
|
||||
// 预览
|
||||
handleView(index, row) {
|
||||
runPlanTemplateList({ pageSize: 10000 }).then(resp => {
|
||||
const list = resp.data.list || [];
|
||||
const index = list.findIndex(elem => { return list.id == row.templateId; });
|
||||
if (index >= 0) {
|
||||
this.$router.push({ path: `${UrlConfig.publish.runPlanView}/common`, query: { skinCode: list[index].skinCode, planId: list[index].id } });
|
||||
}
|
||||
});
|
||||
const init = this.mapList.findIndex(elem => { return elem.id == row.mapId; });
|
||||
this.$router.push({ path: `${UrlConfig.publish.runPlanView}/common`, query: { skinCode: this.mapList[init].skinCode, planId: row.templatePlanId } });
|
||||
},
|
||||
reloadTable() {
|
||||
this.queryList.reload();
|
||||
|
Loading…
Reference in New Issue
Block a user