spree_backend 4.6.0 → 4.6.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +3 -3
- data/app/assets/javascripts/spree/backend/global/tinymce.es6 +2 -2
- data/app/controllers/concerns/spree/admin/translatable.rb +10 -7
- data/app/views/spree/admin/dashboard/_getting_started.html.erb +1 -0
- data/app/views/spree/admin/oauth_applications/index.html.erb +7 -0
- data/app/views/spree/admin/webhooks_subscribers/index.html.erb +11 -0
- data/config/locales/en.yml +4 -1
- data/lib/spree/backend/version.rb +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f6a727db968502ab5d08a7733adecdf3d46a1657218745d63a0896b72d6c0480
|
4
|
+
data.tar.gz: 660d8c18a9e4f401cd72321f7b68503dc0f3784e50eda8e123f0e5ee9cf18d76
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a7d89b1b4411316a3727d36b349f07789ce4eb07e36be7dfa7d046a8becb2acd7dad8439fc7206ca47fd4e834db7a947ef2b8a4c2ade7dbecd17e38e72e8a9b8
|
7
|
+
data.tar.gz: 3cf8f6c96eaef38994f05a137ddcf5cefadb9403b3582dee37fa360c3c868649622b9cc9e56586e31bec9ca97855aff03e9fbe18da23774848de9df91ad77077
|
data/Gemfile
CHANGED
@@ -23,7 +23,7 @@ end
|
|
23
23
|
|
24
24
|
group :test do
|
25
25
|
gem 'tinymce-rails'
|
26
|
-
gem 'capybara', '~> 3.
|
26
|
+
gem 'capybara', '~> 3.39'
|
27
27
|
gem 'capybara-screenshot', '~> 1.0'
|
28
28
|
gem 'capybara-select-2'
|
29
29
|
gem 'database_cleaner', '~> 2.0'
|
@@ -50,7 +50,7 @@ group :test, :development do
|
|
50
50
|
gem 'rubocop', '~> 1.48.1', require: false # bumped
|
51
51
|
gem 'rubocop-rspec', require: false
|
52
52
|
gem 'pry-byebug'
|
53
|
-
gem 'webdrivers', '~>
|
53
|
+
gem 'webdrivers', '~> 5.3'
|
54
54
|
# Puma 6.0 causes issues in specs due to conflict with capybara version
|
55
55
|
gem 'puma', '< 6.0'
|
56
56
|
gem 'ffaker'
|
@@ -62,7 +62,7 @@ group :development do
|
|
62
62
|
end
|
63
63
|
|
64
64
|
|
65
|
-
spree_opts = { github: 'spree/spree', branch: '
|
65
|
+
spree_opts = { github: 'spree/spree', branch: '4-6-stable' }
|
66
66
|
gem 'spree_core', spree_opts
|
67
67
|
gem 'spree_api', spree_opts
|
68
68
|
# Last version that supports Ruby 2.7
|
@@ -4,7 +4,7 @@ document.addEventListener("spree:load", function() {
|
|
4
4
|
tinymce.init({
|
5
5
|
selector: '.spree-rte',
|
6
6
|
plugins: [
|
7
|
-
'image table paste code link table'
|
7
|
+
'image table paste code link table lists'
|
8
8
|
],
|
9
9
|
menubar: false,
|
10
10
|
toolbar: 'undo redo | styleselect | bold italic link forecolor backcolor | alignleft aligncenter alignright alignjustify | table | bullist numlist outdent indent | code '
|
@@ -14,7 +14,7 @@ document.addEventListener("spree:load", function() {
|
|
14
14
|
selector: '.spree-rte-simple',
|
15
15
|
menubar: false,
|
16
16
|
plugins: [
|
17
|
-
'image table paste link table'
|
17
|
+
'image table paste link table lists'
|
18
18
|
],
|
19
19
|
toolbar: 'undo redo | styleselect | bold italic link forecolor backcolor | alignleft aligncenter alignright alignjustify | table | bullist numlist outdent indent'
|
20
20
|
});
|
@@ -13,15 +13,18 @@ module Spree
|
|
13
13
|
private
|
14
14
|
|
15
15
|
def save_translation_values
|
16
|
-
translation_params = params[:translation]
|
16
|
+
translation_params = params[:translation].permit!.to_h
|
17
17
|
|
18
|
-
current_store.supported_locales_list
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
18
|
+
current_store_locales = current_store.supported_locales_list
|
19
|
+
params_locales = translation_params.flat_map { |_attribute, translations| translations.compact_blank.keys }
|
20
|
+
locales_to_update = current_store_locales & params_locales
|
21
|
+
|
22
|
+
locales_to_update.each do |locale|
|
23
|
+
translation = @object.translations.find_or_initialize_by(locale: locale)
|
24
|
+
translation_params.each do |attribute, translations|
|
25
|
+
translation.public_send("#{attribute}=", translations[locale])
|
24
26
|
end
|
27
|
+
translation.save!
|
25
28
|
end
|
26
29
|
end
|
27
30
|
end
|
@@ -45,6 +45,7 @@
|
|
45
45
|
<% else %>
|
46
46
|
<p>
|
47
47
|
<%= Spree.t('admin.gettting_started.products_section.message_without_products') %>
|
48
|
+
<%= link_to(Spree.t('admin.gettting_started.products_section.import_message'), 'https://api.spreecommerce.org/docs/api-v2/27527143a4edf-create-a-product') %>
|
48
49
|
</p>
|
49
50
|
<%= link_to_with_icon 'add.svg', Spree.t('admin.gettting_started.add_products'), spree.admin_products_path, class: 'btn btn-success btn-sm mb-2' %>
|
50
51
|
<% end %>
|
@@ -6,6 +6,13 @@
|
|
6
6
|
<%= button_link_to Spree.t('admin.oauth_applications.new'), new_object_url, class: "btn-success", icon: 'add.svg', id: 'admin_new_role_link' %>
|
7
7
|
<% end if can? :create, Spree::OauthApplication %>
|
8
8
|
|
9
|
+
<div class="card bg-light">
|
10
|
+
<div class="card-body">
|
11
|
+
<%=Spree.t('admin.oauth_applications.documentation_message')%>
|
12
|
+
<%= link_to(Spree.t('admin.oauth_applications.documentation_cta'), 'https://dev-docs.spreecommerce.org/api/platform-api/authenticating-requests')%>
|
13
|
+
</div>
|
14
|
+
</div>
|
15
|
+
|
9
16
|
<% if @oauth_applications.any? %>
|
10
17
|
<div class="table-responsive rounded border mt-4">
|
11
18
|
<table class="table">
|
@@ -15,6 +15,7 @@
|
|
15
15
|
<% if defined?(Spree::Vendor) && can?(:manage, Spree::Vendor) && !current_spree_vendor %>
|
16
16
|
<th><%= Spree.t(:vendor) %></th>
|
17
17
|
<% end %>
|
18
|
+
<th><%= Spree.t('admin.webhooks_subscribers.secret_key') %></th>
|
18
19
|
<th><%= Spree.t('admin.active') %></th>
|
19
20
|
<th><%= Spree.t('admin.webhooks_subscribers.subscriptions') %></th>
|
20
21
|
<th><%= Spree.t('admin.webhooks_subscribers.time_of_last_event') %></th>
|
@@ -31,6 +32,16 @@
|
|
31
32
|
<%= link_to webhooks_subscriber.vendor.name, spree.admin_vendor_path(webhooks_subscriber.vendor) if webhooks_subscriber.vendor.present? %>
|
32
33
|
</td>
|
33
34
|
<% end %>
|
35
|
+
<td>
|
36
|
+
<div class="input-group" data-controller="password-toggle">
|
37
|
+
<%= password_field_tag :password, webhooks_subscriber.secret_key, class: 'form-control unhide text-muted border-0 shadow-none bg-transparent', data: { password_toggle_target: 'unhide' }, readonly: true %>
|
38
|
+
<div class="input-group-append">
|
39
|
+
<%= button_tag class: 'btn btn-link rounded', data: { action: 'click->password-toggle#password' } do %>
|
40
|
+
<%= svg_icon name: "view.svg", width: '18', height: '18' %>
|
41
|
+
<% end %>
|
42
|
+
</div>
|
43
|
+
</div>
|
44
|
+
</td>
|
34
45
|
<td><%= active_badge(webhooks_subscriber.active) %></td>
|
35
46
|
<td><%= webhooks_subscriber.subscriptions&.sort&.join(', ') %></td>
|
36
47
|
<td><%= webhooks_subscriber.events.order(:created_at).last&.created_at %></td>
|
data/config/locales/en.yml
CHANGED
@@ -167,6 +167,8 @@ en:
|
|
167
167
|
new: New oAuth application
|
168
168
|
uid: UID
|
169
169
|
scopes: Scopes
|
170
|
+
documentation_message: 'To learn how to authenticate requests to the Platform API, '
|
171
|
+
documentation_cta: see the documentation
|
170
172
|
reports:
|
171
173
|
for: For %{store_name}
|
172
174
|
return_authorization:
|
@@ -324,7 +326,8 @@ en:
|
|
324
326
|
setup_taxes_calculation: Setup tax calculation
|
325
327
|
products_section:
|
326
328
|
message_with_products_html: You have added <strong> %{count} products</strong> so far - good job!</p>
|
327
|
-
message_without_products: You can add products manually
|
329
|
+
message_without_products: You can add products manually or
|
330
|
+
import_message: import them via the API.
|
328
331
|
shipping_section:
|
329
332
|
message_with_shipping: You have setup shipping for
|
330
333
|
message_without_shipping: You can add multiple shipping methods, different for each country, continent or region.
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: spree_backend
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.6.
|
4
|
+
version: 4.6.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sean Schofield
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2024-01-05 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: spree
|
@@ -2427,9 +2427,9 @@ licenses:
|
|
2427
2427
|
- BSD-3-Clause
|
2428
2428
|
metadata:
|
2429
2429
|
bug_tracker_uri: https://github.com/spree/spree_backend/issues
|
2430
|
-
changelog_uri: https://github.com/spree/spree_backend/releases/tag/v4.6.
|
2430
|
+
changelog_uri: https://github.com/spree/spree_backend/releases/tag/v4.6.2
|
2431
2431
|
documentation_uri: https://dev-docs.spreecommerce.org/
|
2432
|
-
source_code_uri: https://github.com/spree/spree_backend/tree/v4.6.
|
2432
|
+
source_code_uri: https://github.com/spree/spree_backend/tree/v4.6.2
|
2433
2433
|
post_install_message:
|
2434
2434
|
rdoc_options: []
|
2435
2435
|
require_paths:
|