Sha256: 0c352c9a97f8062ba1726adfa3497816f132df0771447e64cce0da7ac2a0c749
Contents?: true
Size: 620 Bytes
Versions: 26
Compression:
Stored size: 620 Bytes
Contents
class FixSubscriptionPermissions < ActiveRecord::Migration def up permission_names = [:view_subscriptions, :attach_subscriptions, :unattach_subscriptions, :import_manifest, :delete_manifest] Permission.where(:resource_type => 'Organization', :name => permission_names).update_all(resource_type: 'Katello::Subscription') end def down permission_names = [:view_subscriptions, :attach_subscriptions, :unattach_subscriptions, :import_manifest, :delete_manifest] Permission.where(:resource_type => 'Katello::Subscription', :name => permission_names).update_all(resource_type: 'Organization') end end
Version data entries
26 entries across 26 versions & 1 rubygems