solidus_legacy_return_authorizations 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +15 -0
- data/.rspec +1 -0
- data/Gemfile +10 -0
- data/LICENSE +26 -0
- data/README.md +62 -0
- data/Rakefile +21 -0
- data/app/assets/javascripts/spree/backend/solidus_legacy_return_authorizations.js +2 -0
- data/app/assets/stylesheets/spree/backend/solidus_legacy_return_authorizations.css +4 -0
- data/app/controllers/spree/admin/legacy_return_authorizations_controller.rb +25 -0
- data/app/controllers/spree/api/legacy_return_authorizations_controller.rb +74 -0
- data/app/helpers/spree/admin/navigation_helper_decorator.rb +12 -0
- data/app/helpers/spree/api/api_helpers_decorator.rb +7 -0
- data/app/models/spree/adjustment_decorator.rb +3 -0
- data/app/models/spree/inventory_unit_decorator.rb +3 -0
- data/app/models/spree/legacy_return_authorization.rb +108 -0
- data/app/models/spree/order_decorator.rb +3 -0
- data/app/models/spree/permission_sets/legacy_return_authorization_display.rb +9 -0
- data/app/models/spree/permission_sets/legacy_return_authorization_management.rb +9 -0
- data/app/models/spree/strong_parameters_decorator.rb +5 -0
- data/app/overrides/admin_legacy_return_authorizations.rb +14 -0
- data/app/views/spree/admin/legacy_return_authorizations/_form.html.erb +78 -0
- data/app/views/spree/admin/legacy_return_authorizations/edit.html.erb +32 -0
- data/app/views/spree/admin/legacy_return_authorizations/index.html.erb +48 -0
- data/app/views/spree/api/legacy_return_authorizations/index.v1.rabl +7 -0
- data/app/views/spree/api/legacy_return_authorizations/new.v1.rabl +3 -0
- data/app/views/spree/api/legacy_return_authorizations/show.v1.rabl +2 -0
- data/bin/rails +7 -0
- data/circle.yml +6 -0
- data/config/locales/en.yml +19 -0
- data/config/routes.rb +25 -0
- data/db/migrate/20140710044402_create_spree_legacy_return_authorizations.rb +26 -0
- data/lib/generators/solidus_legacy_return_authorizations/install/install_generator.rb +29 -0
- data/lib/solidus_legacy_return_authorizations.rb +2 -0
- data/lib/spree_legacy_return_authorizations/engine.rb +20 -0
- data/lib/spree_legacy_return_authorizations/factories.rb +13 -0
- data/solidus_legacy_return_authorizations.gemspec +29 -0
- data/spec/controllers/admin/legacy_return_authorizations_controller_spec.rb +32 -0
- data/spec/controllers/spree/api/legacy_return_authorizations_controller_spec.rb +157 -0
- data/spec/features/admin/orders/legacy_return_authorizations_spec.rb +26 -0
- data/spec/models/spree/legacy_return_authorization_spec.rb +214 -0
- data/spec/models/spree/permission_sets/legacy_return_authorization_display_spec.rb +22 -0
- data/spec/models/spree/permission_sets/legacy_return_authorization_management_spec.rb +20 -0
- data/spec/spec_helper.rb +74 -0
- data/spec/support/authentication_support.rb +7 -0
- data/spec/support/have_attributes_matcher.rb +8 -0
- metadata +245 -0
@@ -0,0 +1,26 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe "legacy return authorizations" do
|
4
|
+
stub_authorization!
|
5
|
+
|
6
|
+
let!(:order) { create(:shipped_order) }
|
7
|
+
|
8
|
+
before do
|
9
|
+
create(:legacy_return_authorization,
|
10
|
+
:order => order,
|
11
|
+
:state => 'authorized',
|
12
|
+
:inventory_units => order.shipments.first.inventory_units,
|
13
|
+
:stock_location_id => order.shipments.first.stock_location_id)
|
14
|
+
end
|
15
|
+
|
16
|
+
# Regression test for #1107
|
17
|
+
it "doesn't blow up when receiving a legacy return authorization" do
|
18
|
+
visit spree.admin_path
|
19
|
+
click_link "Orders"
|
20
|
+
click_link order.number
|
21
|
+
click_link "Legacy Return Authorizations"
|
22
|
+
click_link "Edit"
|
23
|
+
expect { click_button "receive" }.not_to raise_error
|
24
|
+
end
|
25
|
+
|
26
|
+
end
|
@@ -0,0 +1,214 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe Spree::LegacyReturnAuthorization do
|
4
|
+
let(:stock_location) { Spree::StockLocation.create(:name => "test") }
|
5
|
+
let(:order) { FactoryGirl.create(:shipped_order) }
|
6
|
+
|
7
|
+
let(:variant) { order.variants.first }
|
8
|
+
let(:legacy_return_authorization) { Spree::LegacyReturnAuthorization.new(:order => order, :stock_location_id => stock_location.id) }
|
9
|
+
|
10
|
+
context "save" do
|
11
|
+
let(:order) { Spree::Order.create }
|
12
|
+
|
13
|
+
it "should be invalid when order has no inventory units" do
|
14
|
+
legacy_return_authorization.save
|
15
|
+
expect(legacy_return_authorization.errors[:order]).to eq(["has no shipped units"])
|
16
|
+
end
|
17
|
+
end
|
18
|
+
|
19
|
+
describe ".before_create" do
|
20
|
+
describe "#generate_number" do
|
21
|
+
context "number is assigned" do
|
22
|
+
let(:legacy_return_authorization) { Spree::LegacyReturnAuthorization.new(number: '123') }
|
23
|
+
|
24
|
+
it "should return the assigned number" do
|
25
|
+
legacy_return_authorization.save
|
26
|
+
expect(legacy_return_authorization.number).to eq('123')
|
27
|
+
end
|
28
|
+
end
|
29
|
+
|
30
|
+
context "number is not assigned" do
|
31
|
+
let(:legacy_return_authorization) { Spree::LegacyReturnAuthorization.new(number: nil) }
|
32
|
+
|
33
|
+
before { allow(legacy_return_authorization).to receive_messages valid?: true }
|
34
|
+
|
35
|
+
it "should assign number with random RMA number" do
|
36
|
+
legacy_return_authorization.save
|
37
|
+
expect(legacy_return_authorization.number).to match(/RMA\d{9}/)
|
38
|
+
end
|
39
|
+
end
|
40
|
+
end
|
41
|
+
end
|
42
|
+
|
43
|
+
context "add_variant" do
|
44
|
+
context "on empty rma" do
|
45
|
+
it "should associate inventory units as shipped" do
|
46
|
+
legacy_return_authorization.add_variant(variant.id, 1)
|
47
|
+
expect(legacy_return_authorization.inventory_units.where(state: 'shipped').size).to eq 1
|
48
|
+
end
|
49
|
+
|
50
|
+
it "should update order state" do
|
51
|
+
expect(order).to receive(:authorize_return!)
|
52
|
+
legacy_return_authorization.add_variant(variant.id, 1)
|
53
|
+
end
|
54
|
+
end
|
55
|
+
|
56
|
+
context "on rma that already has inventory_units" do
|
57
|
+
before do
|
58
|
+
legacy_return_authorization.add_variant(variant.id, 1)
|
59
|
+
end
|
60
|
+
|
61
|
+
it "should not associate more inventory units than there are on the order" do
|
62
|
+
legacy_return_authorization.add_variant(variant.id, 1)
|
63
|
+
expect(legacy_return_authorization.inventory_units.size).to eq 1
|
64
|
+
end
|
65
|
+
|
66
|
+
it "should not update order state" do
|
67
|
+
expect{legacy_return_authorization.add_variant(variant.id, 1)}.to_not change{order.state}
|
68
|
+
end
|
69
|
+
end
|
70
|
+
end
|
71
|
+
|
72
|
+
context "can_receive?" do
|
73
|
+
it "should allow_receive when inventory units assigned" do
|
74
|
+
allow(legacy_return_authorization).to receive_messages(:inventory_units => [1,2,3])
|
75
|
+
expect(legacy_return_authorization.can_receive?).to be_truthy
|
76
|
+
end
|
77
|
+
|
78
|
+
it "should not allow_receive with no inventory units" do
|
79
|
+
allow(legacy_return_authorization).to receive_messages(:inventory_units => [])
|
80
|
+
expect(legacy_return_authorization.can_receive?).to be_falsey
|
81
|
+
end
|
82
|
+
end
|
83
|
+
|
84
|
+
context "receive!" do
|
85
|
+
let(:inventory_unit) { order.shipments.first.inventory_units.first }
|
86
|
+
|
87
|
+
context "to the initial stock location" do
|
88
|
+
before do
|
89
|
+
allow(legacy_return_authorization).to receive_messages(:inventory_units => [inventory_unit], :amount => -20)
|
90
|
+
allow(legacy_return_authorization).to receive_messages(:stock_location_id => inventory_unit.shipment.stock_location.id)
|
91
|
+
allow(Spree::Adjustment).to receive(:create)
|
92
|
+
allow(order).to receive(:update!)
|
93
|
+
end
|
94
|
+
|
95
|
+
it "should mark all inventory units are returned" do
|
96
|
+
expect(inventory_unit).to receive(:return!)
|
97
|
+
legacy_return_authorization.receive!
|
98
|
+
end
|
99
|
+
|
100
|
+
it "should add credit for specified amount" do
|
101
|
+
legacy_return_authorization.amount = 20
|
102
|
+
expect(Spree::Adjustment).to receive(:create).with(adjustable: order, amount: -20, label: Spree.t(:legacy_rma_credit), source: legacy_return_authorization)
|
103
|
+
legacy_return_authorization.receive!
|
104
|
+
end
|
105
|
+
|
106
|
+
it "should update order state" do
|
107
|
+
expect(order).to receive :update!
|
108
|
+
legacy_return_authorization.receive!
|
109
|
+
end
|
110
|
+
|
111
|
+
context 'with Config.track_inventory_levels == true' do
|
112
|
+
before { Spree::Config.track_inventory_levels = true }
|
113
|
+
|
114
|
+
it "should update the stock item counts in the stock location" do
|
115
|
+
count_on_hand = inventory_unit.find_stock_item.count_on_hand
|
116
|
+
legacy_return_authorization.receive!
|
117
|
+
expect(inventory_unit.find_stock_item.count_on_hand).to eq(count_on_hand + 1)
|
118
|
+
end
|
119
|
+
end
|
120
|
+
|
121
|
+
context 'with Config.track_inventory_levels == false' do
|
122
|
+
before do
|
123
|
+
expect(Spree::StockItem).not_to receive(:find_by)
|
124
|
+
expect(Spree::StockMovement).not_to receive(:create!)
|
125
|
+
Spree::Config.track_inventory_levels = false
|
126
|
+
end
|
127
|
+
|
128
|
+
it "should NOT update the stock item counts in the stock location" do
|
129
|
+
count_on_hand = inventory_unit.find_stock_item.count_on_hand
|
130
|
+
legacy_return_authorization.receive!
|
131
|
+
expect(inventory_unit.find_stock_item.count_on_hand).to eql count_on_hand
|
132
|
+
end
|
133
|
+
end
|
134
|
+
end
|
135
|
+
|
136
|
+
context "to a different stock location" do
|
137
|
+
let(:new_stock_location) { FactoryGirl.create(:stock_location, :name => "other") }
|
138
|
+
|
139
|
+
before do
|
140
|
+
allow(legacy_return_authorization).to receive_messages(:stock_location_id => new_stock_location.id)
|
141
|
+
allow(legacy_return_authorization).to receive_messages(:inventory_units => [inventory_unit], :amount => -20)
|
142
|
+
Spree::Config.track_inventory_levels = true
|
143
|
+
end
|
144
|
+
|
145
|
+
it "should update the stock item counts in new stock location" do
|
146
|
+
count_on_hand = Spree::StockItem.where(variant_id: inventory_unit.variant_id, stock_location_id: new_stock_location.id).first.count_on_hand
|
147
|
+
legacy_return_authorization.receive!
|
148
|
+
expect(Spree::StockItem.where(variant_id: inventory_unit.variant_id, stock_location_id: new_stock_location.id).first.count_on_hand).to eq(count_on_hand + 1)
|
149
|
+
end
|
150
|
+
|
151
|
+
it "should NOT raise an error when no stock item exists in the stock location" do
|
152
|
+
inventory_unit.find_stock_item.destroy
|
153
|
+
expect { legacy_return_authorization.receive! }.not_to raise_error
|
154
|
+
end
|
155
|
+
|
156
|
+
it "should not update the stock item counts in the original stock location" do
|
157
|
+
count_on_hand = inventory_unit.find_stock_item.count_on_hand
|
158
|
+
legacy_return_authorization.receive!
|
159
|
+
expect(inventory_unit.find_stock_item.count_on_hand).to eq(count_on_hand)
|
160
|
+
end
|
161
|
+
end
|
162
|
+
end
|
163
|
+
|
164
|
+
context "force_positive_amount" do
|
165
|
+
it "should ensure the amount is always positive" do
|
166
|
+
legacy_return_authorization.amount = -10
|
167
|
+
legacy_return_authorization.send :force_positive_amount
|
168
|
+
expect(legacy_return_authorization.amount).to eq(10)
|
169
|
+
end
|
170
|
+
end
|
171
|
+
|
172
|
+
context "after_save" do
|
173
|
+
it "should run correct callbacks" do
|
174
|
+
expect(legacy_return_authorization).to receive(:force_positive_amount)
|
175
|
+
legacy_return_authorization.run_callbacks(:save)
|
176
|
+
end
|
177
|
+
end
|
178
|
+
|
179
|
+
context "currency" do
|
180
|
+
before { allow(order).to receive(:currency) { "ABC" } }
|
181
|
+
it "returns the order currency" do
|
182
|
+
expect(legacy_return_authorization.currency).to eq("ABC")
|
183
|
+
end
|
184
|
+
end
|
185
|
+
|
186
|
+
context "display_amount" do
|
187
|
+
it "returns a Spree::Money" do
|
188
|
+
legacy_return_authorization.amount = 21.22
|
189
|
+
expect(legacy_return_authorization.display_amount).to eq(Spree::Money.new(21.22))
|
190
|
+
end
|
191
|
+
end
|
192
|
+
|
193
|
+
context "returnable_inventory" do
|
194
|
+
skip "should return inventory from shipped shipments" do
|
195
|
+
expect(legacy_return_authorization.returnable_inventory).to eq([inventory_unit])
|
196
|
+
end
|
197
|
+
|
198
|
+
skip "should not return inventory from unshipped shipments" do
|
199
|
+
expect(legacy_return_authorization.returnable_inventory).to eq([])
|
200
|
+
end
|
201
|
+
end
|
202
|
+
|
203
|
+
context "destroy" do
|
204
|
+
before do
|
205
|
+
legacy_return_authorization.add_variant(variant.id, 1)
|
206
|
+
legacy_return_authorization.destroy
|
207
|
+
end
|
208
|
+
|
209
|
+
# Regression test for https://github.com/spree/spree/issues/4935
|
210
|
+
it "disassociates inventory units" do
|
211
|
+
expect(Spree::InventoryUnit.where(legacy_return_authorization_id: legacy_return_authorization.id).count).to eq 0
|
212
|
+
end
|
213
|
+
end
|
214
|
+
end
|
@@ -0,0 +1,22 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe Spree::PermissionSets::LegacyReturnAuthorizationDisplay do
|
4
|
+
let(:ability) { Spree::Ability.new nil }
|
5
|
+
|
6
|
+
subject { ability }
|
7
|
+
|
8
|
+
context "when activated" do
|
9
|
+
before do
|
10
|
+
described_class.new(ability).activate!
|
11
|
+
end
|
12
|
+
|
13
|
+
it { should be_able_to(:display, Spree::LegacyReturnAuthorization) }
|
14
|
+
it { should be_able_to(:admin, Spree::LegacyReturnAuthorization) }
|
15
|
+
end
|
16
|
+
|
17
|
+
context "when not activated" do
|
18
|
+
it { should_not be_able_to(:display, Spree::LegacyReturnAuthorization) }
|
19
|
+
it { should_not be_able_to(:admin, Spree::LegacyReturnAuthorization) }
|
20
|
+
end
|
21
|
+
end
|
22
|
+
|
@@ -0,0 +1,20 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe Spree::PermissionSets::LegacyReturnAuthorizationManagement do
|
4
|
+
let(:ability) { Spree::Ability.new nil }
|
5
|
+
|
6
|
+
subject { ability }
|
7
|
+
|
8
|
+
context "when activated" do
|
9
|
+
before do
|
10
|
+
described_class.new(ability).activate!
|
11
|
+
end
|
12
|
+
|
13
|
+
it { should be_able_to(:manage, Spree::LegacyReturnAuthorization) }
|
14
|
+
end
|
15
|
+
|
16
|
+
context "when not activated" do
|
17
|
+
it { should_not be_able_to(:manage, Spree::LegacyReturnAuthorization) }
|
18
|
+
end
|
19
|
+
end
|
20
|
+
|
data/spec/spec_helper.rb
ADDED
@@ -0,0 +1,74 @@
|
|
1
|
+
# Run Coverage report
|
2
|
+
require 'simplecov'
|
3
|
+
SimpleCov.start do
|
4
|
+
add_filter 'spec/dummy'
|
5
|
+
add_group 'Controllers', 'app/controllers'
|
6
|
+
add_group 'Helpers', 'app/helpers'
|
7
|
+
add_group 'Mailers', 'app/mailers'
|
8
|
+
add_group 'Models', 'app/models'
|
9
|
+
add_group 'Views', 'app/views'
|
10
|
+
add_group 'Libraries', 'lib'
|
11
|
+
end
|
12
|
+
|
13
|
+
# Configure Rails Environment
|
14
|
+
ENV['RAILS_ENV'] = 'test'
|
15
|
+
|
16
|
+
require File.expand_path('../dummy/config/environment.rb', __FILE__)
|
17
|
+
|
18
|
+
require 'rspec/rails'
|
19
|
+
|
20
|
+
require 'database_cleaner'
|
21
|
+
require 'ffaker'
|
22
|
+
|
23
|
+
require 'spree/testing_support/factories'
|
24
|
+
require 'spree/testing_support/controller_requests'
|
25
|
+
require 'spree/testing_support/authorization_helpers'
|
26
|
+
require 'spree/testing_support/url_helpers'
|
27
|
+
|
28
|
+
require 'spree/api/testing_support/helpers'
|
29
|
+
require 'cancan/matchers'
|
30
|
+
|
31
|
+
require 'spree_legacy_return_authorizations/factories'
|
32
|
+
|
33
|
+
Dir[File.join(File.dirname(__FILE__), 'support/**/*.rb')].each { |f| require f }
|
34
|
+
|
35
|
+
RSpec.configure do |config|
|
36
|
+
config.infer_spec_type_from_file_location!
|
37
|
+
config.mock_with :rspec
|
38
|
+
|
39
|
+
config.color = true
|
40
|
+
config.order = "random"
|
41
|
+
|
42
|
+
config.expose_current_running_example_as :example
|
43
|
+
config.fail_fast = ENV["FAIL_FAST"] || false
|
44
|
+
|
45
|
+
config.filter_run focus: true
|
46
|
+
config.run_all_when_everything_filtered = true
|
47
|
+
config.use_transactional_fixtures = false
|
48
|
+
|
49
|
+
config.include FactoryGirl::Syntax::Methods
|
50
|
+
config.include Spree::TestingSupport::ControllerRequests, type: :controller
|
51
|
+
config.include Spree::TestingSupport::UrlHelpers, type: :controller
|
52
|
+
config.include Spree::Api::TestingSupport::Helpers, type: :controller
|
53
|
+
config.include AuthenticationSupport, type: :controller
|
54
|
+
|
55
|
+
# Ensure Suite is set to use transactions for speed.
|
56
|
+
config.before :suite do
|
57
|
+
DatabaseCleaner.strategy = :transaction
|
58
|
+
DatabaseCleaner.clean_with :truncation
|
59
|
+
end
|
60
|
+
|
61
|
+
# Before each spec check if it is a Javascript test and switch between using database transactions or not where necessary.
|
62
|
+
config.before :each do
|
63
|
+
DatabaseCleaner.strategy = example.metadata[:js] ? :truncation : :transaction
|
64
|
+
DatabaseCleaner.start
|
65
|
+
|
66
|
+
Spree::Config.reset
|
67
|
+
Spree::Api::Config[:requires_authentication] = true
|
68
|
+
end
|
69
|
+
|
70
|
+
# After each spec clean the database.
|
71
|
+
config.after :each do
|
72
|
+
DatabaseCleaner.clean
|
73
|
+
end
|
74
|
+
end
|
@@ -0,0 +1,7 @@
|
|
1
|
+
module AuthenticationSupport
|
2
|
+
def stub_api_controller_authentication!(options={})
|
3
|
+
@current_api_user = options[:admin] ? create(:admin_user) : create(:user)
|
4
|
+
allow(controller).to receive(:load_user)
|
5
|
+
controller.instance_variable_set(:@current_api_user, @current_api_user)
|
6
|
+
end
|
7
|
+
end
|
@@ -0,0 +1,8 @@
|
|
1
|
+
RSpec::Matchers.define :have_attributes do |expected_attributes|
|
2
|
+
match do |actual|
|
3
|
+
# actual is a Hash object representing an object, like this:
|
4
|
+
# { "name" => "Product #1" }
|
5
|
+
actual_attributes = actual.keys.map(&:to_sym)
|
6
|
+
expected_attributes.map(&:to_sym).all? { |attr| actual_attributes.include?(attr) }
|
7
|
+
end
|
8
|
+
end
|
metadata
ADDED
@@ -0,0 +1,245 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: solidus_legacy_return_authorizations
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 1.0.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Richard Nuno
|
8
|
+
- Jordan Brough
|
9
|
+
autorequire:
|
10
|
+
bindir: bin
|
11
|
+
cert_chain: []
|
12
|
+
date: 2015-08-27 00:00:00.000000000 Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
15
|
+
name: solidus_core
|
16
|
+
requirement: !ruby/object:Gem::Requirement
|
17
|
+
requirements:
|
18
|
+
- - ">="
|
19
|
+
- !ruby/object:Gem::Version
|
20
|
+
version: 1.0.0
|
21
|
+
- - "<"
|
22
|
+
- !ruby/object:Gem::Version
|
23
|
+
version: 1.2.0
|
24
|
+
type: :runtime
|
25
|
+
prerelease: false
|
26
|
+
version_requirements: !ruby/object:Gem::Requirement
|
27
|
+
requirements:
|
28
|
+
- - ">="
|
29
|
+
- !ruby/object:Gem::Version
|
30
|
+
version: 1.0.0
|
31
|
+
- - "<"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: 1.2.0
|
34
|
+
- !ruby/object:Gem::Dependency
|
35
|
+
name: rspec-rails
|
36
|
+
requirement: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '3.2'
|
41
|
+
type: :development
|
42
|
+
prerelease: false
|
43
|
+
version_requirements: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '3.2'
|
48
|
+
- !ruby/object:Gem::Dependency
|
49
|
+
name: simplecov
|
50
|
+
requirement: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - ">="
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0'
|
55
|
+
type: :development
|
56
|
+
prerelease: false
|
57
|
+
version_requirements: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - ">="
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
- !ruby/object:Gem::Dependency
|
63
|
+
name: sqlite3
|
64
|
+
requirement: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - ">="
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0'
|
69
|
+
type: :development
|
70
|
+
prerelease: false
|
71
|
+
version_requirements: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - ">="
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '0'
|
76
|
+
- !ruby/object:Gem::Dependency
|
77
|
+
name: sass-rails
|
78
|
+
requirement: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: 4.0.2
|
83
|
+
type: :development
|
84
|
+
prerelease: false
|
85
|
+
version_requirements: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - "~>"
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: 4.0.2
|
90
|
+
- !ruby/object:Gem::Dependency
|
91
|
+
name: coffee-rails
|
92
|
+
requirement: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - ">="
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '0'
|
97
|
+
type: :development
|
98
|
+
prerelease: false
|
99
|
+
version_requirements: !ruby/object:Gem::Requirement
|
100
|
+
requirements:
|
101
|
+
- - ">="
|
102
|
+
- !ruby/object:Gem::Version
|
103
|
+
version: '0'
|
104
|
+
- !ruby/object:Gem::Dependency
|
105
|
+
name: capybara
|
106
|
+
requirement: !ruby/object:Gem::Requirement
|
107
|
+
requirements:
|
108
|
+
- - "~>"
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: '2.1'
|
111
|
+
type: :development
|
112
|
+
prerelease: false
|
113
|
+
version_requirements: !ruby/object:Gem::Requirement
|
114
|
+
requirements:
|
115
|
+
- - "~>"
|
116
|
+
- !ruby/object:Gem::Version
|
117
|
+
version: '2.1'
|
118
|
+
- !ruby/object:Gem::Dependency
|
119
|
+
name: factory_girl
|
120
|
+
requirement: !ruby/object:Gem::Requirement
|
121
|
+
requirements:
|
122
|
+
- - "~>"
|
123
|
+
- !ruby/object:Gem::Version
|
124
|
+
version: '4.4'
|
125
|
+
type: :development
|
126
|
+
prerelease: false
|
127
|
+
version_requirements: !ruby/object:Gem::Requirement
|
128
|
+
requirements:
|
129
|
+
- - "~>"
|
130
|
+
- !ruby/object:Gem::Version
|
131
|
+
version: '4.4'
|
132
|
+
- !ruby/object:Gem::Dependency
|
133
|
+
name: database_cleaner
|
134
|
+
requirement: !ruby/object:Gem::Requirement
|
135
|
+
requirements:
|
136
|
+
- - ">="
|
137
|
+
- !ruby/object:Gem::Version
|
138
|
+
version: '0'
|
139
|
+
type: :development
|
140
|
+
prerelease: false
|
141
|
+
version_requirements: !ruby/object:Gem::Requirement
|
142
|
+
requirements:
|
143
|
+
- - ">="
|
144
|
+
- !ruby/object:Gem::Version
|
145
|
+
version: '0'
|
146
|
+
- !ruby/object:Gem::Dependency
|
147
|
+
name: ffaker
|
148
|
+
requirement: !ruby/object:Gem::Requirement
|
149
|
+
requirements:
|
150
|
+
- - ">="
|
151
|
+
- !ruby/object:Gem::Version
|
152
|
+
version: '0'
|
153
|
+
type: :development
|
154
|
+
prerelease: false
|
155
|
+
version_requirements: !ruby/object:Gem::Requirement
|
156
|
+
requirements:
|
157
|
+
- - ">="
|
158
|
+
- !ruby/object:Gem::Version
|
159
|
+
version: '0'
|
160
|
+
description: Provides models and admin interfaces to interact with the LegacyReturnAuthorization
|
161
|
+
models from Spree versions prior to 2.4
|
162
|
+
email:
|
163
|
+
executables: []
|
164
|
+
extensions: []
|
165
|
+
extra_rdoc_files: []
|
166
|
+
files:
|
167
|
+
- ".gitignore"
|
168
|
+
- ".rspec"
|
169
|
+
- Gemfile
|
170
|
+
- LICENSE
|
171
|
+
- README.md
|
172
|
+
- Rakefile
|
173
|
+
- app/assets/javascripts/spree/backend/solidus_legacy_return_authorizations.js
|
174
|
+
- app/assets/stylesheets/spree/backend/solidus_legacy_return_authorizations.css
|
175
|
+
- app/controllers/spree/admin/legacy_return_authorizations_controller.rb
|
176
|
+
- app/controllers/spree/api/legacy_return_authorizations_controller.rb
|
177
|
+
- app/helpers/spree/admin/navigation_helper_decorator.rb
|
178
|
+
- app/helpers/spree/api/api_helpers_decorator.rb
|
179
|
+
- app/models/spree/adjustment_decorator.rb
|
180
|
+
- app/models/spree/inventory_unit_decorator.rb
|
181
|
+
- app/models/spree/legacy_return_authorization.rb
|
182
|
+
- app/models/spree/order_decorator.rb
|
183
|
+
- app/models/spree/permission_sets/legacy_return_authorization_display.rb
|
184
|
+
- app/models/spree/permission_sets/legacy_return_authorization_management.rb
|
185
|
+
- app/models/spree/strong_parameters_decorator.rb
|
186
|
+
- app/overrides/admin_legacy_return_authorizations.rb
|
187
|
+
- app/views/spree/admin/legacy_return_authorizations/_form.html.erb
|
188
|
+
- app/views/spree/admin/legacy_return_authorizations/edit.html.erb
|
189
|
+
- app/views/spree/admin/legacy_return_authorizations/index.html.erb
|
190
|
+
- app/views/spree/api/legacy_return_authorizations/index.v1.rabl
|
191
|
+
- app/views/spree/api/legacy_return_authorizations/new.v1.rabl
|
192
|
+
- app/views/spree/api/legacy_return_authorizations/show.v1.rabl
|
193
|
+
- bin/rails
|
194
|
+
- circle.yml
|
195
|
+
- config/locales/en.yml
|
196
|
+
- config/routes.rb
|
197
|
+
- db/migrate/20140710044402_create_spree_legacy_return_authorizations.rb
|
198
|
+
- lib/generators/solidus_legacy_return_authorizations/install/install_generator.rb
|
199
|
+
- lib/solidus_legacy_return_authorizations.rb
|
200
|
+
- lib/spree_legacy_return_authorizations/engine.rb
|
201
|
+
- lib/spree_legacy_return_authorizations/factories.rb
|
202
|
+
- solidus_legacy_return_authorizations.gemspec
|
203
|
+
- spec/controllers/admin/legacy_return_authorizations_controller_spec.rb
|
204
|
+
- spec/controllers/spree/api/legacy_return_authorizations_controller_spec.rb
|
205
|
+
- spec/features/admin/orders/legacy_return_authorizations_spec.rb
|
206
|
+
- spec/models/spree/legacy_return_authorization_spec.rb
|
207
|
+
- spec/models/spree/permission_sets/legacy_return_authorization_display_spec.rb
|
208
|
+
- spec/models/spree/permission_sets/legacy_return_authorization_management_spec.rb
|
209
|
+
- spec/spec_helper.rb
|
210
|
+
- spec/support/authentication_support.rb
|
211
|
+
- spec/support/have_attributes_matcher.rb
|
212
|
+
homepage:
|
213
|
+
licenses: []
|
214
|
+
metadata: {}
|
215
|
+
post_install_message:
|
216
|
+
rdoc_options: []
|
217
|
+
require_paths:
|
218
|
+
- lib
|
219
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
220
|
+
requirements:
|
221
|
+
- - ">="
|
222
|
+
- !ruby/object:Gem::Version
|
223
|
+
version: '2.1'
|
224
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
225
|
+
requirements:
|
226
|
+
- - ">="
|
227
|
+
- !ruby/object:Gem::Version
|
228
|
+
version: '0'
|
229
|
+
requirements:
|
230
|
+
- none
|
231
|
+
rubyforge_project:
|
232
|
+
rubygems_version: 2.2.5
|
233
|
+
signing_key:
|
234
|
+
specification_version: 4
|
235
|
+
summary: Interfaces for Spree 2.3 Legacy Return Authorizations
|
236
|
+
test_files:
|
237
|
+
- spec/controllers/admin/legacy_return_authorizations_controller_spec.rb
|
238
|
+
- spec/controllers/spree/api/legacy_return_authorizations_controller_spec.rb
|
239
|
+
- spec/features/admin/orders/legacy_return_authorizations_spec.rb
|
240
|
+
- spec/models/spree/legacy_return_authorization_spec.rb
|
241
|
+
- spec/models/spree/permission_sets/legacy_return_authorization_display_spec.rb
|
242
|
+
- spec/models/spree/permission_sets/legacy_return_authorization_management_spec.rb
|
243
|
+
- spec/spec_helper.rb
|
244
|
+
- spec/support/authentication_support.rb
|
245
|
+
- spec/support/have_attributes_matcher.rb
|