app/controllers/mixins/actions/vm_actions/ownership.rb
# Assign/unassign ownership to a set of objects
Assign/unassign ownership to a set of objects
Assign / unassign ownership to a set of objects
def load_user_group_items(ownership_ids, klass)
          @ownershipitems ||= filter_ownership_items(klass, ownership_ids)
          if @ownershipitems.length > 1
            @user = @group = 'dont-change'
          else
            record = @ownershipitems.first
            @user = record.evm_owner.id.to_s if record.evm_owner
            @group = record.miq_group.id.to_s if record.miq_group
          end
        end
def load_user_group_items ( ownership_ids , klass ) @ownershipitems ||= filter_ownership_items ( klass , ownership_ids ) if @ownershipitems . length > 1 @user = @group = 'dont-change' else record = @ownershipitems . first @user = record . evm_owner . id . to_s if record . evm_owner @group = record . miq_group . id . to_s if record . miq_group end end
Assign/unassign ownership to a set of objects
Assign / unassign ownership to a set of objects
ownership_ids
<not_specific>
klass
<not_specific>