商业版支持L2节点

This commit is contained in:
刘祥超
2022-04-04 12:08:08 +08:00
parent d884777a55
commit cd7e01c2f0
10 changed files with 305 additions and 28 deletions

View File

@@ -96,3 +96,15 @@ func (this *Node) DecodeSecondaryClusterIds() []int64 {
_ = json.Unmarshal(this.SecondaryClusterIds, &result)
return result
}
func (this *Node) AllClusterIds() []int64 {
var result = []int64{}
if this.ClusterId > 0 {
result = append(result, int64(this.ClusterId))
}
result = append(result, this.DecodeSecondaryClusterIds()...)
return result
}