车库门显示调整
This commit is contained in:
parent
9c95c229e5
commit
2048eb43dd
@ -112,7 +112,7 @@ const ckmFaultOption = [
|
|||||||
value: request.Ckm.Fault.FA_NONE,
|
value: request.Ckm.Fault.FA_NONE,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: '设置故障物',
|
label: '状态丢失',
|
||||||
value: request.Ckm.Fault.FA_State_Loss,
|
value: request.Ckm.Fault.FA_State_Loss,
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
|
@ -36,7 +36,8 @@ export interface IGarageDoorState extends GraphicState {
|
|||||||
const garageConsts = {
|
const garageConsts = {
|
||||||
codeFontSize: 12,
|
codeFontSize: 12,
|
||||||
codeColor: 0xffffff,
|
codeColor: 0xffffff,
|
||||||
bodyLineColor: 0x0000ff,
|
bodyLineColor: 0xffffff,
|
||||||
|
lossStateColor: 0x0000ff,
|
||||||
bodyLineWidth: 2,
|
bodyLineWidth: 2,
|
||||||
bodyColor: 0x000000,
|
bodyColor: 0x000000,
|
||||||
bodyRectWidth: 10,
|
bodyRectWidth: 10,
|
||||||
@ -81,10 +82,11 @@ export class GarageDoor extends JlGraphic {
|
|||||||
codeGraph.position.set(0, -30);
|
codeGraph.position.set(0, -30);
|
||||||
}
|
}
|
||||||
this.lineBody.clear();
|
this.lineBody.clear();
|
||||||
this.lineBody.lineStyle(
|
const color =
|
||||||
garageConsts.bodyLineWidth,
|
this.states.param?.fault === request.Ckm.Fault.FA_State_Loss
|
||||||
garageConsts.bodyLineColor
|
? garageConsts.lossStateColor
|
||||||
);
|
: garageConsts.bodyLineColor;
|
||||||
|
this.lineBody.lineStyle(garageConsts.bodyLineWidth, color);
|
||||||
this.lineBody.moveTo(
|
this.lineBody.moveTo(
|
||||||
-garageConsts.bodyRectWidth / 2,
|
-garageConsts.bodyRectWidth / 2,
|
||||||
-garageConsts.bodyRectHeight / 2
|
-garageConsts.bodyRectHeight / 2
|
||||||
@ -101,8 +103,15 @@ export class GarageDoor extends JlGraphic {
|
|||||||
garageConsts.bodyRectWidth / 2,
|
garageConsts.bodyRectWidth / 2,
|
||||||
garageConsts.bodyRectHeight / 2
|
garageConsts.bodyRectHeight / 2
|
||||||
);
|
);
|
||||||
|
if (this.states.mgj) {
|
||||||
this.lineBody.moveTo(0, -garageConsts.bodyRectHeight / 2);
|
this.lineBody.moveTo(0, -garageConsts.bodyRectHeight / 2);
|
||||||
this.lineBody.lineTo(0, garageConsts.bodyRectHeight / 2);
|
this.lineBody.lineTo(0, garageConsts.bodyRectHeight / 2);
|
||||||
|
} else {
|
||||||
|
this.lineBody.moveTo(0, -garageConsts.bodyRectHeight / 2);
|
||||||
|
this.lineBody.lineTo(0, -garageConsts.bodyRectHeight / 4);
|
||||||
|
this.lineBody.moveTo(0, garageConsts.bodyRectHeight / 4);
|
||||||
|
this.lineBody.lineTo(0, garageConsts.bodyRectHeight / 2);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
buildRelation() {
|
buildRelation() {
|
||||||
|
Loading…
Reference in New Issue
Block a user