From cc6af82823d35030a6f402106a5f037ea6cbfec7 Mon Sep 17 00:00:00 2001 From: Rafael Schouten Date: Mon, 6 Oct 2014 15:40:41 +1100 Subject: [PATCH] move reports abilitiy to can manage products block, producers need to use this too --- app/models/spree/ability_decorator.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/models/spree/ability_decorator.rb b/app/models/spree/ability_decorator.rb index c158e90993..a5d5f8be33 100644 --- a/app/models/spree/ability_decorator.rb +++ b/app/models/spree/ability_decorator.rb @@ -79,6 +79,8 @@ class AbilityDecorator can [:admin, :index, :read, :search], Spree::Taxon can [:admin, :index, :read, :create, :edit], Spree::Classification + # Reports page + can [:admin, :index, :customers, :orders_and_distributors, :group_buys, :bulk_coop, :payments, :orders_and_fulfillment, :products_and_inventory], :report end def add_order_management_abilities(user) @@ -118,8 +120,6 @@ class AbilityDecorator (user.enterprises & shipping_method.distributors).any? end - # Reports page - can [:admin, :index, :customers, :orders_and_distributors, :group_buys, :bulk_coop, :payments, :orders_and_fulfillment, :products_and_inventory], :report end