diff --git a/src/components/draw-app/dialogs/DeviceRelateRelayList.vue b/src/components/draw-app/dialogs/DeviceRelateRelayList.vue
index 3e8d79b..e778cf0 100644
--- a/src/components/draw-app/dialogs/DeviceRelateRelayList.vue
+++ b/src/components/draw-app/dialogs/DeviceRelateRelayList.vue
@@ -70,6 +70,8 @@ const deviceTypeMap = {
11: '车库门',
12: '洗车机',
13: '防淹门',
+ 14: '站台',
+ 15: '零散',
};
const columns: QTable['columns'] = [
{
diff --git a/src/components/draw-app/properties/RelateRelayConfig.vue b/src/components/draw-app/properties/RelateRelayConfig.vue
index e4fc775..c45795e 100644
--- a/src/components/draw-app/properties/RelateRelayConfig.vue
+++ b/src/components/draw-app/properties/RelateRelayConfig.vue
@@ -90,12 +90,15 @@ const optionsType = [
{ label: '洗车机', value: graphicData.RelatedRef.DeviceType.CarWashing },
{ label: '防淹门', value: graphicData.RelatedRef.DeviceType.FloodGate },
{ label: '区段', value: graphicData.RelatedRef.DeviceType.Section },
+ { label: '站台', value: graphicData.RelatedRef.DeviceType.Platform },
+ { label: '零散', value: graphicData.RelatedRef.DeviceType.LS },
];
const noShowType = [
graphicData.RelatedRef.DeviceType.SignalFaultAlarm,
graphicData.RelatedRef.DeviceType.Breakers,
graphicData.RelatedRef.DeviceType.PowerScreen,
+ graphicData.RelatedRef.DeviceType.LS,
];
onMounted(() => {
diff --git a/src/components/draw-app/properties/RelayProperty.vue b/src/components/draw-app/properties/RelayProperty.vue
index 55bcbff..bbf23c4 100644
--- a/src/components/draw-app/properties/RelayProperty.vue
+++ b/src/components/draw-app/properties/RelayProperty.vue
@@ -10,6 +10,15 @@
label="编号"
lazy-rules
/>
+
([
[
@@ -860,4 +896,6 @@ export const ciCjMap = new Map([
[`${DeviceType.CarWashing}+undefined`, carWashingCjList],
[`${DeviceType.FloodGate}+undefined`, floodGateCjList],
[`${DeviceType.Section}+undefined`, sectionCjList],
+ [`${DeviceType.Platform}+undefined`, platformCjList],
+ [`${DeviceType.LS}+undefined`, LSCjList],
]);
diff --git a/src/layouts/RelayCabinetLayout/GeneraterDevice.ts b/src/layouts/RelayCabinetLayout/GeneraterDevice.ts
index 60497a7..b90d491 100644
--- a/src/layouts/RelayCabinetLayout/GeneraterDevice.ts
+++ b/src/layouts/RelayCabinetLayout/GeneraterDevice.ts
@@ -24,6 +24,7 @@ export interface GenerateRelaysCongig {
combinationCode: string;
type?: GenerateDeviceType;
deviceCode?: string;
+ showCode?: string;
}
export function generateRelayCabinet(
@@ -79,6 +80,9 @@ export function generateRelays(
generateDevice.id = relaysInfo.id;
generateDevice.datas.code = relaysInfo.code;
generateDevice.datas.newModel = relaysInfo.model;
+ if (relaysInfo.showCode) {
+ generateDevice.datas.showCode = relaysInfo.showCode;
+ }
relaysInfos.shift();
}
} else {
@@ -122,6 +126,9 @@ function generateRelaysFormat(
generateDevice.id = relaysInfo.id;
generateDevice.datas.code = relaysInfo.code;
generateDevice.datas.newModel = relaysInfo.model;
+ if (relaysInfo.showCode) {
+ generateDevice.datas.showCode = relaysInfo.showCode;
+ }
}
generateDevice.position.set(
relayCabinet.x -
diff --git a/src/layouts/RelayCabinetLayout/GeneraterRelayLayoutConfig.ts b/src/layouts/RelayCabinetLayout/GeneraterRelayLayoutConfig.ts
index a51cad3..b917bc5 100644
--- a/src/layouts/RelayCabinetLayout/GeneraterRelayLayoutConfig.ts
+++ b/src/layouts/RelayCabinetLayout/GeneraterRelayLayoutConfig.ts
@@ -4,50 +4,23 @@ import { ref, watch } from 'vue';
export const RelayModelType = relayCabinetGraphicData.Relay.ModelType;
export type GenerateDeviceType = 'Relay' | 'PhaseFailureProtector';
+export enum ShowCodeType {
+ NO,
+ zhonghe,
+}
export interface Combinationtype {
code: string;
refDeviceCodesAndModel: {
code: string;
model: relayCabinetGraphicData.Relay.ModelType;
type?: GenerateDeviceType;
+ showCode?: {
+ zhonghe?: string;
+ };
}[];
}
//道岔组合类型
-const turoutRefDeviceCodesAndModel = [
- {
- code: '1DQJ',
- model: RelayModelType.JWJXC_H125_80,
- },
- {
- code: '1DQJF',
- model: RelayModelType.JWJXC_480,
- },
- {
- code: '2DQJ',
- model: RelayModelType.JYJXC_160_260,
- },
- {
- code: 'BHJ',
- model: RelayModelType.JWXC_1700,
- },
- {
- code: 'DBJ',
- model: RelayModelType.JPXC_1000,
- },
- {
- code: 'FBJ',
- model: RelayModelType.JPXC_1000,
- },
- {
- code: 'QDJ',
- model: RelayModelType.JWXC_1700,
- },
- {
- code: 'ZBHJ',
- model: RelayModelType.JWXC_1700,
- },
-];
const singleTuroutCombinations = [
{
code: 'moban',
@@ -89,7 +62,44 @@ const doubleTuroutCombinations = [
{
code: 'TDFJ1',
refDeviceCodesAndModel: [
- ...turoutRefDeviceCodesAndModel,
+ {
+ code: '1DQJ',
+ model: RelayModelType.JWJXC_H125_80,
+ },
+ {
+ code: '1DQJF',
+ model: RelayModelType.JWJXC_480,
+ },
+ {
+ code: '2DQJ',
+ model: RelayModelType.JYJXC_160_260,
+ },
+ {
+ code: 'BHJ',
+ model: RelayModelType.JWXC_1700,
+ },
+ {
+ code: 'DBJ',
+ model: RelayModelType.JPXC_1000,
+ showCode: {
+ zhonghe: 'DBJ1',
+ },
+ },
+ {
+ code: 'FBJ',
+ model: RelayModelType.JPXC_1000,
+ showCode: {
+ zhonghe: 'FBJ1',
+ },
+ },
+ {
+ code: 'QDJ',
+ model: RelayModelType.JWXC_1700,
+ },
+ {
+ code: 'ZBHJ',
+ model: RelayModelType.JWXC_1700,
+ },
{
code: 'DBQ',
model: RelayModelType.Unknown,
@@ -100,7 +110,36 @@ const doubleTuroutCombinations = [
{
code: 'TDFJ2',
refDeviceCodesAndModel: [
- ...turoutRefDeviceCodesAndModel.slice(0, 6),
+ {
+ code: '1DQJ',
+ model: RelayModelType.JWJXC_H125_80,
+ },
+ {
+ code: '1DQJF',
+ model: RelayModelType.JWJXC_480,
+ },
+ {
+ code: '2DQJ',
+ model: RelayModelType.JYJXC_160_260,
+ },
+ {
+ code: 'BHJ',
+ model: RelayModelType.JWXC_1700,
+ },
+ {
+ code: 'DBJ',
+ model: RelayModelType.JPXC_1000,
+ showCode: {
+ zhonghe: 'DBJ2',
+ },
+ },
+ {
+ code: 'FBJ',
+ model: RelayModelType.JPXC_1000,
+ showCode: {
+ zhonghe: 'FBJ2',
+ },
+ },
{
code: 'DBQ',
model: RelayModelType.Unknown,
@@ -127,6 +166,9 @@ const signalRefDeviceCodesAndModel = [
{
code: 'LXJ',
model: RelayModelType.JWXC_1700,
+ showCode: {
+ zhonghe: 'LJ',
+ },
},
{
code: 'YXJ',
@@ -135,6 +177,9 @@ const signalRefDeviceCodesAndModel = [
{
code: 'ZXJ',
model: RelayModelType.JWXC_1700,
+ showCode: {
+ zhonghe: 'UJ',
+ },
},
];
@@ -288,10 +333,16 @@ const PSDRefDeviceCodesAndModel = [
{
code: 'XMGJ',
model: RelayModelType.JWXC_1700,
+ showCode: {
+ zhonghe: 'GSJ',
+ },
},
{
code: 'XMPLJ',
model: RelayModelType.JWXC_1700,
+ showCode: {
+ zhonghe: 'PLJ',
+ },
},
];
const downScreenDoorCombinations = [
@@ -303,6 +354,9 @@ const downScreenDoorCombinations = [
code: string;
model: relayCabinetGraphicData.Relay.ModelType;
type?: GenerateDeviceType;
+ showCode?: {
+ zhonghe?: string;
+ };
}[],
},
{
@@ -376,6 +430,7 @@ watch(changeScreenDoorGroup, (group) => {
return {
code: item.code.replace('X', 'S'),
model: item.model,
+ showCode: item.showCode,
};
});
});
@@ -427,6 +482,23 @@ const powerScreenCombinations = [
},
];
+//LS
+const LSCombinations = [
+ {
+ code: 'LS',
+ refDeviceCodesAndModel: [
+ {
+ code: 'GDJ',
+ model: RelayModelType.JWXC_1700,
+ },
+ {
+ code: 'ZFWJ',
+ model: RelayModelType.JWXC_1700,
+ },
+ ],
+ },
+];
+
//车库门
const garageDoorCombinations = [
{
@@ -526,6 +598,19 @@ const sectionCombinations = [
},
];
+//IBP盘扣车继电器
+const platformCombinations = [
+ {
+ code: 'IKC',
+ refDeviceCodesAndModel: [
+ {
+ code: 'IKCJ',
+ model: RelayModelType.JWXC_1700,
+ },
+ ],
+ },
+];
+
const DeviceType = graphicData.RelatedRef.DeviceType;
export const combinationsMap = new Map([
[
@@ -572,4 +657,6 @@ export const combinationsMap = new Map([
[`${DeviceType.CarWashing}`, carWashingCombinations],
[`${DeviceType.FloodGate}`, floodGateCombinations],
[`${DeviceType.Section}`, sectionCombinations],
+ [`${DeviceType.Platform}`, platformCombinations],
+ [`${DeviceType.LS}`, LSCombinations],
]);
diff --git a/src/layouts/RelayCabinetLayout/RelayCabinetLayout.vue b/src/layouts/RelayCabinetLayout/RelayCabinetLayout.vue
index d275d52..6e1061a 100644
--- a/src/layouts/RelayCabinetLayout/RelayCabinetLayout.vue
+++ b/src/layouts/RelayCabinetLayout/RelayCabinetLayout.vue
@@ -197,6 +197,14 @@
label="集中站"
:rules="[(val) => val != '' || '集中站不能为空']"
>
+
+
({
publishId: '',
centralizedStation: 0,
generateCJQD: true,
generateSectionRelay: false,
+ generateIKCJRelay: false,
+ showCodeType: ShowCodeType.NO,
});
let publishIdOption = ref<{ label: string; value: number }[]>();
@@ -490,6 +507,17 @@ let centralizedStationsOption = ref<{ label: string; value: number }[]>([
{ label: '', value: 0 },
]);
+let showCodeTypeOption = [
+ {
+ label: '无',
+ value: ShowCodeType.NO,
+ },
+ {
+ label: '众合',
+ value: ShowCodeType.zhonghe,
+ },
+];
+
async function openGeneraterRelayLayoutDialog() {
generaterRelayLayoutDialog.value = true;
const response = await pageQuery({
@@ -624,6 +652,20 @@ function oneClickGeneraterRelayLayout() {
stationManagePlatformsRefEsb = Array.from(
new Set(stationManagePlatformsRefEsb)
);
+ //站台--关联的扣车继电器
+ const deviceCombinationsOfPlatform = combinationsMap.get(
+ `${DeviceType.Platform}`
+ );
+ if (
+ generaterRelayLayout.value.generateIKCJRelay &&
+ deviceCombinationsOfPlatform
+ ) {
+ creatDeviceRelateRelays(
+ deviceCombinationsOfPlatform,
+ DeviceType.Platform,
+ platform.code
+ );
+ }
}
});
const stationManageScreenDoor: number[] = [];
@@ -632,48 +674,24 @@ function oneClickGeneraterRelayLayout() {
stationManageScreenDoor.push(screenDoor.common.id);
}
});
- for (let i = 0; i < storage.esbButtons.length; i++) {
- if (
- stationManagePlatformsId.includes(storage.esbButtons[i].refStand)
- ) {
- hasEMP_MKX_SPKS.hasEMP = true;
- handleEMPCombination();
- break;
- }
- }
- for (let i = 0; i < storage.gateBoxs.length; i++) {
- if (
- stationManageScreenDoor.includes(
- storage.gateBoxs[i].refScreenDoor
- )
- ) {
- hasEMP_MKX_SPKS.hasMKX = true;
- handleDeviceCombinations.push(deviceCombinations[0]);
- break;
- }
- }
- for (let i = 0; i < storage.spksSwitchs.length; i++) {
- if (
- stationManagePlatformsId.includes(storage.spksSwitchs[i].refStand)
- ) {
- hasEMP_MKX_SPKS.hasSPKS = true;
- handleDeviceCombinations.push(deviceCombinations[1]);
- break;
- }
+ //站台关联的紧急停车继电器的编号
+ if (stationManagePlatformsRefEsb.length) {
+ hasEMP_MKX_SPKS.hasEMP = true;
+ handleEMPCombination();
}
+ //有画pslBox
for (let i = 0; i < storage.pslBoxs.length; i++) {
if (
stationManagePlatformsId.includes(
storage.pslBoxs[i].refPlatformId
)
) {
- hasEMP_MKX_SPKS.hasEMP = true;
- handleEMPCombination();
hasEMP_MKX_SPKS.hasMKX = true;
handleDeviceCombinations.push(deviceCombinations[0]);
break;
}
}
+ //有画ibpBox且对应的ibp图中有相关spks按钮
for (let i = 0; i < storage.ibpBoxs.length; i++) {
if (station.common.id == storage.ibpBoxs[i].refStationId) {
hasEMP_MKX_SPKS.hasSPKS = true;
@@ -836,7 +854,7 @@ function oneClickGeneraterRelayLayout() {
}
});
}
- //信号机故障报警仪-电源屏-断路器
+ //信号机故障报警仪-电源屏-断路器-LS设备
const aboveCombinations = [
{
combinations: combinationsMap.get(`${DeviceType.SignalFaultAlarm}`),
@@ -850,6 +868,10 @@ function oneClickGeneraterRelayLayout() {
combinations: combinationsMap.get(`${DeviceType.PowerScreen}`),
deviceType: DeviceType.PowerScreen,
},
+ {
+ combinations: combinationsMap.get(`${DeviceType.LS}`),
+ deviceType: DeviceType.LS,
+ },
];
aboveCombinations.forEach((aboveCombination) => {
if (aboveCombination.combinations) {
@@ -1054,6 +1076,12 @@ function oneClickGeneraterRelayLayout() {
combinationtype.refDeviceCodesAndModel.forEach((relay) => {
const id = GraphicIdGenerator.next();
refRelayIds.push(id);
+ let showCode = undefined;
+ if (
+ generaterRelayLayout.value.showCodeType == ShowCodeType.zhonghe
+ ) {
+ showCode = relay.showCode?.zhonghe;
+ }
generateRelays.push({
id,
code: relay.code,
@@ -1061,6 +1089,7 @@ function oneClickGeneraterRelayLayout() {
type: relay.type,
deviceCode,
combinationCode: combinationtype.code,
+ showCode,
});
if (deviceCode) {
generateRelaysMap.set(
diff --git a/src/protos/relayCabinetLayoutGraphics.ts b/src/protos/relayCabinetLayoutGraphics.ts
index d3721e4..6a04569 100644
--- a/src/protos/relayCabinetLayoutGraphics.ts
+++ b/src/protos/relayCabinetLayoutGraphics.ts
@@ -368,6 +368,7 @@ export namespace relayCabinetGraphicData {
common?: dependency_1.graphicData.CommonInfo;
code?: string;
newModel?: Relay.ModelType;
+ showCode?: string;
}) {
super();
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
@@ -381,6 +382,9 @@ export namespace relayCabinetGraphicData {
if ("newModel" in data && data.newModel != undefined) {
this.newModel = data.newModel;
}
+ if ("showCode" in data && data.showCode != undefined) {
+ this.showCode = data.showCode;
+ }
}
}
get common() {
@@ -404,10 +408,17 @@ export namespace relayCabinetGraphicData {
set newModel(value: Relay.ModelType) {
pb_1.Message.setField(this, 4, value);
}
+ get showCode() {
+ return pb_1.Message.getFieldWithDefault(this, 5, "") as string;
+ }
+ set showCode(value: string) {
+ pb_1.Message.setField(this, 5, value);
+ }
static fromObject(data: {
common?: ReturnType;
code?: string;
newModel?: Relay.ModelType;
+ showCode?: string;
}): Relay {
const message = new Relay({});
if (data.common != null) {
@@ -419,6 +430,9 @@ export namespace relayCabinetGraphicData {
if (data.newModel != null) {
message.newModel = data.newModel;
}
+ if (data.showCode != null) {
+ message.showCode = data.showCode;
+ }
return message;
}
toObject() {
@@ -426,6 +440,7 @@ export namespace relayCabinetGraphicData {
common?: ReturnType;
code?: string;
newModel?: Relay.ModelType;
+ showCode?: string;
} = {};
if (this.common != null) {
data.common = this.common.toObject();
@@ -436,6 +451,9 @@ export namespace relayCabinetGraphicData {
if (this.newModel != null) {
data.newModel = this.newModel;
}
+ if (this.showCode != null) {
+ data.showCode = this.showCode;
+ }
return data;
}
serialize(): Uint8Array;
@@ -448,6 +466,8 @@ export namespace relayCabinetGraphicData {
writer.writeString(2, this.code);
if (this.newModel != Relay.ModelType.Unknown)
writer.writeEnum(4, this.newModel);
+ if (this.showCode.length)
+ writer.writeString(5, this.showCode);
if (!w)
return writer.getResultBuffer();
}
@@ -466,6 +486,9 @@ export namespace relayCabinetGraphicData {
case 4:
message.newModel = reader.readEnum();
break;
+ case 5:
+ message.showCode = reader.readString();
+ break;
default: reader.skipField();
}
}
diff --git a/src/protos/stationLayoutGraphics.ts b/src/protos/stationLayoutGraphics.ts
index ac93a7e..cfbd549 100644
--- a/src/protos/stationLayoutGraphics.ts
+++ b/src/protos/stationLayoutGraphics.ts
@@ -4709,7 +4709,9 @@ export namespace graphicData {
PowerScreen = 10,
GarageDoor = 11,
CarWashing = 12,
- FloodGate = 13
+ FloodGate = 13,
+ Platform = 14,
+ LS = 15
}
export enum DevicePort {
A = 0,