Skip to content

Commit d83b5bb

Browse files
authored
fix(region): capabilities query usable isolated device (#22360)
1 parent 4b81483 commit d83b5bb

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

pkg/compute/models/capabilities.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -864,6 +864,7 @@ func getIsolatedDeviceInfo(ctx context.Context, userCred mcclient.TokenCredentia
864864
hostQuery = StorageManager.FilterByOwner(ctx, hostQuery, StorageManager, userCred, ownerId, rbacscope.ScopeDomain)
865865
}
866866
if len(tenantId) > 0 {
867+
devicesQ = devicesQ.IsNullOrEmpty("guest_id")
867868
subq := db.SharedResourceManager.Query("resource_id")
868869
subq = subq.Equals("resource_type", IsolatedDeviceManager.Keyword())
869870
subq = subq.Equals("target_project_id", tenantId)

0 commit comments

Comments
 (0)