capability: public network count filter by default vpc

This commit is contained in:
Zexi Li
2020-07-31 20:27:59 +08:00
parent 775c423441
commit 8dd25e01c5
+1 -1
View File
@@ -622,7 +622,7 @@ func getNetworkCountByFilter(region *SCloudregion, zone *SZone, domainId string,
}
vpcs := vpcQuery.SubQuery()*/
wireQuery := WireManager.Query()
wireQuery := WireManager.Query().Equals("vpc_id", api.DEFAULT_VPC_ID)
if len(domainId) > 0 {
ownerId := &db.SOwnerId{DomainId: domainId}
wireQuery = WireManager.FilterByOwner(wireQuery, ownerId, rbacutils.ScopeDomain)