solidus_frontend 2.1.1 → 2.2.0.beta1
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of solidus_frontend might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/Gemfile +1 -0
- data/README.md +30 -0
- data/app/assets/config/solidus_frontend_manifest.js +6 -0
- data/app/assets/javascripts/spree/frontend/checkout/coupon-code.js.coffee +2 -2
- data/app/assets/javascripts/spree/frontend/checkout.js.coffee +8 -0
- data/app/assets/stylesheets/spree/frontend/screen.css.scss +18 -7
- data/app/controllers/spree/checkout_controller.rb +63 -21
- data/app/controllers/spree/orders_controller.rb +2 -2
- data/app/controllers/spree/products_controller.rb +2 -2
- data/app/controllers/spree/store_controller.rb +1 -1
- data/app/controllers/spree/taxons_controller.rb +1 -1
- data/app/models/spree/frontend_configuration.rb +3 -0
- data/app/views/spree/address/_form.html.erb +2 -2
- data/app/views/spree/checkout/_address.html.erb +4 -4
- data/app/views/spree/checkout/_confirm.html.erb +15 -2
- data/app/views/spree/checkout/_delivery.html.erb +2 -2
- data/app/views/spree/checkout/_payment.html.erb +14 -14
- data/app/views/spree/checkout/_terms_and_conditions.en.html.erb +1 -0
- data/app/views/spree/checkout/edit.html.erb +4 -4
- data/app/views/spree/checkout/existing_payment/_gateway.html.erb +9 -0
- data/app/views/spree/checkout/payment/_gateway.html.erb +8 -8
- data/app/views/spree/home/index.html.erb +2 -2
- data/app/views/spree/layouts/spree_application.html.erb +4 -4
- data/app/views/spree/orders/_adjustment_row.html.erb +1 -1
- data/app/views/spree/orders/_adjustments.html.erb +3 -3
- data/app/views/spree/orders/_form.html.erb +7 -6
- data/app/views/spree/orders/_line_item.html.erb +2 -2
- data/app/views/spree/orders/edit.html.erb +9 -9
- data/app/views/spree/orders/show.html.erb +4 -4
- data/app/views/spree/products/_cart_form.html.erb +3 -3
- data/app/views/spree/products/_properties.html.erb +1 -1
- data/app/views/spree/products/index.html.erb +4 -4
- data/app/views/spree/products/show.html.erb +6 -6
- data/app/views/spree/shared/_filters.html.erb +2 -2
- data/app/views/spree/shared/_head.html.erb +1 -1
- data/app/views/spree/shared/_header.html.erb +2 -2
- data/app/views/spree/shared/_main_nav_bar.html.erb +2 -2
- data/app/views/spree/shared/_nav_bar.html.erb +1 -1
- data/app/views/spree/shared/_order_details.html.erb +7 -7
- data/app/views/spree/shared/_search.html.erb +4 -4
- data/app/views/spree/shared/_taxonomies.html.erb +1 -1
- data/config/initializers/assets.rb +1 -8
- data/config/routes.rb +1 -1
- data/lib/generators/solidus/views/override_generator.rb +46 -0
- data/spec/controllers/spree/checkout_controller_spec.rb +5 -52
- data/spec/controllers/spree/orders_controller_spec.rb +3 -3
- data/spec/controllers/spree/orders_controller_transitions_spec.rb +1 -1
- data/spec/features/caching/products_spec.rb +0 -1
- data/spec/features/caching/taxons_spec.rb +0 -1
- data/spec/features/checkout_spec.rb +4 -3
- data/spec/generators/solidus/views/override_generator_spec.rb +47 -0
- metadata +12 -7
@@ -0,0 +1,47 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
require_relative '../../../../lib/generators/solidus/views/override_generator'
|
3
|
+
|
4
|
+
RSpec.describe Solidus::Views::OverrideGenerator, type: :generator do
|
5
|
+
destination Rails.root.join('app', 'views', 'spree')
|
6
|
+
|
7
|
+
before(:all) do
|
8
|
+
prepare_destination
|
9
|
+
end
|
10
|
+
|
11
|
+
subject! do
|
12
|
+
run_generator arguments
|
13
|
+
end
|
14
|
+
|
15
|
+
let(:src) do
|
16
|
+
Spree::Frontend::Engine.root.join('app', 'views', 'spree')
|
17
|
+
end
|
18
|
+
|
19
|
+
let(:dest) do
|
20
|
+
Rails.root.join('app', 'views', 'spree')
|
21
|
+
end
|
22
|
+
|
23
|
+
context 'without any arguments' do
|
24
|
+
let(:arguments) { %w() }
|
25
|
+
|
26
|
+
it 'copies all views into the host app' do
|
27
|
+
expect(src.entries).to match_array(dest.entries)
|
28
|
+
end
|
29
|
+
end
|
30
|
+
|
31
|
+
context 'when "products" is passed as --only argument' do
|
32
|
+
let(:arguments) { %w(--only products) }
|
33
|
+
|
34
|
+
context 'as folder' do
|
35
|
+
it 'exclusively copies views whose name contains "products"' do
|
36
|
+
Dir.glob(dest.join("**", "*")).each do |file|
|
37
|
+
next if File.directory?(file)
|
38
|
+
expect(file.to_s).to match("products")
|
39
|
+
end
|
40
|
+
end
|
41
|
+
end
|
42
|
+
end
|
43
|
+
|
44
|
+
after do
|
45
|
+
FileUtils.rm_rf destination_root
|
46
|
+
end
|
47
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: solidus_frontend
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.2.0.beta1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Solidus Team
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-04-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: solidus_api
|
@@ -16,28 +16,28 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - '='
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 2.
|
19
|
+
version: 2.2.0.beta1
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - '='
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: 2.
|
26
|
+
version: 2.2.0.beta1
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: solidus_core
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
31
|
- - '='
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: 2.
|
33
|
+
version: 2.2.0.beta1
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - '='
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: 2.
|
40
|
+
version: 2.2.0.beta1
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: canonical-rails
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -132,6 +132,7 @@ files:
|
|
132
132
|
- LICENSE
|
133
133
|
- README.md
|
134
134
|
- Rakefile
|
135
|
+
- app/assets/config/solidus_frontend_manifest.js
|
135
136
|
- app/assets/images/credit_cards/amex_cid.gif
|
136
137
|
- app/assets/images/credit_cards/credit_card.gif
|
137
138
|
- app/assets/images/credit_cards/discover_cid.gif
|
@@ -188,7 +189,9 @@ files:
|
|
188
189
|
- app/views/spree/checkout/_delivery.html.erb
|
189
190
|
- app/views/spree/checkout/_payment.html.erb
|
190
191
|
- app/views/spree/checkout/_summary.html.erb
|
192
|
+
- app/views/spree/checkout/_terms_and_conditions.en.html.erb
|
191
193
|
- app/views/spree/checkout/edit.html.erb
|
194
|
+
- app/views/spree/checkout/existing_payment/_gateway.html.erb
|
192
195
|
- app/views/spree/checkout/payment/_check.html.erb
|
193
196
|
- app/views/spree/checkout/payment/_gateway.html.erb
|
194
197
|
- app/views/spree/content/cvv.html.erb
|
@@ -230,6 +233,7 @@ files:
|
|
230
233
|
- config/initializers/assets.rb
|
231
234
|
- config/initializers/canonical_rails.rb
|
232
235
|
- config/routes.rb
|
236
|
+
- lib/generators/solidus/views/override_generator.rb
|
233
237
|
- lib/solidus_frontend.rb
|
234
238
|
- lib/spree/frontend.rb
|
235
239
|
- lib/spree/frontend/engine.rb
|
@@ -269,6 +273,7 @@ files:
|
|
269
273
|
- spec/features/taxons_spec.rb
|
270
274
|
- spec/features/template_rendering_spec.rb
|
271
275
|
- spec/fixtures/thinking-cat.jpg
|
276
|
+
- spec/generators/solidus/views/override_generator_spec.rb
|
272
277
|
- spec/helpers/base_helper_spec.rb
|
273
278
|
- spec/spec_helper.rb
|
274
279
|
- spec/support/shared_contexts/checkout_setup.rb
|
@@ -345,7 +350,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
345
350
|
requirements:
|
346
351
|
- none
|
347
352
|
rubyforge_project:
|
348
|
-
rubygems_version: 2.6.
|
353
|
+
rubygems_version: 2.6.10
|
349
354
|
signing_key:
|
350
355
|
specification_version: 4
|
351
356
|
summary: Cart and storefront for the Solidus e-commerce project.
|