Merge branch 'master' of https://git.code.tencent.com/beijing-rtss-test/bj-rtsts-server-go
# Conflicts: # ats/verify/simulation/wayside/memory/wayside_simulation.go
This commit is contained in:
commit
cd0bffcd36
@ -244,20 +244,24 @@ func buildAndRelateElectronicComponent(repo *proto.Repository, relayGi *graphicD
|
||||
if signal == nil {
|
||||
continue
|
||||
}
|
||||
for _, group := range relationship.Combinationtypes {
|
||||
var componentIds []string
|
||||
for _, relayId := range group.RefRelays {
|
||||
if uidsMap.RelayIds[relayId] == nil {
|
||||
continue
|
||||
}
|
||||
componentIds = append(componentIds, uidsMap.RelayIds[relayId].Uid)
|
||||
}
|
||||
signal.ElectronicComponentGroups = append(signal.ElectronicComponentGroups,
|
||||
&proto.ElectronicComponentGroup{
|
||||
Code: group.Code,
|
||||
ComponentIds: componentIds,
|
||||
})
|
||||
//信号机只有一个组合类型
|
||||
if len(relationship.Combinationtypes) != 1 {
|
||||
panic(fmt.Sprintf("信号机[%s]须有一个组合类型", signal.Id))
|
||||
}
|
||||
group := relationship.Combinationtypes[0]
|
||||
var componentIds []string
|
||||
for _, relayId := range group.RefRelays {
|
||||
if uidsMap.RelayIds[relayId] == nil {
|
||||
continue
|
||||
}
|
||||
componentIds = append(componentIds, uidsMap.RelayIds[relayId].Uid)
|
||||
}
|
||||
signal.Code = group.Code
|
||||
signal.ElectronicComponentGroups = append(signal.ElectronicComponentGroups,
|
||||
&proto.ElectronicComponentGroup{
|
||||
Code: group.Code,
|
||||
ComponentIds: componentIds,
|
||||
})
|
||||
case graphicData.RelatedRef_station:
|
||||
station := stationMap[GenerateElementUid(city, lineId, nil, relationship.Code)]
|
||||
if station == nil {
|
||||
@ -374,6 +378,7 @@ func fillProtoRepository(repo *proto.Repository, storage *graphicData.RtssGraphi
|
||||
Km: convertKm(data.KilometerSystem),
|
||||
SectionId: sectionId,
|
||||
TurnoutPort: turnoutPort,
|
||||
//Code: data.,
|
||||
}
|
||||
repo.Signals = append(repo.Signals, converSignalUid(signal, uidsMap))
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user