workarea-admin 3.4.42 → 3.4.43
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/controllers/workarea/admin/impersonations_controller.rb +2 -1
- data/app/views/workarea/admin/catalog_categories/edit.html.haml +3 -0
- data/app/views/workarea/admin/users/insights.html.haml +12 -0
- data/config/locales/en.yml +12 -0
- data/test/integration/workarea/admin/impersonations_integration_test.rb +21 -3
- data/test/system/workarea/admin/impersonation_system_test.rb +1 -1
- metadata +6 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 77790287084463abb8d04c359a6d42c242195353e79735b9e09b7661ed37a724
|
4
|
+
data.tar.gz: 15ffda628b192e3cb6f50195142b374d8e67ba1f354cc5110c215a32d263da44
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4a6ad1147f3584866134b8ff83e3228fa15f9e8fa96c48557100fa996f6ba09b5bd9d48985fd31049a40c648fbd4ba653a2590a4881dbf25908981ca27751d43
|
7
|
+
data.tar.gz: 7f2f2d7940d4901d35f3274bab3b26e93aec4530c48544d214e9e0dc8c41474d2f8ae81a7b9978d06672844f34c5aea8ed2546b6c527278f18a926ea6c5b8abb
|
@@ -27,7 +27,8 @@ module Workarea
|
|
27
27
|
self.current_order = nil
|
28
28
|
|
29
29
|
flash[:success] = t('workarea.admin.users.flash_messages.stopped')
|
30
|
-
|
30
|
+
referrer = URI.parse(request.referrer).request_uri rescue nil
|
31
|
+
redirect_back_or(referrer.presence || user_path(previous_user_id))
|
31
32
|
end
|
32
33
|
end
|
33
34
|
end
|
@@ -60,6 +60,9 @@
|
|
60
60
|
.property
|
61
61
|
= label_tag 'category_default_sort', t('workarea.admin.fields.default_sort'), class: 'property__name'
|
62
62
|
= select_tag 'category[default_sort]', options_for_select(@category.sort_options, selected: @category.default_sort)
|
63
|
+
- if @category.featured_products?
|
64
|
+
%span.property__note
|
65
|
+
= t('workarea.admin.catalog_categories.edit.default_sort_note')
|
63
66
|
|
64
67
|
.property
|
65
68
|
= label_tag 'category_terms_facets_list', t('workarea.admin.fields.terms_facets_list'), class: 'property__name'
|
@@ -90,6 +90,18 @@
|
|
90
90
|
= @user.insights.average_order_value_percentile.ordinalize
|
91
91
|
= t('workarea.admin.users.insights.percentile')
|
92
92
|
|
93
|
+
.align-center
|
94
|
+
= link_to '#customer-insights-info', data: { tooltip: { side: 'bottom', interactive: true } } do
|
95
|
+
= t('workarea.admin.users.insights.customer_insights')
|
96
|
+
#customer-insights-info.tooltip-content.align-center
|
97
|
+
= t( |
|
98
|
+
'workarea.admin.users.insights.customer_insights_info_html', |
|
99
|
+
best_customers_path: insights_report_path(type: Workarea::Insights::BestCustomers), |
|
100
|
+
customers_at_risk_path: insights_report_path(type: Workarea::Insights::CustomersAtRisk), |
|
101
|
+
repeat_purchase_rate_path: insights_report_path(type: Workarea::Insights::RepeatPurchaseRate), |
|
102
|
+
orders_path: orders_user_path(@user) |
|
103
|
+
) |
|
104
|
+
|
93
105
|
.section
|
94
106
|
%h2.align-center= t('workarea.admin.users.insights.recently_viewed.title')
|
95
107
|
.grid.grid--center
|
data/config/locales/en.yml
CHANGED
@@ -286,6 +286,7 @@ en:
|
|
286
286
|
views: views
|
287
287
|
edit:
|
288
288
|
client_id_note: Identifies the category for product import
|
289
|
+
default_sort_note: 'Since this category has featured products, this sort controls the products listed after the selected featured products.'
|
289
290
|
filters_note_html: 'Comma separated: just, like, this. If these fields are blank, the global values will be used from %{search_settings_link}.'
|
290
291
|
page_title: Attributes for %{category}
|
291
292
|
search_settings: search settings
|
@@ -3553,6 +3554,17 @@ en:
|
|
3553
3554
|
aov: AOV
|
3554
3555
|
insights_for_this_customer: Insights for this Customer
|
3555
3556
|
percentile: percentile
|
3557
|
+
customer_insights: Wondering about how Workarea customer insights work?
|
3558
|
+
customer_insights_info_html: >
|
3559
|
+
<strong>How are customer metrics tracked?</strong>
|
3560
|
+
<p>Workarea's metrics engine saves reporting and insights data based on the customer's email address.
|
3561
|
+
This allows for the best tracking of customers for generating helpful insights like
|
3562
|
+
<a href="%{best_customers_path}">Best Customers</a>, <a href="%{customers_at_risk_path}">Customers at Risk</a>,
|
3563
|
+
and <a href="%{repeat_purchase_rate_path}">Repeat Purchase Rate</a> as accurately as possible across both
|
3564
|
+
guest and account checkouts.</p>
|
3565
|
+
<strong>Wondering why some numbers don't line up?</strong>
|
3566
|
+
<p>Because reporting is tracked by email address, changes in email address and/or having an account
|
3567
|
+
can cause mismatch between the <a href="%{orders_path}">Orders</a> card and these insights.</p>
|
3556
3568
|
login:
|
3557
3569
|
never: Never logged in
|
3558
3570
|
time_ago: "%{period} ago"
|
@@ -70,17 +70,35 @@ module Workarea
|
|
70
70
|
post admin.impersonations_path, params: { user_id: @user.id }
|
71
71
|
delete admin.impersonations_path
|
72
72
|
|
73
|
-
assert_redirected_to(admin.user_path(@user.id))
|
74
73
|
assert_equal(previous_user_id, response_cookies['user_id'])
|
75
74
|
assert(session['admin_id'].blank?)
|
76
75
|
|
77
76
|
post admin.impersonations_path, params: { user_id: @user.id }
|
78
|
-
delete admin.impersonations_path
|
77
|
+
delete admin.impersonations_path
|
79
78
|
|
80
|
-
assert_redirected_to('/foo')
|
81
79
|
assert_equal(previous_user_id, response_cookies['user_id'])
|
82
80
|
assert(session['admin_id'].blank?)
|
83
81
|
end
|
82
|
+
|
83
|
+
def test_redirection_after_destroy
|
84
|
+
post admin.impersonations_path, params: { user_id: @user.id }
|
85
|
+
delete admin.impersonations_path
|
86
|
+
assert_redirected_to(admin.user_path(@user.id))
|
87
|
+
|
88
|
+
post admin.impersonations_path, params: { user_id: @user.id }
|
89
|
+
delete admin.impersonations_path(return_to: '/foo')
|
90
|
+
assert_redirected_to('/foo')
|
91
|
+
|
92
|
+
post admin.impersonations_path, params: { user_id: @user.id }
|
93
|
+
delete admin.impersonations_path(return_to: '/foo'),
|
94
|
+
headers: { 'HTTP_REFERER' => admin.catalog_products_path }
|
95
|
+
assert_redirected_to('/foo')
|
96
|
+
|
97
|
+
post admin.impersonations_path, params: { user_id: @user.id }
|
98
|
+
delete admin.impersonations_path,
|
99
|
+
headers: { 'HTTP_REFERER' => admin.catalog_products_url(host: 'foo.com') }
|
100
|
+
assert_redirected_to(admin.catalog_products_path)
|
101
|
+
end
|
84
102
|
end
|
85
103
|
end
|
86
104
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: workarea-admin
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.4.
|
4
|
+
version: 3.4.43
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ben Crouse
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-11-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: workarea-core
|
@@ -16,28 +16,28 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - '='
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 3.4.
|
19
|
+
version: 3.4.43
|
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: 3.4.
|
26
|
+
version: 3.4.43
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: workarea-storefront
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
31
|
- - '='
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: 3.4.
|
33
|
+
version: 3.4.43
|
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: 3.4.
|
40
|
+
version: 3.4.43
|
41
41
|
description: Provides site administration functionality for the Workarea Commerce
|
42
42
|
Platform.
|
43
43
|
email:
|