Я использую что-то вроде этого:
privileges do
# default privilege hierarchies to facilitate RESTful Rails apps
privilege :manage, :includes => [:create, :read, :update, :delete]
method_names = Bar.action_methods.to_a
meths = method_names - %w{create read update delete}
privilege :all_others, :includes => meths.map{|m| m.to_sym}
end
role :foo do
has_permission_on :bar, :to =>[:manage,:all_others]
end
хотя что-то вроде:
privileges do
# default privilege hierarchies to facilitate RESTful Rails apps
privilege :manage, :includes => [:create, :read, :update, :delete]
privilege :all, :includes => Bar.action_methods
end
role :foo do
has_permission_on :bar, :to =>[:all]
end
может лучше соответствовать вашим требованиям