solidus_frontend 4.6.3 → 4.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/test.yml +2 -2
- data/Gemfile +1 -1
- data/app/controllers/spree/orders_controller.rb +6 -1
- data/lib/spree/frontend/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 5294035bcb041247624c2b5e25e0ffe1b12e3e3c9ac4f062e5c2f5ab4b5f6700
|
|
4
|
+
data.tar.gz: 893761e7a21db3961bdf924429d362f201bf2e02c7adab47ca5f7c0f72886a7e
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 8395ea1b598f71430ea76f48933640fc919e982a709179ec1a260091e0326455e0a634bd27660aa4115986f42a487212407cc79a031da3e50437b2973bbcd409
|
|
7
|
+
data.tar.gz: f4ed0596aa980976745450b96408618c4d6ff0d9362205f5b0deaa5ab7b157ede1b8e099f3e0670444a72a88f1cb00846c10c8dcbbf4fbef5f26fdc8b400c361
|
data/.github/workflows/test.yml
CHANGED
|
@@ -4,7 +4,7 @@ on:
|
|
|
4
4
|
push:
|
|
5
5
|
branches:
|
|
6
6
|
- main
|
|
7
|
-
- v4.
|
|
7
|
+
- v4.7
|
|
8
8
|
pull_request:
|
|
9
9
|
workflow_dispatch:
|
|
10
10
|
schedule:
|
|
@@ -21,5 +21,5 @@ jobs:
|
|
|
21
21
|
test:
|
|
22
22
|
uses: solidusio/test-solidus-extension/.github/workflows/test.yml@main
|
|
23
23
|
with:
|
|
24
|
-
solidus_branches: '["v4.
|
|
24
|
+
solidus_branches: '["v4.7"]'
|
|
25
25
|
ruby_versions: '["3.2", "3.4"]'
|
data/Gemfile
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
source 'https://rubygems.org'
|
|
4
4
|
|
|
5
|
-
branch = ENV.fetch('SOLIDUS_BRANCH', 'v4.
|
|
5
|
+
branch = ENV.fetch('SOLIDUS_BRANCH', 'v4.7')
|
|
6
6
|
|
|
7
7
|
# The storefront's promotion features build on the legacy promotion
|
|
8
8
|
# system, which lives in the solidus_legacy_promotions gem since Solidus
|
|
@@ -6,13 +6,14 @@ module Spree
|
|
|
6
6
|
|
|
7
7
|
respond_to :html
|
|
8
8
|
|
|
9
|
+
before_action :store_guest_token
|
|
9
10
|
before_action :assign_order, only: :update
|
|
10
11
|
# note: do not lock the #edit action because that's where we redirect when we fail to acquire a lock
|
|
11
12
|
around_action :lock_order, only: :update
|
|
12
13
|
|
|
13
14
|
def show
|
|
14
15
|
@order = Spree::Order.find_by!(number: params[:id])
|
|
15
|
-
authorize! :show, @order,
|
|
16
|
+
authorize! :show, @order, cookies.signed[:guest_token]
|
|
16
17
|
end
|
|
17
18
|
|
|
18
19
|
def update
|
|
@@ -101,6 +102,10 @@ module Spree
|
|
|
101
102
|
|
|
102
103
|
private
|
|
103
104
|
|
|
105
|
+
def store_guest_token
|
|
106
|
+
cookies.permanent.signed[:guest_token] = params[:token] if params[:token]
|
|
107
|
+
end
|
|
108
|
+
|
|
104
109
|
def order_params
|
|
105
110
|
if params[:order]
|
|
106
111
|
params[:order].permit(*permitted_order_attributes)
|