From 05ccbc7c979a328053170913c0e23331637ee2cc Mon Sep 17 00:00:00 2001 From: Adam Grare Date: Fri, 1 Nov 2024 12:13:33 -0400 Subject: [PATCH] Fix missing 'storages' association on Datacenter When provisioning a Vm as a user that belongs to a group with a belongs_to filter applying Rbac on storages fails due to a missing virtual_has_many on the Datacenter base class. --- app/models/ems_folder.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/app/models/ems_folder.rb b/app/models/ems_folder.rb index 5e965130be5..e89905e6265 100644 --- a/app/models/ems_folder.rb +++ b/app/models/ems_folder.rb @@ -18,6 +18,7 @@ class EmsFolder < ApplicationRecord virtual_has_many :vms, :uses => :all_relationships virtual_has_many :miq_templates, :uses => :all_relationships virtual_has_many :hosts, :uses => :all_relationships + virtual_has_many :storages, :uses => :all_relationships virtual_attribute :folder_path, :string, :uses => :all_relationships