From 5210c9d9cd3ebb92f25f6d9aa420cdd676d314ab Mon Sep 17 00:00:00 2001 From: joylink_zhaoerwei Date: Wed, 27 Mar 2024 17:04:26 +0800 Subject: [PATCH 1/8] =?UTF-8?q?=E5=B1=8F=E8=94=BD=E9=97=A8=E5=8F=B3?= =?UTF-8?q?=E9=94=AEbug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/drawApp/graphics/GarageDoorInteraction.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/drawApp/graphics/GarageDoorInteraction.ts b/src/drawApp/graphics/GarageDoorInteraction.ts index ee2b9ee..8565091 100644 --- a/src/drawApp/graphics/GarageDoorInteraction.ts +++ b/src/drawApp/graphics/GarageDoorInteraction.ts @@ -124,7 +124,7 @@ export class GarageDoorState const setCkmrParam: MenuItemOptions = { name: '设置参数' }; const ckmOperateMenu: ContextMenu = ContextMenu.init({ - name: '屏蔽门操作菜单', + name: '车库门操作菜单', groups: [ { items: [setCkmrParam], From d9b5841cfbb0270f7fc65b402e535fb2bc1875b3 Mon Sep 17 00:00:00 2001 From: joylink_fanyuhong <18706759286@163.com> Date: Wed, 27 Mar 2024 17:20:17 +0800 Subject: [PATCH 2/8] =?UTF-8?q?=E8=BD=A6=E5=BA=93=E9=97=A8=E7=8A=B6?= =?UTF-8?q?=E6=80=81=E6=98=BE=E7=A4=BA=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/line-app/states/GarageDoorState.vue | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/components/line-app/states/GarageDoorState.vue b/src/components/line-app/states/GarageDoorState.vue index 43357c3..3810abc 100644 --- a/src/components/line-app/states/GarageDoorState.vue +++ b/src/components/line-app/states/GarageDoorState.vue @@ -83,7 +83,7 @@ const list: KeyType[] = [ { label: '车库门索引', key: 'id' }, { label: '车库门名称', key: 'code', formatFn: getNameFormat }, { label: '车库门关闭', key: 'mgj', formatFn: getName }, - { label: '状态丢失', key: 'stateLoss', formatFn: getName }, + // { label: '状态丢失', key: 'stateLoss', formatFn: getName }, { label: '车库门强制', key: 'param', formatFn: getForceName }, { label: '设置故障', key: 'param', formatFn: getFaultName }, ]; @@ -127,8 +127,8 @@ function getForceName() { } function getFaultName() { - if (garageDoorFault.value == 1) return '是'; - return '否'; + if (garageDoorFault.value == request.Ckm.Fault.FA_State_Loss) return '状态丢失'; + return '无'; } function initGarageDoorState(garageDoor: GarageDoor) { From 7d2a1be457430ee0d18830eaf8a4abf5b9ec864c Mon Sep 17 00:00:00 2001 From: joylink_fanyuhong <18706759286@163.com> Date: Thu, 28 Mar 2024 09:18:23 +0800 Subject: [PATCH 3/8] =?UTF-8?q?=E8=BD=A6=E5=BA=93=E9=97=A8=E8=B0=83?= =?UTF-8?q?=E6=95=B4=E6=9A=82=E6=8F=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/drawIcon.svg | 8 - src/components/draw-app/DrawProperties.vue | 10 -- .../draw-app/properties/FloodGateProperty.vue | 95 ----------- .../properties/GarageDoorBoxProperty.vue | 78 --------- src/drawApp/common.ts | 6 +- src/drawApp/commonApp.ts | 32 ---- src/drawApp/graphics/FloodGateInteraction.ts | 85 ---------- .../graphics/GarageDoorBoxInteraction.ts | 150 ------------------ src/drawApp/lineScene.ts | 25 +-- src/graphics/floodGate/FloodGate.ts | 126 --------------- .../floodGate/FloodGateDrawAssistant.ts | 126 --------------- src/graphics/garageDoorBox/GarageDoorBox.ts | 110 ------------- .../garageDoorBox/GarageDoorBoxAssistant.ts | 132 --------------- src/layouts/DrawLayout.vue | 8 - 14 files changed, 2 insertions(+), 989 deletions(-) delete mode 100644 src/components/draw-app/properties/FloodGateProperty.vue delete mode 100644 src/components/draw-app/properties/GarageDoorBoxProperty.vue delete mode 100644 src/drawApp/graphics/FloodGateInteraction.ts delete mode 100644 src/drawApp/graphics/GarageDoorBoxInteraction.ts delete mode 100644 src/graphics/floodGate/FloodGate.ts delete mode 100644 src/graphics/floodGate/FloodGateDrawAssistant.ts delete mode 100644 src/graphics/garageDoorBox/GarageDoorBox.ts delete mode 100644 src/graphics/garageDoorBox/GarageDoorBoxAssistant.ts diff --git a/public/drawIcon.svg b/public/drawIcon.svg index b214fc1..1a825dc 100644 --- a/public/drawIcon.svg +++ b/public/drawIcon.svg @@ -32,11 +32,6 @@ - - - - - @@ -83,7 +78,4 @@ - - - diff --git a/src/components/draw-app/DrawProperties.vue b/src/components/draw-app/DrawProperties.vue index dc9b47c..ac88326 100644 --- a/src/components/draw-app/DrawProperties.vue +++ b/src/components/draw-app/DrawProperties.vue @@ -139,18 +139,12 @@ drawStore.selectedGraphicType === ConcentrationDividingLine.Type " /> - - @@ -65,7 +65,7 @@ import { Transponder } from 'src/graphics/transponder/Transponder'; import { GarageDoor } from 'src/graphics/garageDoor/GarageDoor'; import GarageDoorState from './states/GarageDoorState.vue'; import { FloodGate } from 'src/graphics/floodGate/FloodGate'; -import FloodGateProperty from '../draw-app/properties/FloodGateProperty.vue'; +import FloodGateState from './states/FloodGateState.vue'; const lineStore = useLineStore(); diff --git a/src/components/line-app/states/FloodGateState.vue b/src/components/line-app/states/FloodGateState.vue index f203529..acdf9b7 100644 --- a/src/components/line-app/states/FloodGateState.vue +++ b/src/components/line-app/states/FloodGateState.vue @@ -83,7 +83,6 @@ const list: KeyType[] = [ { label: '防淹门索引', key: 'id' }, { label: '防淹门名称', key: 'code', formatFn: getNameFormat }, { label: '防淹门关闭', key: 'mgj', formatFn: getName }, - // { label: '状态丢失', key: 'stateLoss', formatFn: getName }, { label: '防淹门强制', key: 'param', formatFn: getForceName }, { label: '设置故障', key: 'param', formatFn: getFaultName }, ]; @@ -105,6 +104,7 @@ watch( ); onMounted(() => { + console.log('1111111111'); if (lineStore.selectedGraphics) { initFloodGateState(lineStore.selectedGraphics[0] as FloodGate); } diff --git a/src/configs/UrlManage.ts b/src/configs/UrlManage.ts index b047e37..62d1883 100644 --- a/src/configs/UrlManage.ts +++ b/src/configs/UrlManage.ts @@ -9,7 +9,7 @@ function getHost(): string { // return '192.168.3.7:9091'; // return '192.168.3.47:9091'; // return '192.168.3.37:9091'; - // return '192.168.33.207:9091'; // 张骞 + return '192.168.33.207:9091'; // 张骞 // return '192.168.33.93:9091'; // return '192.168.3.37:9091'; //卫志宏 // return 'test.joylink.club/bjrtsts-service'; // 测试 diff --git a/src/drawApp/graphics/FloodGateInteraction.ts b/src/drawApp/graphics/FloodGateInteraction.ts index 8e24bb5..3cfd8c4 100644 --- a/src/drawApp/graphics/FloodGateInteraction.ts +++ b/src/drawApp/graphics/FloodGateInteraction.ts @@ -102,13 +102,6 @@ export class FloodGateState set mgj(v: boolean) { this.states.mgj = v; } - get stateLoss(): boolean { - //状态丢失 - return this.states.stateLoss; - } - set stateLoss(v: boolean) { - this.states.stateLoss = v; - } get param(): request.CkmParam { return this.states.param; } diff --git a/src/drawApp/graphics/GarageDoorInteraction.ts b/src/drawApp/graphics/GarageDoorInteraction.ts index c13c337..8ec0801 100644 --- a/src/drawApp/graphics/GarageDoorInteraction.ts +++ b/src/drawApp/graphics/GarageDoorInteraction.ts @@ -102,13 +102,6 @@ export class GarageDoorState set mgj(v: boolean) { this.states.mgj = v; } - get stateLoss(): boolean { - //状态丢失 - return this.states.stateLoss; - } - set stateLoss(v: boolean) { - this.states.stateLoss = v; - } get param(): request.CkmParam { return this.states.param; } diff --git a/src/drawApp/lineScene.ts b/src/drawApp/lineScene.ts index 393b70d..44b210e 100644 --- a/src/drawApp/lineScene.ts +++ b/src/drawApp/lineScene.ts @@ -459,6 +459,11 @@ function handleSubscribe(lineScene: IGraphicScene) { states.push(new GarageDoorState(item)); } }); + storage.allStatus.fymStates.forEach((item) => { + if (item.id) { + states.push(new FloodGateState(item)); + } + }); storage.allStatus.trainState.forEach((item) => { // 列车 if (!item.show) { diff --git a/src/graphics/floodGate/FloodGate.ts b/src/graphics/floodGate/FloodGate.ts index 7aa5d39..1638474 100644 --- a/src/graphics/floodGate/FloodGate.ts +++ b/src/graphics/floodGate/FloodGate.ts @@ -31,8 +31,6 @@ export interface IFloodGateState extends GraphicState { set mgj(v: boolean); get param(): request.CkmParam; set param(v: request.CkmParam); - get stateLoss(): boolean; //状态丢失 - set stateLoss(v: boolean); } const garageConsts = { diff --git a/src/graphics/garageDoor/GarageDoor.ts b/src/graphics/garageDoor/GarageDoor.ts index a9f305f..67f28ca 100644 --- a/src/graphics/garageDoor/GarageDoor.ts +++ b/src/graphics/garageDoor/GarageDoor.ts @@ -31,8 +31,6 @@ export interface IGarageDoorState extends GraphicState { set mgj(v: boolean); get param(): request.CkmParam; set param(v: request.CkmParam); - get stateLoss(): boolean; //状态丢失 - set stateLoss(v: boolean); } const garageConsts = { diff --git a/src/protos/device_state.ts b/src/protos/device_state.ts index d13e99e..c63d7f0 100644 --- a/src/protos/device_state.ts +++ b/src/protos/device_state.ts @@ -6879,7 +6879,6 @@ export namespace state { id?: number; mgj?: boolean; param?: dependency_3.request.CkmParam; - stateLoss?: boolean; }) { super(); pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls); @@ -6893,9 +6892,6 @@ export namespace state { if ("param" in data && data.param != undefined) { this.param = data.param; } - if ("stateLoss" in data && data.stateLoss != undefined) { - this.stateLoss = data.stateLoss; - } } } get id() { @@ -6919,17 +6915,10 @@ export namespace state { get has_param() { return pb_1.Message.getField(this, 3) != null; } - get stateLoss() { - return pb_1.Message.getFieldWithDefault(this, 4, false) as boolean; - } - set stateLoss(value: boolean) { - pb_1.Message.setField(this, 4, value); - } static fromObject(data: { id?: number; mgj?: boolean; param?: ReturnType; - stateLoss?: boolean; }): CkmState { const message = new CkmState({}); if (data.id != null) { @@ -6941,9 +6930,6 @@ export namespace state { if (data.param != null) { message.param = dependency_3.request.CkmParam.fromObject(data.param); } - if (data.stateLoss != null) { - message.stateLoss = data.stateLoss; - } return message; } toObject() { @@ -6951,7 +6937,6 @@ export namespace state { id?: number; mgj?: boolean; param?: ReturnType; - stateLoss?: boolean; } = {}; if (this.id != null) { data.id = this.id; @@ -6962,9 +6947,6 @@ export namespace state { if (this.param != null) { data.param = this.param.toObject(); } - if (this.stateLoss != null) { - data.stateLoss = this.stateLoss; - } return data; } serialize(): Uint8Array; @@ -6977,8 +6959,6 @@ export namespace state { writer.writeBool(2, this.mgj); if (this.has_param) writer.writeMessage(3, this.param, () => this.param.serialize(writer)); - if (this.stateLoss != false) - writer.writeBool(4, this.stateLoss); if (!w) return writer.getResultBuffer(); } @@ -6997,9 +6977,6 @@ export namespace state { case 3: reader.readMessage(message.param, () => message.param = dependency_3.request.CkmParam.deserialize(reader)); break; - case 4: - message.stateLoss = reader.readBool(); - break; default: reader.skipField(); } }