thecore_ui_rails_admin 2.3.6 → 2.4.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/javascripts/thecore_ui_rails_admin/thecore_rails_admin.js +0 -1
- data/app/assets/stylesheets/thecore_ui_rails_admin/thecore_rails_admin.scss +2 -2
- data/app/views/layouts/rails_admin/application.html.haml +2 -2
- data/config/initializers/thecore_concern.rb +14 -5
- data/lib/thecore_ui_rails_admin.rb +1 -1
- metadata +2 -16
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1279d70dc26563abf8d3f1df0f0e42e9914517904e3ba6fe15a9767ef3e1ec39
|
4
|
+
data.tar.gz: 713d6d14978afe9a9c5bbcf1340c0f37124dc03ea3f982526129b89bb207fe79
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9deccd904b0c45249cf22d6f3857f579011600472e1a0de3eff8ce3bb3364c6a4ffbc87b12cef0c941531ecf77f055499f8f19650f1ec5f0adbb3f44d8b6419f
|
7
|
+
data.tar.gz: b627897bceb05749e8b7a775ff4094f5931f29b32c7192c5b6211f883f9bc04817e78662b5724abef059d963e3aebe7c6e1225ce450a58e094f5129aff52b887
|
@@ -138,9 +138,9 @@ body.rails_admin .nav.nav-tabs {
|
|
138
138
|
.content {
|
139
139
|
margin: 0px 0 15px 0;
|
140
140
|
padding: 8px;
|
141
|
-
background:
|
141
|
+
background: transparent;
|
142
142
|
&.dashboard {
|
143
|
-
background:
|
143
|
+
background: transparent;
|
144
144
|
}
|
145
145
|
.page-header {
|
146
146
|
display: none;
|
@@ -23,8 +23,8 @@
|
|
23
23
|
%body.rails_admin
|
24
24
|
#admin-js{:'data-i18n-options' => I18n.t("admin.js").to_json}
|
25
25
|
-# Initialize JS simple i18n
|
26
|
-
:javascript
|
27
|
-
|
26
|
+
-# :javascript
|
27
|
+
-# RailsAdmin.I18n.init('#{I18n.locale}', document.getElementById("admin-js").dataset.i18nOptions);
|
28
28
|
#loading.label.label-warning{style: 'display:none; position:fixed; right:20px; bottom:20px; z-index:100000'}= t('admin.loading')
|
29
29
|
-# %nav.navbar.navbar-default.navbar-fixed-top
|
30
30
|
-# = render "layouts/rails_admin/navigation"
|
@@ -9,7 +9,7 @@ module ThecoreConcern
|
|
9
9
|
layout 'thecore'
|
10
10
|
protect_from_forgery with: :exception, prepend: true
|
11
11
|
rescue_from CanCan::AccessDenied do |exception|
|
12
|
-
redirect_to main_app.root_url, :
|
12
|
+
redirect_to main_app.root_url, alert: exception.message
|
13
13
|
end
|
14
14
|
include HttpAcceptLanguage::AutoLocale
|
15
15
|
before_action :store_user_location!, if: :storable_location?
|
@@ -33,17 +33,22 @@ module ThecoreConcern
|
|
33
33
|
action = root_actions.collect(&:action_name).first
|
34
34
|
# REDIRECT TO THAT ACTION
|
35
35
|
|
36
|
-
|
37
|
-
|
36
|
+
Rails.logger.info "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA: Checking redirect path"
|
37
|
+
stored_location = stored_location_for(resource)
|
38
|
+
if !stored_location.blank? && can?(resource, :all)
|
39
|
+
Rails.logger.info "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA: Checking redirect path: I'm in the IF stored_location_for(resource): #{stored_location}"
|
40
|
+
return stored_location
|
38
41
|
elsif action
|
42
|
+
Rails.logger.info "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA: Checking redirect path: I'm in the ELSIF with action name: #{action}"
|
39
43
|
return rails_admin.send("#{action}_path").sub("#{ENV['RAILS_RELATIVE_URL_ROOT']}#{ENV['RAILS_RELATIVE_URL_ROOT']}", "#{ENV['RAILS_RELATIVE_URL_ROOT']}")
|
40
44
|
else
|
45
|
+
Rails.logger.info "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA: Checking redirect path: I'm in the ELSE with root_path: #{root_path}"
|
41
46
|
sign_out current_user
|
42
47
|
user_session = nil
|
43
48
|
current_user = nil
|
44
49
|
flash[:alert] = "Your user is not authorized to access any page."
|
45
50
|
flash[:notice] = nil
|
46
|
-
return
|
51
|
+
return root_path
|
47
52
|
end
|
48
53
|
end
|
49
54
|
end
|
@@ -100,7 +105,9 @@ module ThecoreConcern
|
|
100
105
|
|
101
106
|
# Auto-sign out locked users
|
102
107
|
def reject_locked!
|
103
|
-
|
108
|
+
Rails.logger.info "BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB reject_locked"
|
109
|
+
if !current_user.blank? && current_user.locked?
|
110
|
+
Rails.logger.info "BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB is locked"
|
104
111
|
sign_out current_user
|
105
112
|
user_session = nil
|
106
113
|
current_user = nil
|
@@ -108,7 +115,9 @@ module ThecoreConcern
|
|
108
115
|
flash[:notice] = nil
|
109
116
|
redirect_to root_url
|
110
117
|
end
|
118
|
+
Rails.logger.info "BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB is not locked = ok"
|
111
119
|
end
|
120
|
+
|
112
121
|
|
113
122
|
# Only permits admin users
|
114
123
|
def require_admin!
|
@@ -11,7 +11,7 @@ require 'concerns/rails_admin_requirements'
|
|
11
11
|
# Abilities
|
12
12
|
require 'abilities/thecore_ui_rails_admin'
|
13
13
|
# Rails Admin Buildups
|
14
|
-
require 'jquery-ui-rails'
|
14
|
+
# require 'jquery-ui-rails'
|
15
15
|
require 'bootstrap-sass'
|
16
16
|
|
17
17
|
require 'concerns/thecore_ui_rails_admin_user'
|
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: 2.
|
4
|
+
version: 2.4.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gabriele Tassoni
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-07-
|
11
|
+
date: 2021-07-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: thecore_ui_commons
|
@@ -136,20 +136,6 @@ dependencies:
|
|
136
136
|
- - "~>"
|
137
137
|
- !ruby/object:Gem::Version
|
138
138
|
version: '2.0'
|
139
|
-
- !ruby/object:Gem::Dependency
|
140
|
-
name: jquery-ui-rails
|
141
|
-
requirement: !ruby/object:Gem::Requirement
|
142
|
-
requirements:
|
143
|
-
- - "~>"
|
144
|
-
- !ruby/object:Gem::Version
|
145
|
-
version: '6.0'
|
146
|
-
type: :runtime
|
147
|
-
prerelease: false
|
148
|
-
version_requirements: !ruby/object:Gem::Requirement
|
149
|
-
requirements:
|
150
|
-
- - "~>"
|
151
|
-
- !ruby/object:Gem::Version
|
152
|
-
version: '6.0'
|
153
139
|
description: Holds all base dependencies and configurations to have a thecore integrated
|
154
140
|
with Rails Admin.
|
155
141
|
email:
|