Archived
统计节点分组中节点数量时判断节点集群是否存在
This commit is contained in:
@@ -941,6 +941,7 @@ func (this *NodeDAO) CountAllEnabledNodesWithGroupId(tx *dbs.Tx, groupId int64)
|
|||||||
return this.Query(tx).
|
return this.Query(tx).
|
||||||
State(NodeStateEnabled).
|
State(NodeStateEnabled).
|
||||||
Attr("groupId", groupId).
|
Attr("groupId", groupId).
|
||||||
|
Where("clusterId IN (SELECT id FROM " + SharedNodeClusterDAO.Table + " WHERE state=1)").
|
||||||
Count()
|
Count()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user