Skip to content

Commit

Permalink
sites provide permissions for managing users
Browse files Browse the repository at this point in the history
  • Loading branch information
Sven Fuchs committed Jul 17, 2008
1 parent 5c68376 commit ee30e5c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion spec/models/site_spec.rb
Expand Up @@ -37,7 +37,8 @@
Site.default_permissions.should ==
{ :site => { :show => :admin, :create => :superuser, :update => :admin, :destroy => :superuser, :manage => :admin },
:section => { :show => :admin, :create => :admin, :update => :admin, :destroy => :admin },
:theme => { :show => :admin, :create => :admin, :update => :admin, :destroy => :admin } }
:theme => { :show => :admin, :create => :admin, :update => :admin, :destroy => :admin },
:user => { :show => :admin, :create => :admin, :update => :admin, :destroy => :admin } }
end

it "has a comments counter" do
Expand Down
3 changes: 2 additions & 1 deletion vendor/engines/adva_cms/app/models/site.rb
Expand Up @@ -8,7 +8,8 @@ class Site < ActiveRecord::Base
serialize :spam_options
permissions :site => { :superuser => [:create, :destroy], :admin => [:show, :update, :manage] },
:section => { :admin => :all },
:theme => { :admin => :all }
:theme => { :admin => :all },
:user => { :admin => :all }

has_many :sections, :dependent => :destroy, :order => :lft do
def root
Expand Down

0 comments on commit ee30e5c

Please sign in to comment.