iscs bas 大系统

This commit is contained in:
xzb 2023-12-25 17:31:35 +08:00
parent df69a319d5
commit d868465505
15 changed files with 518 additions and 584 deletions

View File

@ -1,11 +0,0 @@
package component
// ExhaustPavilion 排风亭
type ExhaustPavilion struct {
Normal bool //true-正常
}
// AirSupplyPavilion 送风亭
type AirSupplyPavilion struct {
Normal bool //true-正常
}

View File

@ -0,0 +1,17 @@
package component
import "joylink.club/ecs"
// AirConditioning 空调
type AirConditioning struct {
Running bool //true-运行正常false-停止
}
var (
AirConditioningType = ecs.NewComponentType[AirConditioning]() //空调
CombinationAirConditionerTag = ecs.NewTag() //组合式空调
AirConditioningGroupTag = ecs.NewTag() //空调群控系统
AirConditionerTag = ecs.NewTag() //空调器
)

View File

@ -0,0 +1,14 @@
package component
import "joylink.club/ecs"
// AirPavilion 风亭(排风亭、送风亭)
type AirPavilion struct {
Normal bool //true-正常
}
var (
AirPavilionType = ecs.NewComponentType[AirPavilion]() //风亭
ExhaustPavilionTag = ecs.NewTag() //排风亭
AirSupplyPavilionTag = ecs.NewTag() //送风亭
)

View File

@ -1,48 +1,43 @@
package component package component
import ( import "joylink.club/ecs"
"joylink.club/ecs"
)
//环境与设备监控系统BAS 相关组件定义 // FanDevice 风机设备
// Fan 风机设备
// 正转即顺时针转-排风;反转即逆时针转-进风 // 正转即顺时针转-排风;反转即逆时针转-进风
type Fan struct { type FanDevice struct {
Fc bool //true-变频器开启 Speed uint16 //风机转速r/min
Bypass bool //true-旁路开启 Forward bool //true-正转false-反转
SoftStart bool //true-软启开启
Power int //风机电源大于0接通正转相序电源小于0接通反转相序电源等于0关闭电源
} }
// FanState 面向用户的风机状态 // FanFcUnit 风机变频器
// 具体异常-故障、报警、异常、通信中断 type FanFcUnit struct {
type FanState struct { Fc bool //true-变频器已开启
Forward bool //true-正转false-反转
Running bool //true-运行false-停止
Fc bool //true-变频器开启
Bypass bool //true-旁路开启
SoftStart bool //true-软启开启
HighSpeed bool //true-双速风机之扇叶高速运转
SlowSpeed bool //true-双速风机之扇叶低速运转
} }
// AirConditionerGroup 空调群控系统 // FanBypassUnit 风机旁路装置
// 具体异常-故障、异常、通信中断 type FanBypassUnit struct {
type AirConditionerGroup struct { Bypass bool //true-风机旁路已开启
Acs []*ecs.Entry //空调群 }
GroupRunning bool //true-空调群中所有空调正常运行
// FanSoftStartUnit 风机软启装置
type FanSoftStartUnit struct {
SoftStart bool //true-风机软启已开启
}
// FanHighLowSpeedMode 风机双速模式控制
type FanHighLowSpeedMode struct {
HighMode bool //true-风机高速模式false-风机低速模式
} }
var ( var (
FanType = ecs.NewComponentType[Fan]() //风机 FanDeviceType = ecs.NewComponentType[FanDevice]() //风机设备
FanStateType = ecs.NewComponentType[FanState]() FanFcUnitType = ecs.NewComponentType[FanFcUnit]() //风机变频装置
FanBypassUnitType = ecs.NewComponentType[FanBypassUnit]() //风机旁路装置
TwoSpeedFanTag = ecs.NewTag() //双速风机标签 FanSoftStartUnitType = ecs.NewComponentType[FanSoftStartUnit]() //风机软启装置
LowSpeedModeFanTag = ecs.NewTag() //双速风机低速运行模式标签 FanHighLowSpeedModeType = ecs.NewComponentType[FanHighLowSpeedMode]() //风机双速模式控制
HighSpeedModeFanTag = ecs.NewTag() //双速风机高速运行模式标签
AirConditionerTag = ecs.NewTag() //空调、空调器
CombinedAirConditionerTag = ecs.NewTag() //组合式空调
CommonFanTag = ecs.NewTag()
FcBypassFanTag = ecs.NewTag()
SoftStartFanTag = ecs.NewTag()
HighLowSpeedFanTag = ecs.NewTag()
) )

View File

@ -0,0 +1,11 @@
package component
import "joylink.club/ecs"
// GasEnvironment 气体环境
type GasEnvironment struct {
}
var (
GasEnvironmentType = ecs.NewComponentType[GasEnvironment]() //气体环境
)

View File

@ -0,0 +1,11 @@
package component
import "joylink.club/ecs"
// GasMixingChamber 混合室静压箱
type GasMixingChamber struct {
}
var (
GasMixingChamberType = ecs.NewComponentType[GasMixingChamber]()
)

View File

@ -14,5 +14,5 @@ type PurificationDevice struct {
const PurificationDeviceStartTime int = 3000 //净化装置启动耗时ms const PurificationDeviceStartTime int = 3000 //净化装置启动耗时ms
var ( var (
PurificationDeviceType = ecs.NewComponentType[PurificationDevice]() PurificationDeviceType = ecs.NewComponentType[PurificationDevice]() //净化装置
) )

View File

@ -4,35 +4,18 @@ import (
"joylink.club/ecs" "joylink.club/ecs"
) )
// 阀门开关 // Valve 阀门开关(电动调节阀、电动风阀、组合式风阀、电动蝶阀)
type Valve struct {
// ElectricControlValve 电动调节阀 Opened bool //true-开到位(全开)
// 具体异常 Closed bool //true-关到位(全关)
//
// 电动风阀、电动调节阀、组合式风阀、电动两通调节阀、电动蝶阀
type ElectricControlValve struct {
Opened bool //true-开到位
Closed bool //true-关到位
Moving bool //true-正在动作 Moving bool //true-正在动作
OpenRate uint8 //开度
}
// ElectricControlValveOperationTime 电动调节阀动作耗时ms
const ElectricControlValveOperationTime int = 4000
// ControlValve 调节阀(手动)
type ControlValve struct {
OpenRate uint8 //开度0-100% OpenRate uint8 //开度0-100%
} }
var ( var (
ElectricControlValveType = ecs.NewComponentType[ElectricControlValve]() ValveType = ecs.NewComponentType[Valve]() //阀门(开关)
ElectricControlValveTag = ecs.NewTag() //电动调节阀
ElectricAirValveTag = ecs.NewTag() //电动风阀标签 ElectricAirValveTag = ecs.NewTag() //电动风阀标签
CombinationAirValveTag = ecs.NewTag() //组合式风阀 CombinationAirValveTag = ecs.NewTag() //组合式风阀
ElectricTwoWayValveTag = ecs.NewTag() //电动两通调节阀 ElectricButterflyValveTag = ecs.NewTag() //电动蝶阀
ElectricButterflyValveTag = ecs.NewTag() //电动蝶阀
ControlValveType = ecs.NewComponentType[ControlValve]()
BypassValveSwitchTag = ecs.NewTag() //旁通阀开关(ControlValve)
) )

View File

@ -3,338 +3,15 @@ package entity
import ( import (
"joylink.club/ecs" "joylink.club/ecs"
"joylink.club/rtsssimulation/component" "joylink.club/rtsssimulation/component"
"joylink.club/rtsssimulation/repository/model/proto"
) )
// NewIscsFanEntity 创建风机实体 // NewWireCabinetEntity 创建线柜实体
func NewIscsFanEntity(w ecs.World, id string) *ecs.Entry { func NewWireCabinetEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w) wd := GetWorldData(w)
e, ok := wd.EntityMap[id] e, ok := wd.EntityMap[id]
if !ok { if !ok {
e := w.Entry(w.Create(component.UidType, component.FanType, component.FanStateType)) e := w.Entry(w.Create(component.UidType, component.WireCabinetType, component.DeviceExceptionType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewIscsTwoSpeedFanEntity 创建双速风机实体
func NewIscsTwoSpeedFanEntity(w ecs.World, id string) *ecs.Entry {
entry := NewIscsFanEntity(w, id)
entry.AddComponent(component.TwoSpeedFanTag)
return entry
}
// NewAirConditionerEntity 创建空调实体/空调器实体
//
// fc-true变频空调
func NewAirConditionerEntity(w ecs.World, id string, fc bool) *ecs.Entry {
entry := NewIscsFanEntity(w, id)
entry.HasComponent(component.AirConditionerTag)
component.FanType.Get(entry).Fc = fc
return entry
}
// NewCombinedAirConditionerEntity 组合式空调(变频空调)
func NewCombinedAirConditionerEntity(w ecs.World, id string) *ecs.Entry {
entry := NewAirConditionerEntity(w, id, true)
entry.AddComponent(component.CombinedAirConditionerTag)
return entry
}
// NewElectricControlValveEntity 创建电动调节阀实体
func NewElectricControlValveEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.ElectricControlValveType, component.TwoPositionTransformType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewElectricAirValveEntity 创建电动风阀实体
func NewElectricAirValveEntity(w ecs.World, id string) *ecs.Entry {
entry := NewElectricControlValveEntity(w, id)
entry.AddComponent(component.ElectricAirValveTag)
return entry
}
// NewCombinationAirValveEntity 创建组合式风阀
func NewCombinationAirValveEntity(w ecs.World, id string) *ecs.Entry {
entry := NewElectricControlValveEntity(w, id)
entry.AddComponent(component.CombinationAirValveTag)
return entry
}
// NewElectricTwoWayValveEntity 创建电动两通调节阀实体
func NewElectricTwoWayValveEntity(w ecs.World, id string) *ecs.Entry {
entry := NewElectricControlValveEntity(w, id)
entry.AddComponent(component.ElectricTwoWayValveTag)
return entry
}
// NewElectricButterflyValveEntity 创建电动蝶阀实体
func NewElectricButterflyValveEntity(w ecs.World, id string) *ecs.Entry {
entry := NewElectricControlValveEntity(w, id)
entry.AddComponent(component.ElectricButterflyValveTag)
return entry
}
// NewPurificationDeviceEntity 创建净化装置实体
func NewPurificationDeviceEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.PurificationDeviceType, component.CounterType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewElevatorDeviceEntity 创建垂直电梯实体
func NewElevatorDeviceEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.ElevatorType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewEscalatorDeviceEntity 创建自动扶梯实体
func NewEscalatorDeviceEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.EscalatorType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewChillerUnitEntity 创建冷水机组实体
func NewChillerUnitEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.ChillerUnitType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewWaterPumpEntity 创建水泵实体
func NewWaterPumpEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.WaterPumpType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewFloatBallWaterPumpEntity 创建浮球型水泵
func NewFloatBallWaterPumpEntity(w ecs.World, id string) *ecs.Entry {
entry := NewWaterPumpEntity(w, id)
entry.AddComponent(component.FloatBallSwitchType)
return entry
}
// NewWaterTankEntity 创建水池或水箱实体
func NewWaterTankEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.WaterTankType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewWaterClosedContainerEntity 创建封闭式水容器,如冷却塔、水处理器
func NewWaterClosedContainerEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.WaterClosedContainerType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewCoolingTowerEntity 创建冷却塔实体
func NewCoolingTowerEntity(w ecs.World, id string) *ecs.Entry {
entry := NewWaterClosedContainerEntity(w, id)
entry.AddComponent(component.CoolingTowerTag)
return entry
}
// NewWaterProcessorEntity 创建水处理器实体
func NewWaterProcessorEntity(w ecs.World, id string) *ecs.Entry {
entry := NewWaterClosedContainerEntity(w, id)
entry.AddComponent(component.WaterProcessorTag)
return entry
}
// NewBypassValveSwitchEntity 创建旁通阀开关实体
func NewBypassValveSwitchEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.ControlValveType, component.BypassValveSwitchTag))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewSensorEntity 创建传感器实体
func NewSensorEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.SensorType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewThSensorEntity 创建温湿度传感器实体
func NewThSensorEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.ThSensorType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewCO2SensorEntity CO2 传感器
func NewCO2SensorEntity(w ecs.World, id string) *ecs.Entry {
entry := NewSensorEntity(w, id)
entry.AddComponent(component.CO2SensorTag)
return entry
}
// NewWaterTSensorEntity 水温传感器
func NewWaterTSensorEntity(w ecs.World, id string) *ecs.Entry {
entry := NewSensorEntity(w, id)
entry.AddComponent(component.WaterTSensorTag)
return entry
}
// NewPressureSensorEntity 压力传感器
func NewPressureSensorEntity(w ecs.World, id string) *ecs.Entry {
entry := NewSensorEntity(w, id)
entry.AddComponent(component.PressureSensorTag)
return entry
}
// NewFlowSensorEntity 流量传感器
func NewFlowSensorEntity(w ecs.World, id string) *ecs.Entry {
entry := NewSensorEntity(w, id)
entry.AddComponent(component.FlowSensorTag)
return entry
}
// NewTemperatureSensorEntity 温度传感器
func NewTemperatureSensorEntity(w ecs.World, id string) *ecs.Entry {
entry := NewSensorEntity(w, id)
entry.AddComponent(component.TemperatureSensorTag)
return entry
}
// NewLightingGuidanceEntity 创建照明导向实体
func NewLightingGuidanceEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.LightingGuidanceType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewPowerSwitchGuidanceEntity 创建电源开关导向实体
func NewPowerSwitchGuidanceEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.PowerSwitchGuidanceType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewEscalatorGuidanceEntity 创建扶梯导向实体
func NewEscalatorGuidanceEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.EscalatorGuidanceType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewTicketGateGuidanceEntity 创建闸机导向实体
func NewTicketGateGuidanceEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.TicketGateGuidanceType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewSectionEvacuationGuidanceEntity 创建区间疏散导向实体
func NewSectionEvacuationGuidanceEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.SectionEvacuationGuidanceType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewCivilDefenseDoorEntity 创建人防门实体
func NewCivilDefenseDoorEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.CivilDefenseDoorType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewPlcControllerEntity 创建PLC控制器实体
func NewPlcControllerEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.PlcControllerType))
component.UidType.SetValue(e, component.Uid{Id: id}) component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e wd.EntityMap[id] = e
} }
@ -354,12 +31,85 @@ func NewNetworkSwitchEntity(w ecs.World, id string) *ecs.Entry {
return e return e
} }
// NewEmergencyLightingEntity 创建应急照明实体 // NewAirPavilionEntity 创建风亭实体
func NewEmergencyLightingEntity(w ecs.World, id string) *ecs.Entry { func NewAirPavilionEntity(w ecs.World, id string, apType proto.AirPavilion_Type) *ecs.Entry {
wd := GetWorldData(w) wd := GetWorldData(w)
e, ok := wd.EntityMap[id] e, ok := wd.EntityMap[id]
if !ok { if !ok {
e := w.Entry(w.Create(component.UidType, component.EmergencyLightingType)) e := w.Entry(w.Create(component.UidType, component.AirPavilionType))
//
switch apType {
case proto.AirPavilion_ExhaustPavilion:
e.AddComponent(component.ExhaustPavilionTag)
case proto.AirPavilion_AirSupplyPavilion:
e.AddComponent(component.AirSupplyPavilionTag)
}
//
component.UidType.SetValue(e, component.Uid{Id: id})
component.AirPavilionType.Set(e, &component.AirPavilion{Normal: true})
wd.EntityMap[id] = e
}
return e
}
// NewValveEntity 创建阀门实体
func NewValveEntity(w ecs.World, id string, valveType proto.Valve_Type) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.ValveType, component.DeviceExceptionType))
component.UidType.SetValue(e, component.Uid{Id: id})
component.ValveType.Set(e, &component.Valve{OpenRate: 100, Closed: false, Opened: true, Moving: false})
//
switch valveType {
case proto.Valve_ElectricControlValve:
e.AddComponent(component.ElectricControlValveTag)
case proto.Valve_ElectricAirValve:
e.AddComponent(component.ElectricAirValveTag)
case proto.Valve_CombinationAirValve:
e.AddComponent(component.CombinationAirValveTag)
case proto.Valve_ElectricButterflyValve:
e.AddComponent(component.ElectricButterflyValveTag)
}
//
wd.EntityMap[id] = e
}
return e
}
// NewGasMixingChamberEntity 创建混合室静压箱实体
func NewGasMixingChamberEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.GasMixingChamberType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewCombinationAirConditionerEntity 创建组合式空调实体
func NewCombinationAirConditionerEntity(w ecs.World, id string) *ecs.Entry {
return newAirConditioningEntity(w, id, component.CombinationAirConditionerTag)
}
func newAirConditioningEntity(w ecs.World, id string, tag *ecs.ComponentType[struct{}]) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.AirConditioningType, component.DeviceExceptionType, tag))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewPurificationDeviceEntity 创建净化装置实体
func NewPurificationDeviceEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.PurificationDeviceType, component.DeviceExceptionType))
component.UidType.SetValue(e, component.Uid{Id: id}) component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e wd.EntityMap[id] = e
} }
@ -371,9 +121,57 @@ func NewAirCurtainEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w) wd := GetWorldData(w)
e, ok := wd.EntityMap[id] e, ok := wd.EntityMap[id]
if !ok { if !ok {
e := w.Entry(w.Create(component.UidType, component.AirCurtainType)) e := w.Entry(w.Create(component.UidType, component.AirCurtainType, component.DeviceExceptionType))
component.UidType.SetValue(e, component.Uid{Id: id}) component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e wd.EntityMap[id] = e
} }
return e return e
} }
// NewGasEnvironmentEntity 创建气体环境实体
func NewGasEnvironmentEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.GasEnvironmentType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewFanEntity 创建风机实体
func NewFanEntity(w ecs.World, id string, fanType proto.Fan_Type) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.FanDeviceType, component.DeviceExceptionType))
component.UidType.SetValue(e, component.Uid{Id: id})
//
switch fanType {
case proto.Fan_CommonFan:
{
e.AddComponent(component.CommonFanTag)
}
case proto.Fan_FcBypassFan:
{
e.AddComponent(component.FanFcUnitType)
e.AddComponent(component.FanBypassUnitType)
e.AddComponent(component.FcBypassFanTag)
}
case proto.Fan_SoftStartFan:
{
e.AddComponent(component.FanSoftStartUnitType)
e.AddComponent(component.SoftStartFanTag)
}
case proto.Fan_HighLowSpeedFan:
{
e.AddComponent(component.FanHighLowSpeedModeType)
e.AddComponent(component.HighLowSpeedFanTag)
}
}
//
wd.EntityMap[id] = e
}
return e
}

View File

@ -59,6 +59,38 @@ func LoadIscs(w ecs.World) error {
for _, wc := range data.Repo.WireCabinetMap { for _, wc := range data.Repo.WireCabinetMap {
NewWireCabinetEntity(w, wc.Id()) NewWireCabinetEntity(w, wc.Id())
} }
//风亭(排风亭、送风亭)
for _, ap := range data.Repo.AirPavilionMap {
NewAirPavilionEntity(w, ap.Id(), ap.PavilionType)
}
//阀门
for _, valve := range data.Repo.ValveMap {
NewValveEntity(w, valve.Id(), valve.ValveType)
}
//混合室静压箱
for _, gmc := range data.Repo.GasMixingChamberMap {
NewGasMixingChamberEntity(w, gmc.Id())
}
//组合式空调
for _, cac := range data.Repo.CombinationAirConditionerMap {
NewCombinationAirConditionerEntity(w, cac.Id())
}
//净化装置
for _, apd := range data.Repo.AirPurificationDeviceMap {
NewPurificationDeviceEntity(w, apd.Id())
}
//空气幕
for _, ac := range data.Repo.AirCurtainMap {
NewAirCurtainEntity(w, ac.Id())
}
//气体环境
for _, gasEnv := range data.Repo.GasEnvironmentMap {
NewGasEnvironmentEntity(w, gasEnv.Id())
}
//风机
for _, fan := range data.Repo.FanMap {
NewFanEntity(w, fan.Id(), fan.FanType)
}
// //
return nil return nil
} }

View File

@ -69,18 +69,6 @@ func NewDisconnectorEntity(w ecs.World, id string) *ecs.Entry {
return e return e
} }
// NewWireCabinetEntity 创建线柜实体
func NewWireCabinetEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w)
e, ok := wd.EntityMap[id]
if !ok {
e := w.Entry(w.Create(component.UidType, component.WireCabinetType, component.DeviceExceptionType))
component.UidType.SetValue(e, component.Uid{Id: id})
wd.EntityMap[id] = e
}
return e
}
// NewLightningArresterEntity 创建避雷器实体 // NewLightningArresterEntity 创建避雷器实体
func NewLightningArresterEntity(w ecs.World, id string) *ecs.Entry { func NewLightningArresterEntity(w ecs.World, id string) *ecs.Entry {
wd := GetWorldData(w) wd := GetWorldData(w)

View File

@ -665,6 +665,7 @@ message WireCabinet{
message AirPavilion{ message AirPavilion{
string id = 1; string id = 1;
string code = 2; string code = 2;
//
enum Type{ enum Type{
ExhaustPavilion = 0;// ExhaustPavilion = 0;//
AirSupplyPavilion = 1;// AirSupplyPavilion = 1;//
@ -676,9 +677,12 @@ message AirPavilion{
message Valve{ message Valve{
string id = 1; string id = 1;
string code = 2; string code = 2;
//
enum Type{ enum Type{
ElectricControlValve = 0;// ElectricControlValve = 0;//
ElectricAirValve = 1;// ElectricAirValve = 1;//
CombinationAirValve = 2;//
ElectricButterflyValve = 3;//
} }
Type valveType = 3;// Type valveType = 3;//
} }
@ -716,6 +720,14 @@ message AirCurtain{
message Fan{ message Fan{
string id = 1; string id = 1;
string code = 2; string code = 2;
//
enum Type{
CommonFan = 0;//(线)
FcBypassFan = 1;//()
SoftStartFan = 2;//()
HighLowSpeedFan = 3;//
}
Type fanType = 3;//
} }
//(+) //(+)

View File

@ -208,15 +208,17 @@ func NewAirCurtain(id string, code string) *AirCurtain {
// Fan 风机 // Fan 风机
type Fan struct { type Fan struct {
Identity Identity
Code string Code string
PortA DevicePort //A端口连接的设备 FanType proto.Fan_Type
PortB DevicePort //B端口连接的设备 PortA DevicePort //A端口连接的设备
PortB DevicePort //B端口连接的设备
} }
func NewFan(id string, code string) *Fan { func NewFan(id string, code string, fanType proto.Fan_Type) *Fan {
return &Fan{ return &Fan{
Identity: &identity{id: id, deviceType: proto.DeviceType_DeviceType_Fan}, Identity: &identity{id: id, deviceType: proto.DeviceType_DeviceType_Fan},
Code: code, Code: code,
FanType: fanType,
} }
} }
func (p *Fan) PortNum() int { func (p *Fan) PortNum() int {

View File

@ -962,6 +962,7 @@ func (Pipe_Type) EnumDescriptor() ([]byte, []int) {
return file_model_proto_rawDescGZIP(), []int{32, 0} return file_model_proto_rawDescGZIP(), []int{32, 0}
} }
// 风亭子类型
type AirPavilion_Type int32 type AirPavilion_Type int32
const ( const (
@ -1008,11 +1009,14 @@ func (AirPavilion_Type) EnumDescriptor() ([]byte, []int) {
return file_model_proto_rawDescGZIP(), []int{45, 0} return file_model_proto_rawDescGZIP(), []int{45, 0}
} }
// 阀门子类型
type Valve_Type int32 type Valve_Type int32
const ( const (
Valve_ElectricControlValve Valve_Type = 0 //电动调节阀 Valve_ElectricControlValve Valve_Type = 0 //电动调节阀
Valve_ElectricAirValve Valve_Type = 1 //电动风阀 Valve_ElectricAirValve Valve_Type = 1 //电动风阀
Valve_CombinationAirValve Valve_Type = 2 //组合式风阀
Valve_ElectricButterflyValve Valve_Type = 3 //电动蝶阀
) )
// Enum value maps for Valve_Type. // Enum value maps for Valve_Type.
@ -1020,10 +1024,14 @@ var (
Valve_Type_name = map[int32]string{ Valve_Type_name = map[int32]string{
0: "ElectricControlValve", 0: "ElectricControlValve",
1: "ElectricAirValve", 1: "ElectricAirValve",
2: "CombinationAirValve",
3: "ElectricButterflyValve",
} }
Valve_Type_value = map[string]int32{ Valve_Type_value = map[string]int32{
"ElectricControlValve": 0, "ElectricControlValve": 0,
"ElectricAirValve": 1, "ElectricAirValve": 1,
"CombinationAirValve": 2,
"ElectricButterflyValve": 3,
} }
) )
@ -1054,6 +1062,59 @@ func (Valve_Type) EnumDescriptor() ([]byte, []int) {
return file_model_proto_rawDescGZIP(), []int{46, 0} return file_model_proto_rawDescGZIP(), []int{46, 0}
} }
// 风机子类型
type Fan_Type int32
const (
Fan_CommonFan Fan_Type = 0 //一般风机(普通风机、硬线风机、射流风机、排烟风机、正压送风机)
Fan_FcBypassFan Fan_Type = 1 //变频旁路风机(回排风机)
Fan_SoftStartFan Fan_Type = 2 //软启风机(软启风机、隧道风机)
Fan_HighLowSpeedFan Fan_Type = 3 //双速风机
)
// Enum value maps for Fan_Type.
var (
Fan_Type_name = map[int32]string{
0: "CommonFan",
1: "FcBypassFan",
2: "SoftStartFan",
3: "HighLowSpeedFan",
}
Fan_Type_value = map[string]int32{
"CommonFan": 0,
"FcBypassFan": 1,
"SoftStartFan": 2,
"HighLowSpeedFan": 3,
}
)
func (x Fan_Type) Enum() *Fan_Type {
p := new(Fan_Type)
*p = x
return p
}
func (x Fan_Type) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (Fan_Type) Descriptor() protoreflect.EnumDescriptor {
return file_model_proto_enumTypes[13].Descriptor()
}
func (Fan_Type) Type() protoreflect.EnumType {
return &file_model_proto_enumTypes[13]
}
func (x Fan_Type) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Use Fan_Type.Descriptor instead.
func (Fan_Type) EnumDescriptor() ([]byte, []int) {
return file_model_proto_rawDescGZIP(), []int{51, 0}
}
type Repository struct { type Repository struct {
state protoimpl.MessageState state protoimpl.MessageState
sizeCache protoimpl.SizeCache sizeCache protoimpl.SizeCache
@ -4809,8 +4870,9 @@ type Fan struct {
sizeCache protoimpl.SizeCache sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields unknownFields protoimpl.UnknownFields
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
Code string `protobuf:"bytes,2,opt,name=code,proto3" json:"code,omitempty"` Code string `protobuf:"bytes,2,opt,name=code,proto3" json:"code,omitempty"`
FanType Fan_Type `protobuf:"varint,3,opt,name=fanType,proto3,enum=model.Fan_Type" json:"fanType,omitempty"` //风机子类型
} }
func (x *Fan) Reset() { func (x *Fan) Reset() {
@ -4859,6 +4921,13 @@ func (x *Fan) GetCode() string {
return "" return ""
} }
func (x *Fan) GetFanType() Fan_Type {
if x != nil {
return x.FanType
}
return Fan_CommonFan
}
// 气体环境(正常空气+有害烟雾) // 气体环境(正常空气+有害烟雾)
// 有多个输入口统一为端口A用来为环境补充新鲜空气 // 有多个输入口统一为端口A用来为环境补充新鲜空气
// 有多个输出口统一为端口B用户将环境的混浊气体排除 // 有多个输出口统一为端口B用户将环境的混浊气体排除
@ -5463,34 +5532,45 @@ var file_model_proto_rawDesc = []byte{
0x69, 0x6c, 0x69, 0x6f, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x22, 0x32, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x69, 0x6c, 0x69, 0x6f, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x22, 0x32, 0x0a, 0x04, 0x54, 0x79, 0x70,
0x65, 0x12, 0x13, 0x0a, 0x0f, 0x45, 0x78, 0x68, 0x61, 0x75, 0x73, 0x74, 0x50, 0x61, 0x76, 0x69, 0x65, 0x12, 0x13, 0x0a, 0x0f, 0x45, 0x78, 0x68, 0x61, 0x75, 0x73, 0x74, 0x50, 0x61, 0x76, 0x69,
0x6c, 0x69, 0x6f, 0x6e, 0x10, 0x00, 0x12, 0x15, 0x0a, 0x11, 0x41, 0x69, 0x72, 0x53, 0x75, 0x70, 0x6c, 0x69, 0x6f, 0x6e, 0x10, 0x00, 0x12, 0x15, 0x0a, 0x11, 0x41, 0x69, 0x72, 0x53, 0x75, 0x70,
0x70, 0x6c, 0x79, 0x50, 0x61, 0x76, 0x69, 0x6c, 0x69, 0x6f, 0x6e, 0x10, 0x01, 0x22, 0x94, 0x01, 0x70, 0x6c, 0x79, 0x50, 0x61, 0x76, 0x69, 0x6c, 0x69, 0x6f, 0x6e, 0x10, 0x01, 0x22, 0xc9, 0x01,
0x0a, 0x05, 0x56, 0x61, 0x6c, 0x76, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x0a, 0x05, 0x56, 0x61, 0x6c, 0x76, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20,
0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18,
0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x2f, 0x0a, 0x09, 0x76, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x2f, 0x0a, 0x09, 0x76,
0x61, 0x6c, 0x76, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x11, 0x61, 0x6c, 0x76, 0x65, 0x54, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x11,
0x2e, 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x2e, 0x56, 0x61, 0x6c, 0x76, 0x65, 0x2e, 0x54, 0x79, 0x70, 0x2e, 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x2e, 0x56, 0x61, 0x6c, 0x76, 0x65, 0x2e, 0x54, 0x79, 0x70,
0x65, 0x52, 0x09, 0x76, 0x61, 0x6c, 0x76, 0x65, 0x54, 0x79, 0x70, 0x65, 0x22, 0x36, 0x0a, 0x04, 0x65, 0x52, 0x09, 0x76, 0x61, 0x6c, 0x76, 0x65, 0x54, 0x79, 0x70, 0x65, 0x22, 0x6b, 0x0a, 0x04,
0x54, 0x79, 0x70, 0x65, 0x12, 0x18, 0x0a, 0x14, 0x45, 0x6c, 0x65, 0x63, 0x74, 0x72, 0x69, 0x63, 0x54, 0x79, 0x70, 0x65, 0x12, 0x18, 0x0a, 0x14, 0x45, 0x6c, 0x65, 0x63, 0x74, 0x72, 0x69, 0x63,
0x43, 0x6f, 0x6e, 0x74, 0x72, 0x6f, 0x6c, 0x56, 0x61, 0x6c, 0x76, 0x65, 0x10, 0x00, 0x12, 0x14, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x6f, 0x6c, 0x56, 0x61, 0x6c, 0x76, 0x65, 0x10, 0x00, 0x12, 0x14,
0x0a, 0x10, 0x45, 0x6c, 0x65, 0x63, 0x74, 0x72, 0x69, 0x63, 0x41, 0x69, 0x72, 0x56, 0x61, 0x6c, 0x0a, 0x10, 0x45, 0x6c, 0x65, 0x63, 0x74, 0x72, 0x69, 0x63, 0x41, 0x69, 0x72, 0x56, 0x61, 0x6c,
0x76, 0x65, 0x10, 0x01, 0x22, 0x36, 0x0a, 0x10, 0x47, 0x61, 0x73, 0x4d, 0x69, 0x78, 0x69, 0x6e, 0x76, 0x65, 0x10, 0x01, 0x12, 0x17, 0x0a, 0x13, 0x43, 0x6f, 0x6d, 0x62, 0x69, 0x6e, 0x61, 0x74,
0x67, 0x43, 0x68, 0x61, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x69, 0x6f, 0x6e, 0x41, 0x69, 0x72, 0x56, 0x61, 0x6c, 0x76, 0x65, 0x10, 0x02, 0x12, 0x1a, 0x0a,
0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x16, 0x45, 0x6c, 0x65, 0x63, 0x74, 0x72, 0x69, 0x63, 0x42, 0x75, 0x74, 0x74, 0x65, 0x72, 0x66,
0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x22, 0x3f, 0x0a, 0x19, 0x6c, 0x79, 0x56, 0x61, 0x6c, 0x76, 0x65, 0x10, 0x03, 0x22, 0x36, 0x0a, 0x10, 0x47, 0x61, 0x73,
0x43, 0x6f, 0x6d, 0x62, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x41, 0x69, 0x72, 0x43, 0x6f, 0x4d, 0x69, 0x78, 0x69, 0x6e, 0x67, 0x43, 0x68, 0x61, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x0e, 0x0a,
0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x65, 0x72, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a,
0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64,
0x65, 0x22, 0x3f, 0x0a, 0x19, 0x43, 0x6f, 0x6d, 0x62, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e,
0x41, 0x69, 0x72, 0x43, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x65, 0x72, 0x12, 0x0e,
0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12,
0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f,
0x64, 0x65, 0x22, 0x3b, 0x0a, 0x15, 0x41, 0x69, 0x72, 0x50, 0x75, 0x72, 0x69, 0x66, 0x69, 0x63,
0x61, 0x74, 0x69, 0x6f, 0x6e, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69,
0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x63,
0x6f, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x22,
0x30, 0x0a, 0x0a, 0x41, 0x69, 0x72, 0x43, 0x75, 0x72, 0x74, 0x61, 0x69, 0x6e, 0x12, 0x0e, 0x0a,
0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a,
0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64,
0x65, 0x22, 0xa3, 0x01, 0x0a, 0x03, 0x46, 0x61, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18,
0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64,
0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x22, 0x3b, 0x0a, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x29, 0x0a,
0x15, 0x41, 0x69, 0x72, 0x50, 0x75, 0x72, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x07, 0x66, 0x61, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x0f,
0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x2e, 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x2e, 0x46, 0x61, 0x6e, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52,
0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x02, 0x07, 0x66, 0x61, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x22, 0x4d, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65,
0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x22, 0x30, 0x0a, 0x0a, 0x41, 0x69, 0x12, 0x0d, 0x0a, 0x09, 0x43, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x46, 0x61, 0x6e, 0x10, 0x00, 0x12,
0x72, 0x43, 0x75, 0x72, 0x74, 0x61, 0x69, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x0f, 0x0a, 0x0b, 0x46, 0x63, 0x42, 0x79, 0x70, 0x61, 0x73, 0x73, 0x46, 0x61, 0x6e, 0x10, 0x01,
0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x10, 0x0a, 0x0c, 0x53, 0x6f, 0x66, 0x74, 0x53, 0x74, 0x61, 0x72, 0x74, 0x46, 0x61, 0x6e,
0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x22, 0x29, 0x0a, 0x03, 0x10, 0x02, 0x12, 0x13, 0x0a, 0x0f, 0x48, 0x69, 0x67, 0x68, 0x4c, 0x6f, 0x77, 0x53, 0x70, 0x65,
0x46, 0x61, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x65, 0x64, 0x46, 0x61, 0x6e, 0x10, 0x03, 0x22, 0x34, 0x0a, 0x0e, 0x47, 0x61, 0x73, 0x45, 0x6e,
0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28,
0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x22, 0x34, 0x0a, 0x0e, 0x47, 0x61, 0x73, 0x45, 0x6e,
0x76, 0x69, 0x72, 0x6f, 0x6e, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x76, 0x69, 0x72, 0x6f, 0x6e, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18,
0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64,
0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x2a, 0xee, 0x15, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x2a, 0xee, 0x15,
@ -5695,7 +5775,7 @@ func file_model_proto_rawDescGZIP() []byte {
return file_model_proto_rawDescData return file_model_proto_rawDescData
} }
var file_model_proto_enumTypes = make([]protoimpl.EnumInfo, 13) var file_model_proto_enumTypes = make([]protoimpl.EnumInfo, 14)
var file_model_proto_msgTypes = make([]protoimpl.MessageInfo, 53) var file_model_proto_msgTypes = make([]protoimpl.MessageInfo, 53)
var file_model_proto_goTypes = []interface{}{ var file_model_proto_goTypes = []interface{}{
(DeviceType)(0), // 0: model.DeviceType (DeviceType)(0), // 0: model.DeviceType
@ -5711,159 +5791,161 @@ var file_model_proto_goTypes = []interface{}{
(Pipe_Type)(0), // 10: model.Pipe.Type (Pipe_Type)(0), // 10: model.Pipe.Type
(AirPavilion_Type)(0), // 11: model.AirPavilion.Type (AirPavilion_Type)(0), // 11: model.AirPavilion.Type
(Valve_Type)(0), // 12: model.Valve.Type (Valve_Type)(0), // 12: model.Valve.Type
(*Repository)(nil), // 13: model.Repository (Fan_Type)(0), // 13: model.Fan.Type
(*SignalLayout)(nil), // 14: model.SignalLayout (*Repository)(nil), // 14: model.Repository
(*PhysicalSection)(nil), // 15: model.PhysicalSection (*SignalLayout)(nil), // 15: model.SignalLayout
(*CheckPoint)(nil), // 16: model.CheckPoint (*PhysicalSection)(nil), // 16: model.PhysicalSection
(*Turnout)(nil), // 17: model.Turnout (*CheckPoint)(nil), // 17: model.CheckPoint
(*Signal)(nil), // 18: model.Signal (*Turnout)(nil), // 18: model.Turnout
(*Psd)(nil), // 19: model.Psd (*Signal)(nil), // 19: model.Signal
(*Transponder)(nil), // 20: model.Transponder (*Psd)(nil), // 20: model.Psd
(*Slope)(nil), // 21: model.Slope (*Transponder)(nil), // 21: model.Transponder
(*SectionalCurvature)(nil), // 22: model.SectionalCurvature (*Slope)(nil), // 22: model.Slope
(*DevicePort)(nil), // 23: model.DevicePort (*SectionalCurvature)(nil), // 23: model.SectionalCurvature
(*Kilometer)(nil), // 24: model.Kilometer (*DevicePort)(nil), // 24: model.DevicePort
(*KilometerConvert)(nil), // 25: model.KilometerConvert (*Kilometer)(nil), // 25: model.Kilometer
(*Relay)(nil), // 26: model.Relay (*KilometerConvert)(nil), // 26: model.KilometerConvert
(*PhaseFailureProtector)(nil), // 27: model.PhaseFailureProtector (*Relay)(nil), // 27: model.Relay
(*ElectronicComponentGroup)(nil), // 28: model.ElectronicComponentGroup (*PhaseFailureProtector)(nil), // 28: model.PhaseFailureProtector
(*Button)(nil), // 29: model.Button (*ElectronicComponentGroup)(nil), // 29: model.ElectronicComponentGroup
(*Light)(nil), // 30: model.Light (*Button)(nil), // 30: model.Button
(*Alarm)(nil), // 31: model.Alarm (*Light)(nil), // 31: model.Light
(*Station)(nil), // 32: model.Station (*Alarm)(nil), // 32: model.Alarm
(*DeviceEcc)(nil), // 33: model.DeviceEcc (*Station)(nil), // 33: model.Station
(*ElectronicGroup)(nil), // 34: model.ElectronicGroup (*DeviceEcc)(nil), // 34: model.DeviceEcc
(*ElectronicComponent)(nil), // 35: model.ElectronicComponent (*ElectronicGroup)(nil), // 35: model.ElectronicGroup
(*Mkx)(nil), // 36: model.Mkx (*ElectronicComponent)(nil), // 36: model.ElectronicComponent
(*Platform)(nil), // 37: model.Platform (*Mkx)(nil), // 37: model.Mkx
(*Key)(nil), // 38: model.Key (*Platform)(nil), // 38: model.Platform
(*CentralizedStationRef)(nil), // 39: model.CentralizedStationRef (*Key)(nil), // 39: model.Key
(*CjData)(nil), // 40: model.CjData (*CentralizedStationRef)(nil), // 40: model.CentralizedStationRef
(*CjDataItem)(nil), // 41: model.CjDataItem (*CjData)(nil), // 41: model.CjData
(*QdData)(nil), // 42: model.QdData (*CjDataItem)(nil), // 42: model.CjDataItem
(*AsdGroup)(nil), // 43: model.AsdGroup (*QdData)(nil), // 43: model.QdData
(*CiSectionCodePoint)(nil), // 44: model.CiSectionCodePoint (*AsdGroup)(nil), // 44: model.AsdGroup
(*Pipe)(nil), // 45: model.Pipe (*CiSectionCodePoint)(nil), // 45: model.CiSectionCodePoint
(*PipeFitting)(nil), // 46: model.PipeFitting (*Pipe)(nil), // 46: model.Pipe
(*CircuitBreaker)(nil), // 47: model.CircuitBreaker (*PipeFitting)(nil), // 47: model.PipeFitting
(*ThreePositionSwitch)(nil), // 48: model.ThreePositionSwitch (*CircuitBreaker)(nil), // 48: model.CircuitBreaker
(*HandcartSwitch)(nil), // 49: model.HandcartSwitch (*ThreePositionSwitch)(nil), // 49: model.ThreePositionSwitch
(*Rectifier)(nil), // 50: model.Rectifier (*HandcartSwitch)(nil), // 50: model.HandcartSwitch
(*Disconnector)(nil), // 51: model.Disconnector (*Rectifier)(nil), // 51: model.Rectifier
(*VoltageTransformer)(nil), // 52: model.VoltageTransformer (*Disconnector)(nil), // 52: model.Disconnector
(*PowerSource)(nil), // 53: model.PowerSource (*VoltageTransformer)(nil), // 53: model.VoltageTransformer
(*LightningArrester)(nil), // 54: model.LightningArrester (*PowerSource)(nil), // 54: model.PowerSource
(*EarthingDevice)(nil), // 55: model.EarthingDevice (*LightningArrester)(nil), // 55: model.LightningArrester
(*NetworkSwitch)(nil), // 56: model.NetworkSwitch (*EarthingDevice)(nil), // 56: model.EarthingDevice
(*WireCabinet)(nil), // 57: model.WireCabinet (*NetworkSwitch)(nil), // 57: model.NetworkSwitch
(*AirPavilion)(nil), // 58: model.AirPavilion (*WireCabinet)(nil), // 58: model.WireCabinet
(*Valve)(nil), // 59: model.Valve (*AirPavilion)(nil), // 59: model.AirPavilion
(*GasMixingChamber)(nil), // 60: model.GasMixingChamber (*Valve)(nil), // 60: model.Valve
(*CombinationAirConditioner)(nil), // 61: model.CombinationAirConditioner (*GasMixingChamber)(nil), // 61: model.GasMixingChamber
(*AirPurificationDevice)(nil), // 62: model.AirPurificationDevice (*CombinationAirConditioner)(nil), // 62: model.CombinationAirConditioner
(*AirCurtain)(nil), // 63: model.AirCurtain (*AirPurificationDevice)(nil), // 63: model.AirPurificationDevice
(*Fan)(nil), // 64: model.Fan (*AirCurtain)(nil), // 64: model.AirCurtain
(*GasEnvironment)(nil), // 65: model.GasEnvironment (*Fan)(nil), // 65: model.Fan
(*GasEnvironment)(nil), // 66: model.GasEnvironment
} }
var file_model_proto_depIdxs = []int32{ var file_model_proto_depIdxs = []int32{
15, // 0: model.Repository.physicalSections:type_name -> model.PhysicalSection 16, // 0: model.Repository.physicalSections:type_name -> model.PhysicalSection
16, // 1: model.Repository.checkPoints:type_name -> model.CheckPoint 17, // 1: model.Repository.checkPoints:type_name -> model.CheckPoint
17, // 2: model.Repository.turnouts:type_name -> model.Turnout 18, // 2: model.Repository.turnouts:type_name -> model.Turnout
18, // 3: model.Repository.signals:type_name -> model.Signal 19, // 3: model.Repository.signals:type_name -> model.Signal
20, // 4: model.Repository.transponders:type_name -> model.Transponder 21, // 4: model.Repository.transponders:type_name -> model.Transponder
21, // 5: model.Repository.slopes:type_name -> model.Slope 22, // 5: model.Repository.slopes:type_name -> model.Slope
22, // 6: model.Repository.sectionalCurvatures:type_name -> model.SectionalCurvature 23, // 6: model.Repository.sectionalCurvatures:type_name -> model.SectionalCurvature
25, // 7: model.Repository.kilometerConverts:type_name -> model.KilometerConvert 26, // 7: model.Repository.kilometerConverts:type_name -> model.KilometerConvert
26, // 8: model.Repository.relays:type_name -> model.Relay 27, // 8: model.Repository.relays:type_name -> model.Relay
27, // 9: model.Repository.phaseFailureProtectors:type_name -> model.PhaseFailureProtector 28, // 9: model.Repository.phaseFailureProtectors:type_name -> model.PhaseFailureProtector
29, // 10: model.Repository.buttons:type_name -> model.Button 30, // 10: model.Repository.buttons:type_name -> model.Button
19, // 11: model.Repository.psds:type_name -> model.Psd 20, // 11: model.Repository.psds:type_name -> model.Psd
30, // 12: model.Repository.lights:type_name -> model.Light 31, // 12: model.Repository.lights:type_name -> model.Light
31, // 13: model.Repository.alarms:type_name -> model.Alarm 32, // 13: model.Repository.alarms:type_name -> model.Alarm
32, // 14: model.Repository.stations:type_name -> model.Station 33, // 14: model.Repository.stations:type_name -> model.Station
36, // 15: model.Repository.mkxs:type_name -> model.Mkx 37, // 15: model.Repository.mkxs:type_name -> model.Mkx
37, // 16: model.Repository.platforms:type_name -> model.Platform 38, // 16: model.Repository.platforms:type_name -> model.Platform
38, // 17: model.Repository.Keys:type_name -> model.Key 39, // 17: model.Repository.Keys:type_name -> model.Key
39, // 18: model.Repository.CentralizedStationRefs:type_name -> model.CentralizedStationRef 40, // 18: model.Repository.CentralizedStationRefs:type_name -> model.CentralizedStationRef
45, // 19: model.Repository.pipes:type_name -> model.Pipe 46, // 19: model.Repository.pipes:type_name -> model.Pipe
46, // 20: model.Repository.pipeFittings:type_name -> model.PipeFitting 47, // 20: model.Repository.pipeFittings:type_name -> model.PipeFitting
47, // 21: model.Repository.circuitBreakers:type_name -> model.CircuitBreaker 48, // 21: model.Repository.circuitBreakers:type_name -> model.CircuitBreaker
48, // 22: model.Repository.threePositionSwitches:type_name -> model.ThreePositionSwitch 49, // 22: model.Repository.threePositionSwitches:type_name -> model.ThreePositionSwitch
49, // 23: model.Repository.handcartSwitches:type_name -> model.HandcartSwitch 50, // 23: model.Repository.handcartSwitches:type_name -> model.HandcartSwitch
50, // 24: model.Repository.rectifiers:type_name -> model.Rectifier 51, // 24: model.Repository.rectifiers:type_name -> model.Rectifier
51, // 25: model.Repository.disconnectors:type_name -> model.Disconnector 52, // 25: model.Repository.disconnectors:type_name -> model.Disconnector
52, // 26: model.Repository.voltageTransformers:type_name -> model.VoltageTransformer 53, // 26: model.Repository.voltageTransformers:type_name -> model.VoltageTransformer
53, // 27: model.Repository.powerSources:type_name -> model.PowerSource 54, // 27: model.Repository.powerSources:type_name -> model.PowerSource
54, // 28: model.Repository.lightningArresters:type_name -> model.LightningArrester 55, // 28: model.Repository.lightningArresters:type_name -> model.LightningArrester
55, // 29: model.Repository.earthingDevices:type_name -> model.EarthingDevice 56, // 29: model.Repository.earthingDevices:type_name -> model.EarthingDevice
56, // 30: model.Repository.networkSwitches:type_name -> model.NetworkSwitch 57, // 30: model.Repository.networkSwitches:type_name -> model.NetworkSwitch
57, // 31: model.Repository.wireCabinets:type_name -> model.WireCabinet 58, // 31: model.Repository.wireCabinets:type_name -> model.WireCabinet
58, // 32: model.Repository.airPavilions:type_name -> model.AirPavilion 59, // 32: model.Repository.airPavilions:type_name -> model.AirPavilion
59, // 33: model.Repository.valves:type_name -> model.Valve 60, // 33: model.Repository.valves:type_name -> model.Valve
60, // 34: model.Repository.gasMixingChambers:type_name -> model.GasMixingChamber 61, // 34: model.Repository.gasMixingChambers:type_name -> model.GasMixingChamber
61, // 35: model.Repository.combinationAirConditioners:type_name -> model.CombinationAirConditioner 62, // 35: model.Repository.combinationAirConditioners:type_name -> model.CombinationAirConditioner
62, // 36: model.Repository.airPurificationDevices:type_name -> model.AirPurificationDevice 63, // 36: model.Repository.airPurificationDevices:type_name -> model.AirPurificationDevice
63, // 37: model.Repository.airCurtains:type_name -> model.AirCurtain 64, // 37: model.Repository.airCurtains:type_name -> model.AirCurtain
64, // 38: model.Repository.fans:type_name -> model.Fan 65, // 38: model.Repository.fans:type_name -> model.Fan
65, // 39: model.Repository.gasEnvironments:type_name -> model.GasEnvironment 66, // 39: model.Repository.gasEnvironments:type_name -> model.GasEnvironment
15, // 40: model.SignalLayout.physicalSections:type_name -> model.PhysicalSection 16, // 40: model.SignalLayout.physicalSections:type_name -> model.PhysicalSection
16, // 41: model.SignalLayout.checkPoints:type_name -> model.CheckPoint 17, // 41: model.SignalLayout.checkPoints:type_name -> model.CheckPoint
17, // 42: model.SignalLayout.turnouts:type_name -> model.Turnout 18, // 42: model.SignalLayout.turnouts:type_name -> model.Turnout
18, // 43: model.SignalLayout.signals:type_name -> model.Signal 19, // 43: model.SignalLayout.signals:type_name -> model.Signal
20, // 44: model.SignalLayout.transponders:type_name -> model.Transponder 21, // 44: model.SignalLayout.transponders:type_name -> model.Transponder
21, // 45: model.SignalLayout.slopes:type_name -> model.Slope 22, // 45: model.SignalLayout.slopes:type_name -> model.Slope
22, // 46: model.SignalLayout.sectionalCurvatures:type_name -> model.SectionalCurvature 23, // 46: model.SignalLayout.sectionalCurvatures:type_name -> model.SectionalCurvature
25, // 47: model.SignalLayout.kilometerConverts:type_name -> model.KilometerConvert 26, // 47: model.SignalLayout.kilometerConverts:type_name -> model.KilometerConvert
23, // 48: model.PhysicalSection.aDevicePort:type_name -> model.DevicePort 24, // 48: model.PhysicalSection.aDevicePort:type_name -> model.DevicePort
23, // 49: model.PhysicalSection.bDevicePort:type_name -> model.DevicePort 24, // 49: model.PhysicalSection.bDevicePort:type_name -> model.DevicePort
24, // 50: model.CheckPoint.km:type_name -> model.Kilometer 25, // 50: model.CheckPoint.km:type_name -> model.Kilometer
3, // 51: model.CheckPoint.type:type_name -> model.CheckPointType 3, // 51: model.CheckPoint.type:type_name -> model.CheckPointType
23, // 52: model.CheckPoint.devicePorts:type_name -> model.DevicePort 24, // 52: model.CheckPoint.devicePorts:type_name -> model.DevicePort
24, // 53: model.Turnout.km:type_name -> model.Kilometer 25, // 53: model.Turnout.km:type_name -> model.Kilometer
23, // 54: model.Turnout.aDevicePort:type_name -> model.DevicePort 24, // 54: model.Turnout.aDevicePort:type_name -> model.DevicePort
23, // 55: model.Turnout.bDevicePort:type_name -> model.DevicePort 24, // 55: model.Turnout.bDevicePort:type_name -> model.DevicePort
23, // 56: model.Turnout.cDevicePort:type_name -> model.DevicePort 24, // 56: model.Turnout.cDevicePort:type_name -> model.DevicePort
4, // 57: model.Turnout.switchMachineType:type_name -> model.Turnout.SwitchMachineType 4, // 57: model.Turnout.switchMachineType:type_name -> model.Turnout.SwitchMachineType
28, // 58: model.Turnout.electronicComponentGroups:type_name -> model.ElectronicComponentGroup 29, // 58: model.Turnout.electronicComponentGroups:type_name -> model.ElectronicComponentGroup
24, // 59: model.Signal.km:type_name -> model.Kilometer 25, // 59: model.Signal.km:type_name -> model.Kilometer
23, // 60: model.Signal.turnoutPort:type_name -> model.DevicePort 24, // 60: model.Signal.turnoutPort:type_name -> model.DevicePort
28, // 61: model.Signal.electronicComponentGroups:type_name -> model.ElectronicComponentGroup 29, // 61: model.Signal.electronicComponentGroups:type_name -> model.ElectronicComponentGroup
5, // 62: model.Signal.model:type_name -> model.Signal.Model 5, // 62: model.Signal.model:type_name -> model.Signal.Model
43, // 63: model.Psd.asdGroups:type_name -> model.AsdGroup 44, // 63: model.Psd.asdGroups:type_name -> model.AsdGroup
28, // 64: model.Psd.electronicComponentGroups:type_name -> model.ElectronicComponentGroup 29, // 64: model.Psd.electronicComponentGroups:type_name -> model.ElectronicComponentGroup
24, // 65: model.Transponder.km:type_name -> model.Kilometer 25, // 65: model.Transponder.km:type_name -> model.Kilometer
23, // 66: model.Transponder.turnoutPort:type_name -> model.DevicePort 24, // 66: model.Transponder.turnoutPort:type_name -> model.DevicePort
6, // 67: model.Transponder.type:type_name -> model.Transponder.Type 6, // 67: model.Transponder.type:type_name -> model.Transponder.Type
24, // 68: model.Slope.kms:type_name -> model.Kilometer 25, // 68: model.Slope.kms:type_name -> model.Kilometer
24, // 69: model.SectionalCurvature.kms:type_name -> model.Kilometer 25, // 69: model.SectionalCurvature.kms:type_name -> model.Kilometer
0, // 70: model.DevicePort.deviceType:type_name -> model.DeviceType 0, // 70: model.DevicePort.deviceType:type_name -> model.DeviceType
1, // 71: model.DevicePort.port:type_name -> model.Port 1, // 71: model.DevicePort.port:type_name -> model.Port
2, // 72: model.Kilometer.direction:type_name -> model.Direction 2, // 72: model.Kilometer.direction:type_name -> model.Direction
24, // 73: model.KilometerConvert.kmA:type_name -> model.Kilometer 25, // 73: model.KilometerConvert.kmA:type_name -> model.Kilometer
24, // 74: model.KilometerConvert.kmB:type_name -> model.Kilometer 25, // 74: model.KilometerConvert.kmB:type_name -> model.Kilometer
7, // 75: model.Relay.model:type_name -> model.Relay.Model 7, // 75: model.Relay.model:type_name -> model.Relay.Model
8, // 76: model.Button.buttonType:type_name -> model.Button.ButtonType 8, // 76: model.Button.buttonType:type_name -> model.Button.ButtonType
9, // 77: model.Light.aspect:type_name -> model.Light.LightAspect 9, // 77: model.Light.aspect:type_name -> model.Light.LightAspect
34, // 78: model.Station.electronicGroup:type_name -> model.ElectronicGroup 35, // 78: model.Station.electronicGroup:type_name -> model.ElectronicGroup
33, // 79: model.Station.deccs:type_name -> model.DeviceEcc 34, // 79: model.Station.deccs:type_name -> model.DeviceEcc
0, // 80: model.DeviceEcc.deviceType:type_name -> model.DeviceType 0, // 80: model.DeviceEcc.deviceType:type_name -> model.DeviceType
28, // 81: model.DeviceEcc.egs:type_name -> model.ElectronicComponentGroup 29, // 81: model.DeviceEcc.egs:type_name -> model.ElectronicComponentGroup
35, // 82: model.ElectronicGroup.components:type_name -> model.ElectronicComponent 36, // 82: model.ElectronicGroup.components:type_name -> model.ElectronicComponent
0, // 83: model.ElectronicComponent.deviceType:type_name -> model.DeviceType 0, // 83: model.ElectronicComponent.deviceType:type_name -> model.DeviceType
40, // 84: model.CentralizedStationRef.cjList:type_name -> model.CjData 41, // 84: model.CentralizedStationRef.cjList:type_name -> model.CjData
42, // 85: model.CentralizedStationRef.qdList:type_name -> model.QdData 43, // 85: model.CentralizedStationRef.qdList:type_name -> model.QdData
44, // 86: model.CentralizedStationRef.sectionCodePoints:type_name -> model.CiSectionCodePoint 45, // 86: model.CentralizedStationRef.sectionCodePoints:type_name -> model.CiSectionCodePoint
41, // 87: model.CjData.refRelays:type_name -> model.CjDataItem 42, // 87: model.CjData.refRelays:type_name -> model.CjDataItem
23, // 88: model.Pipe.portA:type_name -> model.DevicePort 24, // 88: model.Pipe.portA:type_name -> model.DevicePort
23, // 89: model.Pipe.portB:type_name -> model.DevicePort 24, // 89: model.Pipe.portB:type_name -> model.DevicePort
10, // 90: model.Pipe.pipeType:type_name -> model.Pipe.Type 10, // 90: model.Pipe.pipeType:type_name -> model.Pipe.Type
11, // 91: model.AirPavilion.pavilionType:type_name -> model.AirPavilion.Type 11, // 91: model.AirPavilion.pavilionType:type_name -> model.AirPavilion.Type
12, // 92: model.Valve.valveType:type_name -> model.Valve.Type 12, // 92: model.Valve.valveType:type_name -> model.Valve.Type
93, // [93:93] is the sub-list for method output_type 13, // 93: model.Fan.fanType:type_name -> model.Fan.Type
93, // [93:93] is the sub-list for method input_type 94, // [94:94] is the sub-list for method output_type
93, // [93:93] is the sub-list for extension type_name 94, // [94:94] is the sub-list for method input_type
93, // [93:93] is the sub-list for extension extendee 94, // [94:94] is the sub-list for extension type_name
0, // [0:93] is the sub-list for field type_name 94, // [94:94] is the sub-list for extension extendee
0, // [0:94] is the sub-list for field type_name
} }
func init() { file_model_proto_init() } func init() { file_model_proto_init() }
@ -6514,7 +6596,7 @@ func file_model_proto_init() {
File: protoimpl.DescBuilder{ File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(), GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: file_model_proto_rawDesc, RawDescriptor: file_model_proto_rawDesc,
NumEnums: 13, NumEnums: 14,
NumMessages: 53, NumMessages: 53,
NumExtensions: 0, NumExtensions: 0,
NumServices: 0, NumServices: 0,

View File

@ -101,7 +101,7 @@ func buildIscsModels(source *proto.Repository, repository *Repository) error {
} }
//ISCS风机 //ISCS风机
for _, protoData := range source.Fans { for _, protoData := range source.Fans {
m := NewFan(protoData.Id, protoData.Code) m := NewFan(protoData.Id, protoData.Code, protoData.FanType)
repository.FanMap[m.Id()] = m repository.FanMap[m.Id()] = m
} }
//ISCS气体环境 //ISCS气体环境