| | |
| | | 'site-run-block': 0xe69138, |
| | | 'site-error': 0xDB2828 |
| | | }, |
| | | fakeOperationVisible: false, |
| | | tickerMap: new Map() |
| | | }; |
| | | fakeOperationVisible: false |
| | | } |
| | | }, |
| | | mounted() { |
| | | this.DEVICE_MAP = { |
| | | crn: { |
| | | createTexture: this.createCrnTexture, |
| | | graphics: this.graphicsCrn, |
| | | emitName: 'crn-click', |
| | | pixiMap: this.pixiCrnMap, |
| | | type: 'crn', |
| | | idName: 'crnId', |
| | | statusInfo: { |
| | | name: 'crnStatus', |
| | | getStatus: this.getCrnStatusColor, |
| | | updateTextureColor: this.updateCrnTextureColor |
| | | } |
| | | }, |
| | | dualcrn: { |
| | | createTexture: this.createCrnTexture, |
| | | graphics: this.graphicsCrn, |
| | | emitName: 'dual-crn-click', |
| | | pixiMap: this.pixiDualCrnMap, |
| | | type: 'dualCrn', |
| | | idName: 'crnId', |
| | | statusInfo: { |
| | | name: 'crnStatus', |
| | | getStatus: this.getCrnStatusColor, |
| | | updateTextureColor: this.updateCrnTextureColor |
| | | } |
| | | }, |
| | | rgv: { |
| | | createTexture: this.createRgvTexture, |
| | | graphics: this.graphicsRgv, |
| | | emitName: 'rgv-click', |
| | | pixiMap: this.pixiRgvMap, |
| | | type: 'rgv', |
| | | idName: 'rgvNo', |
| | | statusInfo: { |
| | | name: 'rgvStatus', |
| | | getStatus: this.getRgvStatusColor, |
| | | updateTextureColor: this.updateRgvTextureColor |
| | | } |
| | | } |
| | | }; |
| | | this.DEVICE_MAP.dualCrn = this.DEVICE_MAP.dualcrn; |
| | | mounted() { |
| | | this.currentLev = this.lev || 1; |
| | | this.createMap(); |
| | | this.startContainerResizeObserve(); |
| | |
| | | } |
| | | window.open(url, '_blank'); |
| | | }, |
| | | loadFakeProcessStatus() { |
| | | if (typeof window === 'undefined' || typeof $ === 'undefined' || typeof baseUrl === 'undefined') { |
| | | this.fakeOperationVisible = false; |
| | | return; |
| | | } |
| | | $.ajax({ |
| | | url: baseUrl + '/openapi/getFakeSystemRunStatus', |
| | | method: 'get', |
| | | success: function (res) { |
| | | const data = res && res.data ? res.data : null; |
| | | this.fakeOperationVisible = !!(data && data.isFake); |
| | | }.bind(this), |
| | | error: function () { |
| | | this.fakeOperationVisible = false; |
| | | }.bind(this) |
| | | }); |
| | | }, |
| | | openFakeOperationConfigPage() { |
| | | if (typeof window === 'undefined' || !this.fakeOperationVisible) { return; } |
| | | const url = (typeof baseUrl !== 'undefined' ? baseUrl : '') + '/views/watch/fakeOperationConfig.html'; |
| | | const layerInstance = (window.top && window.top.layer) || window.layer; |
| | | if (layerInstance && typeof layerInstance.open === 'function') { |
| | | layerInstance.open({ |
| | | type: 2, |
| | | title: '仿真操作', |
| | | maxmin: true, |
| | | area: ['1180px', '820px'], |
| | | shadeClose: false, |
| | | content: url |
| | | }); |
| | | return; |
| | | } |
| | | window.open(url, '_blank'); |
| | | }, |
| | | parseRotation(value) { |
| | | const num = parseInt(value, 10); |
| | | if (!isFinite(num)) { |