ISCS环境与设备监控系统ecs定义
This commit is contained in:
parent
e27ccfd184
commit
1d183dfa12
@ -171,6 +171,7 @@ var (
|
||||
var (
|
||||
DevicePlacingOverhaulCardTag = ecs.NewTag() //设备置牌:检修
|
||||
DevicePlacingLandingCardTag = ecs.NewTag() //设备置牌:接地
|
||||
DevicePlacingHandTag = ecs.NewTag() //设备置牌:就地(手型牌)
|
||||
DevicePlacingOtherCardTag = ecs.NewTag() //设备置牌:其他
|
||||
)
|
||||
|
||||
|
@ -15,6 +15,7 @@ const (
|
||||
PlacingNonCard PlacingCardOptEnum = iota
|
||||
PlacingOverhaulCard
|
||||
PlacingLandingCard
|
||||
PlacingHandCard
|
||||
PlacingOtherCard
|
||||
)
|
||||
|
||||
@ -30,6 +31,7 @@ func DevicePlacingCardOperate(w ecs.World, deviceId string, placingCard PlacingC
|
||||
deviceEntry.RemoveComponent(component.DevicePlacingLandingCardTag)
|
||||
deviceEntry.RemoveComponent(component.DevicePlacingOverhaulCardTag)
|
||||
deviceEntry.RemoveComponent(component.DevicePlacingOtherCardTag)
|
||||
deviceEntry.RemoveComponent(component.DevicePlacingHandTag)
|
||||
}
|
||||
switch placingCard {
|
||||
case PlacingLandingCard:
|
||||
@ -41,6 +43,9 @@ func DevicePlacingCardOperate(w ecs.World, deviceId string, placingCard PlacingC
|
||||
case PlacingOtherCard:
|
||||
clearAllPlacingTags(deviceEntry)
|
||||
deviceEntry.AddComponent(component.DevicePlacingOtherCardTag)
|
||||
case PlacingHandCard:
|
||||
clearAllPlacingTags(deviceEntry)
|
||||
deviceEntry.AddComponent(component.DevicePlacingHandTag)
|
||||
default:
|
||||
clearAllPlacingTags(deviceEntry)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user