Implemented the site ability fix for designers.

This commit is contained in:
Mario Visic 2011-08-20 17:33:13 +08:00
parent 5c3cf83082
commit a7bc648333
2 changed files with 3 additions and 1 deletions

View File

@ -61,6 +61,8 @@ class Ability
can :point, Site can :point, Site
cannot :create, Site
can :manage, Membership can :manage, Membership
cannot :change_role, Membership do |membership| cannot :change_role, Membership do |membership|

View File

@ -8,7 +8,7 @@
- if multi_sites? - if multi_sites?
- content_for :buttons do - content_for :buttons do
= admin_button_tag t('.new_site'), new_admin_site_url, :class => 'new' if can?(:manage, Site) = admin_button_tag t('.new_site'), new_admin_site_url, :class => 'new' if can?(:create, Site)
%p= t('.help') %p= t('.help')