From 4aace221ea9561e98aba03b8087646d67652c99c Mon Sep 17 00:00:00 2001 From: Rohan Mitchell Date: Thu, 20 Mar 2014 11:41:08 +1100 Subject: [PATCH] Enterprise user can reorder product properties and update product images --- app/models/spree/ability_decorator.rb | 4 ++-- spec/models/spree/ability_spec.rb | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/models/spree/ability_decorator.rb b/app/models/spree/ability_decorator.rb index 0fe8d22e59..83a4e5e0aa 100644 --- a/app/models/spree/ability_decorator.rb +++ b/app/models/spree/ability_decorator.rb @@ -15,8 +15,8 @@ class AbilityDecorator end can [:admin, :index, :read, :create, :edit, :update, :search, :destroy], Spree::Variant - can [:admin, :index, :read, :create, :edit, :destroy], Spree::ProductProperty - can [:admin, :index, :read, :create, :edit, :destroy], Spree::Image + can [:admin, :index, :read, :create, :edit, :update_positions, :destroy], Spree::ProductProperty + can [:admin, :index, :read, :create, :edit, :update, :destroy], Spree::Image can [:admin, :index, :read, :search], Spree::Taxon can [:admin, :index, :read, :create, :edit], Spree::Classification diff --git a/spec/models/spree/ability_spec.rb b/spec/models/spree/ability_spec.rb index 86c24aa9ec..71160c7f87 100644 --- a/spec/models/spree/ability_spec.rb +++ b/spec/models/spree/ability_spec.rb @@ -48,11 +48,11 @@ module Spree end it "should be able to read/write their enterprises' product properties" do - should have_ability([:admin, :index, :read, :create, :edit, :destroy], for: Spree::ProductProperty) + should have_ability([:admin, :index, :read, :create, :edit, :update_positions, :destroy], for: Spree::ProductProperty) end it "should be able to read/write their enterprises' product images" do - should have_ability([:admin, :index, :read, :create, :edit, :destroy], for: Spree::Image) + should have_ability([:admin, :index, :read, :create, :edit, :update, :destroy], for: Spree::Image) end it "should be able to read Taxons (in order to create classifications)" do