lesli_admin 1.1.2 → 1.1.3
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/app/controllers/lesli_admin/dashboards_controller.rb +0 -15
- data/app/models/lesli_admin/dashboard.rb +4 -6
- data/app/views/lesli_admin/dashboards/_component-account-metadata.html.erb +3 -0
- data/app/views/lesli_admin/dashboards/_component-installed-engines.html.erb +3 -0
- data/app/views/lesli_admin/dashboards/_component-roles.html.erb +3 -0
- data/app/views/lesli_admin/dashboards/_component-users.html.erb +3 -0
- data/config/locales/translations.en.yml +10 -1
- data/config/locales/translations.es.yml +10 -1
- data/config/locales/translations.fr.yml +2 -1
- data/config/locales/translations.it.yml +2 -1
- data/config/locales/translations.pt.yml +2 -1
- data/lib/lesli_admin/version.rb +2 -2
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: a0836e1e00903a513f98f3cbb117f98195cc7605189cc864b607f2ac2e4d0449
|
|
4
|
+
data.tar.gz: 7c030c6ba6ab3450378b9faf644346fba233e2743424bf96fbd961436ac847bc
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 0fa2b729e658af3c7945ac6dc3b1b6f75924e905ba10b6bea9b6aea9b549c2d853d327bbc54c0777c904ef615139e743e6256e14f48b160aff64944542867906
|
|
7
|
+
data.tar.gz: 55d3a90049f8295d68c6e2cb43950abc808466e52edb7e1dfefc13796bff54a703f356b567741c3e8e8a76cb7bfc415d4ad5bf0e03974b906c2c4404ad0372f4
|
|
@@ -33,25 +33,10 @@ Building a better future, one line of code at a time.
|
|
|
33
33
|
module LesliAdmin
|
|
34
34
|
class DashboardsController < Lesli::Shared::DashboardsController
|
|
35
35
|
def show
|
|
36
|
-
@account_summary = AccountService.new(current_user, query).summary
|
|
37
|
-
|
|
38
|
-
synchronize_dashboard_components if defined?(LesliDashboard)
|
|
39
|
-
|
|
40
36
|
return super if defined?(LesliDashboard)
|
|
41
37
|
|
|
42
38
|
render :show
|
|
43
39
|
end
|
|
44
40
|
|
|
45
|
-
private
|
|
46
|
-
|
|
47
|
-
def synchronize_dashboard_components
|
|
48
|
-
dashboard_account = current_user.account.dashboard
|
|
49
|
-
return unless dashboard_account
|
|
50
|
-
|
|
51
|
-
LesliDashboard::DashboardService.new(current_user).register(dashboard_account)
|
|
52
|
-
|
|
53
|
-
dashboard = dashboard_account.dashboards.find_by(engine: "LesliAdmin")
|
|
54
|
-
dashboard&.components&.where(component: Dashboard::RETIRED_COMPONENTS)&.destroy_all
|
|
55
|
-
end
|
|
56
41
|
end
|
|
57
42
|
end
|
|
@@ -32,13 +32,11 @@ Building a better future, one line of code at a time.
|
|
|
32
32
|
|
|
33
33
|
module LesliAdmin
|
|
34
34
|
class Dashboard < Lesli::Shared::Dashboard
|
|
35
|
-
RETIRED_COMPONENTS = %w[locations currencies settings].freeze
|
|
36
|
-
|
|
37
35
|
COMPONENTS = [
|
|
38
|
-
{ users: { size: 4, position:
|
|
39
|
-
{ roles: { size: 4, position:
|
|
40
|
-
{ installed_engines: { size: 4, position:
|
|
41
|
-
{ account_metadata: { size: 12, position:
|
|
36
|
+
{ users: { size: 4, position: 2 } },
|
|
37
|
+
{ roles: { size: 4, position: 3 } },
|
|
38
|
+
{ installed_engines: { size: 4, position: 4 } },
|
|
39
|
+
{ account_metadata: { size: 12, position: 1 } }
|
|
42
40
|
].freeze
|
|
43
41
|
end
|
|
44
42
|
end
|
data/lib/lesli_admin/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: lesli_admin
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.1.
|
|
4
|
+
version: 1.1.3
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- The Lesli Development Team
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-
|
|
11
|
+
date: 2026-11-16 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: lesli
|