thecore_ui_rails_admin 3.0.18 → 3.0.19

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 5efac1012ef290f5f973be7861420b1e7914a576a348ac6cfab2037bb3deb1ff
4
- data.tar.gz: 3115e6b705d010a7dff478d2d0f8644fc971e9bcae4cea25077a05e9379d9fd6
3
+ metadata.gz: 1e483927bcfef24e0c9f5d48923ee241aca2980ecf1ea9bdc6130dbd0e683406
4
+ data.tar.gz: da29456ecee758fea45205532a52abca5ea97f1bedb7002639c4bbff0f881b73
5
5
  SHA512:
6
- metadata.gz: 9b5e809fe078edf927236381def6fb128cafd76cdd7c10c7ac4760054447f92a21f9e9aacb6118b098154180a89b6342615ab9491018f53dc0f843842f91c04c
7
- data.tar.gz: 0ecd2a172a1e4ad607670646ab8c711dbb649b920fd0d899e4d5f9571bd5d7e47fe85f36d7c0e37b3375a74397c2d7796ddf18d9216f9f3acbb2372dc544e256
6
+ metadata.gz: a35ffaecc2492c3c0c43fba3b57044224fde8163ffea558db1020ba64599919862de397ed96ec49ddd2c21405665970661548bd5a77852c594023d4b62eb7770
7
+ data.tar.gz: 930fe0d19ec346a234594cc0af0dfe47271edd31af845eba1a23148df8c005881d2a224ec573aed64b1614b722da9d6f84a6e3961e5c4536ded7bce1ffba80e5
@@ -4,9 +4,9 @@ module Abilities
4
4
  def initialize user
5
5
  # No one is allowed to add or destroy settings
6
6
  # just list or edit existing
7
- cannot :create, ThecoreSettings::Setting
8
- cannot :destroy, ThecoreSettings::Setting
9
- cannot :show, ThecoreSettings::Setting
7
+ cannot [:create, :destroy, :show], ThecoreSettings::Setting
8
+
9
+ cannot [:destroy, :update, :edit, :show], Action
10
10
  # Main abilities file for Thecore applications
11
11
  if user.present?
12
12
  # Users' abilities
@@ -26,12 +26,12 @@ Rails.application.configure do
26
26
  RailsAdmin::Config.excluded_models << ActiveStorage::VariantRecord
27
27
  RailsAdmin::Config.excluded_models << ActionMailbox::InboundEmail
28
28
  RailsAdmin::Config.excluded_models << UsedToken rescue puts "No UsedToken Model it could be normal: maybe model_driven_api is not installed"
29
- RailsAdmin::Config.excluded_models << RoleUser
30
- RailsAdmin::Config.excluded_models << Predicate
31
- RailsAdmin::Config.excluded_models << Target
32
- RailsAdmin::Config.excluded_models << Action
33
- RailsAdmin::Config.excluded_models << PermissionRole
34
- RailsAdmin::Config.excluded_models << Permission
29
+ # RailsAdmin::Config.excluded_models << RoleUser
30
+ # RailsAdmin::Config.excluded_models << Predicate
31
+ # RailsAdmin::Config.excluded_models << Target
32
+ # RailsAdmin::Config.excluded_models << Action
33
+ # RailsAdmin::Config.excluded_models << PermissionRole
34
+ # RailsAdmin::Config.excluded_models << Permission
35
35
 
36
36
  RailsAdmin::Config::Actions.add_action "active_job_monitor", :base, :root do
37
37
  show_in_sidebar true
@@ -62,6 +62,12 @@ Rails.application.configure do
62
62
  RailsAdmin::Config::Actions::BulkDelete.send(:include, BulkDeleteConcern)
63
63
  Role.send :include, ThecoreUiRailsAdminRoleConcern
64
64
  User.send :include, ThecoreUiRailsAdminUserConcern
65
+ RoleUser.send :include, ThecoreUiRailsAdminRoleUserConcern
66
+ Action.send :include, ThecoreUiRailsAdminActionConcern
67
+ PermissionRole.send :include, ThecoreUiRailsAdminPermissionRoleConcern
68
+ Permission.send :include, ThecoreUiRailsAdminPermissionConcern
69
+ Predicate.send :include, ThecoreUiRailsAdminPredicateConcern
70
+ Target.send :include, ThecoreUiRailsAdminTargetConcern
65
71
  ThecoreSettings::Setting.send :include, ThecoreUiRailsAdminSettingsConcern
66
72
  end
67
73
  end
@@ -0,0 +1,19 @@
1
+ puts "Role Concern from ThecoreUiRailsAdmin"
2
+ require 'active_support/concern'
3
+
4
+ module ThecoreUiRailsAdminActionConcern
5
+ extend ActiveSupport::Concern
6
+
7
+ included do
8
+
9
+ rails_admin do
10
+ navigation_label I18n.t("admin.settings.label")
11
+ navigation_icon 'fas fa-users'
12
+ desc I18n.t("activerecord.descriptions.role")
13
+
14
+ visible false
15
+
16
+ exclude_fields :id, :lock_version, :updated_at
17
+ end
18
+ end
19
+ end
@@ -0,0 +1,19 @@
1
+ puts "Role Concern from ThecoreUiRailsAdmin"
2
+ require 'active_support/concern'
3
+
4
+ module ThecoreUiRailsAdminPermissionConcern
5
+ extend ActiveSupport::Concern
6
+
7
+ included do
8
+
9
+ rails_admin do
10
+ navigation_label I18n.t("admin.settings.label")
11
+ navigation_icon 'fas fa-users'
12
+ desc I18n.t("activerecord.descriptions.role")
13
+
14
+ visible false
15
+
16
+ exclude_fields :id, :lock_version, :updated_at, :permission_roles, :roles
17
+ end
18
+ end
19
+ end
@@ -0,0 +1,17 @@
1
+ puts "Role Concern from ThecoreUiRailsAdmin"
2
+ require 'active_support/concern'
3
+
4
+ module ThecoreUiRailsAdminPermissionRoleConcern
5
+ extend ActiveSupport::Concern
6
+
7
+ included do
8
+
9
+ rails_admin do
10
+ navigation_label I18n.t("admin.settings.label")
11
+ navigation_icon 'fas fa-users'
12
+ desc I18n.t("activerecord.descriptions.role")
13
+
14
+ visible false
15
+ end
16
+ end
17
+ end
@@ -0,0 +1,19 @@
1
+ puts "Role Concern from ThecoreUiRailsAdmin"
2
+ require 'active_support/concern'
3
+
4
+ module ThecoreUiRailsAdminPredicateConcern
5
+ extend ActiveSupport::Concern
6
+
7
+ included do
8
+
9
+ rails_admin do
10
+ navigation_label I18n.t("admin.settings.label")
11
+ navigation_icon 'fas fa-users'
12
+ desc I18n.t("activerecord.descriptions.role")
13
+
14
+ visible false
15
+
16
+ exclude_fields :id, :lock_version, :updated_at
17
+ end
18
+ end
19
+ end
@@ -12,7 +12,7 @@ module ThecoreUiRailsAdminRoleConcern
12
12
  desc I18n.t("activerecord.descriptions.role")
13
13
 
14
14
  field :name
15
- field :permissions#, :selectize
15
+ field :permissions
16
16
 
17
17
  list do
18
18
  field :created_at
@@ -0,0 +1,17 @@
1
+ puts "Role Concern from ThecoreUiRailsAdmin"
2
+ require 'active_support/concern'
3
+
4
+ module ThecoreUiRailsAdminRoleUserConcern
5
+ extend ActiveSupport::Concern
6
+
7
+ included do
8
+
9
+ rails_admin do
10
+ navigation_label I18n.t("admin.settings.label")
11
+ navigation_icon 'fas fa-users'
12
+ desc I18n.t("activerecord.descriptions.role")
13
+
14
+ visible false
15
+ end
16
+ end
17
+ end
@@ -0,0 +1,19 @@
1
+ puts "Role Concern from ThecoreUiRailsAdmin"
2
+ require 'active_support/concern'
3
+
4
+ module ThecoreUiRailsAdminTargetConcern
5
+ extend ActiveSupport::Concern
6
+
7
+ included do
8
+
9
+ rails_admin do
10
+ navigation_label I18n.t("admin.settings.label")
11
+ navigation_icon 'fas fa-users'
12
+ desc I18n.t("activerecord.descriptions.role")
13
+
14
+ visible false
15
+
16
+ exclude_fields :id, :lock_version, :updated_at
17
+ end
18
+ end
19
+ end
@@ -2,9 +2,9 @@ en:
2
2
  admin:
3
3
  actions:
4
4
  active_job_monitor:
5
- menu: Worker Monitor
6
- title: Worker Monitor
7
- breadcrumb: Worker Monitor
5
+ menu: Async Worker Monitor
6
+ title: Async Worker Monitor
7
+ breadcrumb: Async Worker Monitor
8
8
  misc:
9
9
  scopes: Fast Filters
10
10
  scopes:
@@ -6,8 +6,8 @@ it:
6
6
  index:
7
7
  no_records: Nessun record da mostrare
8
8
  active_job_monitor:
9
- menu: Worker Monitor
10
- title: Worker Monitor
11
- breadcrumb: Worker Monitor
9
+ menu: Async Worker Monitor
10
+ title: Async Worker Monitor
11
+ breadcrumb: Async Worker Monitor
12
12
  scopes:
13
13
  _all: Tutti
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: thecore_ui_rails_admin
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.18
4
+ version: 3.0.19
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gabriele Tassoni
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-02-20 00:00:00.000000000 Z
11
+ date: 2023-03-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: thecore_ui_commons
@@ -84,10 +84,16 @@ files:
84
84
  - config/initializers/add_to_db_migrations.rb
85
85
  - config/initializers/after_initialize.rb
86
86
  - config/initializers/assets.rb
87
+ - config/initializers/concern_action.rb
87
88
  - config/initializers/concern_bulk_delete.rb
88
89
  - config/initializers/concern_export.rb
90
+ - config/initializers/concern_permission.rb
91
+ - config/initializers/concern_permission_role.rb
92
+ - config/initializers/concern_predicate.rb
89
93
  - config/initializers/concern_role.rb
94
+ - config/initializers/concern_role_user.rb
90
95
  - config/initializers/concern_settings.rb
96
+ - config/initializers/concern_target.rb
91
97
  - config/initializers/concern_user.rb
92
98
  - config/locales/en.index_cards.custom.yml
93
99
  - config/locales/en.main.yml