solidus_multi_domain 1.0.3 → 1.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +1 -1
- data/app/models/spree/store_decorator.rb +0 -3
- data/config/locales/en.yml +0 -1
- data/solidus_multi_domain.gemspec +2 -2
- metadata +13 -13
- data/app/models/spree/order_decorator.rb +0 -5
- data/app/models/spree/payment_method_decorator.rb +0 -13
- data/app/models/spree/store_payment_method.rb +0 -6
- data/db/migrate/20121210224018_add_store_payment_methods.rb +0 -10
- data/spec/models/spree/payment_method_spec.rb +0 -33
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 098985ec80349cc626444c51ed5dc087f24e3c45
|
4
|
+
data.tar.gz: 183006f5dd4b9df940748cad1bd00668bdb2eb53
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: daa7ec76b99e1692175da20803924bcb01f5f97a353a5a9fe8430ef7e70fe844651ff6c3be56f79cc74901a5fcdfb280bbd51dd7e88b44f4a1b213fa4c92fcb5
|
7
|
+
data.tar.gz: e2464782a80ab6a0aecefcd75ffdbd80151419bc2e4f549bcd664b0f6f286fbbc75e94b86886c8a9a2fab6e692628c876703ac02d4828039d9dc8d037c52b4cc
|
data/Gemfile
CHANGED
data/config/locales/en.yml
CHANGED
@@ -6,7 +6,6 @@ en:
|
|
6
6
|
products_from_different_stores_may_not_be_added_to_this_order: Products from different stores may not be added to this order.
|
7
7
|
send_mail_as: Send Mail As
|
8
8
|
logo: Logo
|
9
|
-
payment_method: Payment Method
|
10
9
|
shipping_method: Shipping Method
|
11
10
|
store: Store
|
12
11
|
stores: Stores
|
@@ -3,7 +3,7 @@
|
|
3
3
|
Gem::Specification.new do |s|
|
4
4
|
s.platform = Gem::Platform::RUBY
|
5
5
|
s.name = "solidus_multi_domain"
|
6
|
-
s.version = "1.0
|
6
|
+
s.version = "1.1.0"
|
7
7
|
s.summary = "Adds multiple site support to Solidus"
|
8
8
|
s.description = "Multiple Solidus stores on different domains - single unified backed for processing orders."
|
9
9
|
s.required_ruby_version = ">= 2.1"
|
@@ -18,7 +18,7 @@ Gem::Specification.new do |s|
|
|
18
18
|
s.require_path = "lib"
|
19
19
|
s.requirements << "none"
|
20
20
|
|
21
|
-
s.add_dependency "solidus", "
|
21
|
+
s.add_dependency "solidus", [">= 1.1.0.pre", "< 2"]
|
22
22
|
|
23
23
|
s.add_development_dependency "rspec-rails", "~> 3.2"
|
24
24
|
s.add_development_dependency "simplecov"
|
metadata
CHANGED
@@ -1,29 +1,35 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: solidus_multi_domain
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0
|
4
|
+
version: 1.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Solidus Team
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-08-
|
11
|
+
date: 2015-08-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: solidus
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- - "
|
17
|
+
- - ">="
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: 1.1.0.pre
|
20
|
+
- - "<"
|
18
21
|
- !ruby/object:Gem::Version
|
19
|
-
version:
|
22
|
+
version: '2'
|
20
23
|
type: :runtime
|
21
24
|
prerelease: false
|
22
25
|
version_requirements: !ruby/object:Gem::Requirement
|
23
26
|
requirements:
|
24
|
-
- - "
|
27
|
+
- - ">="
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
version: 1.1.0.pre
|
30
|
+
- - "<"
|
25
31
|
- !ruby/object:Gem::Version
|
26
|
-
version:
|
32
|
+
version: '2'
|
27
33
|
- !ruby/object:Gem::Dependency
|
28
34
|
name: rspec-rails
|
29
35
|
requirement: !ruby/object:Gem::Requirement
|
@@ -161,15 +167,12 @@ files:
|
|
161
167
|
- app/controllers/spree/taxons_controller_decorator.rb
|
162
168
|
- app/helpers/spree/products_helper_decorator.rb
|
163
169
|
- app/models/spree/line_item_decorator.rb
|
164
|
-
- app/models/spree/order_decorator.rb
|
165
|
-
- app/models/spree/payment_method_decorator.rb
|
166
170
|
- app/models/spree/permission_sets/store_display.rb
|
167
171
|
- app/models/spree/permission_sets/store_management.rb
|
168
172
|
- app/models/spree/product_decorator.rb
|
169
173
|
- app/models/spree/promotion/rules/store.rb
|
170
174
|
- app/models/spree/shipping_method_decorator.rb
|
171
175
|
- app/models/spree/store_decorator.rb
|
172
|
-
- app/models/spree/store_payment_method.rb
|
173
176
|
- app/models/spree/store_shipping_method.rb
|
174
177
|
- app/models/spree/taxon_decorator.rb
|
175
178
|
- app/models/spree/taxonomy_decorator.rb
|
@@ -208,7 +211,6 @@ files:
|
|
208
211
|
- db/migrate/20110601125650_remove_datetime_columns_from_products_stores.rb
|
209
212
|
- db/migrate/20110601145424_add_indexes_to_products_stores.rb
|
210
213
|
- db/migrate/20120223183401_namespace.rb
|
211
|
-
- db/migrate/20121210224018_add_store_payment_methods.rb
|
212
214
|
- db/migrate/20130308084714_add_logo_to_stores.rb
|
213
215
|
- db/migrate/20130325231147_add_store_shipping_methods.rb
|
214
216
|
- db/migrate/20130412212659_add_spree_promotion_rules_stores.rb
|
@@ -233,7 +235,6 @@ files:
|
|
233
235
|
- spec/helpers/products_helper_decorator_spec.rb
|
234
236
|
- spec/models/spree/line_item_spec.rb
|
235
237
|
- spec/models/spree/order_spec.rb
|
236
|
-
- spec/models/spree/payment_method_spec.rb
|
237
238
|
- spec/models/spree/permission_sets/store_display_spec.rb
|
238
239
|
- spec/models/spree/permission_sets/store_management_spec.rb
|
239
240
|
- spec/models/spree/product_spec.rb
|
@@ -266,7 +267,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
266
267
|
requirements:
|
267
268
|
- none
|
268
269
|
rubyforge_project:
|
269
|
-
rubygems_version: 2.2.
|
270
|
+
rubygems_version: 2.2.3
|
270
271
|
signing_key:
|
271
272
|
specification_version: 4
|
272
273
|
summary: Adds multiple site support to Solidus
|
@@ -280,7 +281,6 @@ test_files:
|
|
280
281
|
- spec/helpers/products_helper_decorator_spec.rb
|
281
282
|
- spec/models/spree/line_item_spec.rb
|
282
283
|
- spec/models/spree/order_spec.rb
|
283
|
-
- spec/models/spree/payment_method_spec.rb
|
284
284
|
- spec/models/spree/permission_sets/store_display_spec.rb
|
285
285
|
- spec/models/spree/permission_sets/store_management_spec.rb
|
286
286
|
- spec/models/spree/product_spec.rb
|
@@ -1,13 +0,0 @@
|
|
1
|
-
Spree::PaymentMethod.class_eval do
|
2
|
-
has_many :store_payment_methods
|
3
|
-
has_many :stores, :through => :store_payment_methods
|
4
|
-
|
5
|
-
def self.available(display_on = 'both', store = nil)
|
6
|
-
result = all.select do |p|
|
7
|
-
p.active &&
|
8
|
-
(p.environment == Rails.env || p.environment.blank?) &&
|
9
|
-
(store.nil? || store.payment_methods.empty? || store.payment_methods.include?(p)) &&
|
10
|
-
(p.display_on == display_on.to_s || p.display_on.blank?)
|
11
|
-
end
|
12
|
-
end
|
13
|
-
end
|
@@ -1,33 +0,0 @@
|
|
1
|
-
require 'spec_helper'
|
2
|
-
|
3
|
-
describe 'PaymentMethod' do
|
4
|
-
describe '.available' do
|
5
|
-
subject { Spree::PaymentMethod.available(:front_end, store) }
|
6
|
-
|
7
|
-
let!(:check_payment_method) { FactoryGirl.create :check_payment_method }
|
8
|
-
let(:payment_method_store) { FactoryGirl.create :store, :payment_methods => [check_payment_method] }
|
9
|
-
|
10
|
-
context "when store is not specified" do
|
11
|
-
let(:store) { nil }
|
12
|
-
|
13
|
-
it { is_expected.to include(check_payment_method) }
|
14
|
-
end
|
15
|
-
|
16
|
-
context "when store is specified" do
|
17
|
-
let(:store) { payment_method_store }
|
18
|
-
|
19
|
-
context "when store has payment methods" do
|
20
|
-
let(:non_matching_check_payment_method) { FactoryGirl.create :check_payment_method }
|
21
|
-
|
22
|
-
it { is_expected.to include(check_payment_method) }
|
23
|
-
it { is_expected.not_to include(non_matching_check_payment_method) }
|
24
|
-
end
|
25
|
-
|
26
|
-
context "when store does not have payment_methods" do
|
27
|
-
let(:payment_method_store) { FactoryGirl.create :store }
|
28
|
-
|
29
|
-
it { is_expected.to include(check_payment_method) }
|
30
|
-
end
|
31
|
-
end
|
32
|
-
end
|
33
|
-
end
|