thecore_ui_rails_admin 2.7.7 → 3.0.0
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/rails_admin/custom/thecore/ui.js +1 -0
- data/app/assets/javascripts/rails_admin/custom/ui.js +6 -9
- data/app/assets/stylesheets/rails_admin/custom/mixins.scss +15 -0
- data/app/assets/stylesheets/rails_admin/custom/thecore/mixins.scss +1 -0
- data/app/assets/stylesheets/rails_admin/custom/thecore/theming.scss +23 -0
- data/app/assets/stylesheets/rails_admin/custom/thecore/variables.scss +1 -0
- data/app/assets/stylesheets/rails_admin/custom/theming.scss +11 -147
- data/app/assets/stylesheets/rails_admin/custom/variables.scss.erb +85 -0
- data/app/views/layouts/_navigation.html.erb +20 -0
- data/app/views/layouts/_navigation_links.html.erb +7 -0
- data/app/views/rails_admin/main/{thecore_sidekiq_monitor.html.erb → active_job_monitor.html.erb} +1 -1
- data/{lib/concerns → config/initializers}/thecore_rails_admin_bulk_delete_concern.rb +0 -0
- data/{lib/concerns → config/initializers}/thecore_rails_admin_export_concern.rb +0 -0
- data/{lib/abilities/thecore_ui_rails_admin.rb → config/initializers/thecore_ui_rails_admin_abilities.rb} +0 -0
- data/config/initializers/thecore_ui_rails_admin_after_initialize.rb +71 -0
- data/config/initializers/thecore_ui_rails_admin_app_configs.rb +0 -12
- data/config/initializers/thecore_ui_rails_admin_assets.rb +9 -0
- data/config/initializers/{thecore_concern.rb → thecore_ui_rails_admin_concern.rb} +3 -3
- data/{lib/concerns/thecore_ui_rails_admin_used_token.rb → config/initializers/thecore_ui_rails_admin_invisible_models_concern.rb} +2 -2
- data/{lib/concerns → config/initializers}/thecore_ui_rails_admin_role.rb +2 -2
- data/config/initializers/thecore_ui_rails_admin_settings_concern.rb +14 -0
- data/{lib/concerns/thecore_ui_rails_admin_user.rb → config/initializers/thecore_ui_rails_admin_user_concern.rb} +2 -1
- data/config/locales/en.index_cards.custom.yml +8 -0
- data/config/locales/en.main.yml +5 -40
- data/config/locales/en.rails_admin.yml +6 -0
- data/config/locales/it.index_cards.custom.yml +20 -0
- data/config/locales/it.main.yml +0 -4
- data/config/locales/it.rails_admin.yml +9 -30
- data/config/routes.rb +3 -4
- data/lib/thecore_ui_rails_admin/engine.rb +1 -0
- data/lib/thecore_ui_rails_admin/version.rb +1 -1
- data/lib/thecore_ui_rails_admin.rb +0 -27
- metadata +34 -94
- data/app/assets/javascripts/rails_admin/custom/thecore-custom-1.js +0 -1
- data/app/assets/javascripts/rails_admin/custom/thecore-custom-2.js +0 -1
- data/app/assets/javascripts/rails_admin/custom/thecore-custom-3.js +0 -1
- data/app/assets/javascripts/rails_admin/custom/thecore-custom-4.js +0 -1
- data/app/assets/javascripts/rails_admin/custom/thecore-custom-5.js +0 -1
- data/app/assets/javascripts/rails_admin/custom/thecore.js +0 -1
- data/app/assets/javascripts/thecore_ui_rails_admin/thecore_rails_admin.js +0 -77
- data/app/assets/stylesheets/rails_admin/custom/theming-custom-1.scss +0 -1
- data/app/assets/stylesheets/rails_admin/custom/theming-custom-2.scss +0 -1
- data/app/assets/stylesheets/rails_admin/custom/theming-custom-3.scss +0 -1
- data/app/assets/stylesheets/rails_admin/custom/theming-custom-4.scss +0 -1
- data/app/assets/stylesheets/rails_admin/custom/theming-custom-5.scss +0 -1
- data/app/assets/stylesheets/rails_admin/custom/variables.scss +0 -21
- data/app/assets/stylesheets/thecore_ui_rails_admin/animate.css +0 -3458
- data/app/assets/stylesheets/thecore_ui_rails_admin/apexcharts.scss +0 -7
- data/app/assets/stylesheets/thecore_ui_rails_admin/common.scss +0 -43
- data/app/assets/stylesheets/thecore_ui_rails_admin/devise.scss +0 -241
- data/app/assets/stylesheets/thecore_ui_rails_admin/flashing.scss +0 -28
- data/app/assets/stylesheets/thecore_ui_rails_admin/mixins.scss +0 -18
- data/app/assets/stylesheets/thecore_ui_rails_admin/thecore.scss +0 -45
- data/app/assets/stylesheets/thecore_ui_rails_admin/thecore_rails_admin.scss +0 -243
- data/app/assets/stylesheets/thecore_ui_rails_admin/togglable-sidebar.scss +0 -89
- data/app/views/rails_admin/main/thecore_blazer_bi.html.erb +0 -5
- data/app/views/shared/_flash.html.erb +0 -10
- data/config/blazer.yml +0 -79
- data/config/initializers/rails_admin.rb +0 -105
- data/config/initializers/thecore_ui_rails_admin_load_root_actions_for.rb +0 -6
- data/lib/concerns/rails_admin_requirements.rb +0 -19
- data/lib/concerns/thecore_ui_rails_admin_permission.rb +0 -33
- data/lib/iframes/blazer_bi.rb +0 -59
- data/lib/iframes/sidekiq_monitor.rb +0 -59
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ec8dc0eac44b2163ed615efe0800fca6b01f6f297be48b2df497db68830776a2
|
4
|
+
data.tar.gz: d0ead922cdfec3199ca35225aabaa685432d66c724a99ce8cc6e2adb17b24672
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b764ecb0e7aaa61d2023cfe2f2ecbb75b4448801c01c5cca84fe19a0916ab6a7bc16f0d259a30378059b413a121f7fc3966abcea014f3f4672762c1e18b62b09
|
7
|
+
data.tar.gz: ccbc1873291ba6a620e0e74bec3b925b0524320d934aca0ec1b63022cbc0a2592e4b85ea58a10fbd07edf1e6250f2d113018fe2876a93898224ebf6f6784b3bd
|
@@ -0,0 +1 @@
|
|
1
|
+
// override this file in your thecore based application to add custom behaviour
|
@@ -1,11 +1,6 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
//= require rails_admin/custom/thecore-custom-1
|
5
|
-
//= require rails_admin/custom/thecore-custom-2
|
6
|
-
//= require rails_admin/custom/thecore-custom-3
|
7
|
-
//= require rails_admin/custom/thecore-custom-4
|
8
|
-
//= require rails_admin/custom/thecore-custom-5
|
1
|
+
// override this file in your application to add custom behaviour
|
2
|
+
|
3
|
+
console.log("Thecore UI Rails Admin")
|
9
4
|
|
10
5
|
function hideBreadCrumbAndToolbar() {
|
11
6
|
// If the page loaded has a tag like <span class="hide-breadcrumb hide-toolbar"></span>
|
@@ -30,4 +25,6 @@ function adjustIframe(obj) {
|
|
30
25
|
|
31
26
|
// Re evaluate at each iteraction
|
32
27
|
$(document).off('ready pjax:success', hideBreadCrumbAndToolbar);
|
33
|
-
$(document).on('ready pjax:success', hideBreadCrumbAndToolbar);
|
28
|
+
$(document).on('ready pjax:success', hideBreadCrumbAndToolbar);
|
29
|
+
|
30
|
+
//= require 'rails_admin/custom/thecore/ui'
|
@@ -0,0 +1,15 @@
|
|
1
|
+
/*
|
2
|
+
Customize Sass mixins from Twitter-Bootstrap/RailsAdmin theme or add new ones for your own use.
|
3
|
+
Copy this file to your app/assets/rails_admin/custom/mixins.scss, leave this one untouched
|
4
|
+
Don't require it in your application.rb
|
5
|
+
|
6
|
+
Available mixins to use/override:
|
7
|
+
|
8
|
+
https://github.com/twbs/bootstrap-sass/tree/master/assets/stylesheets/bootstrap/mixins
|
9
|
+
https://github.com/railsadminteam/rails_admin/blob/master/src/rails_admin/styles/base/mixins.scss
|
10
|
+
Plus the ones from your theme.
|
11
|
+
*/
|
12
|
+
|
13
|
+
/* Thecore Mixins */
|
14
|
+
|
15
|
+
@import 'thecore/mixins';
|
@@ -0,0 +1 @@
|
|
1
|
+
// Override this file in your Thcore based application to add specific styles
|
@@ -0,0 +1,23 @@
|
|
1
|
+
// Override this file in your Thcore based application to add specific styles
|
2
|
+
.alert {
|
3
|
+
position: absolute;
|
4
|
+
bottom: 1em !important;
|
5
|
+
top: auto !important;
|
6
|
+
right: 2.5em !important;
|
7
|
+
width: auto !important;
|
8
|
+
z-index: 9999 !important;
|
9
|
+
border-radius: 2em !important;
|
10
|
+
animation: hideMe 5s 1;
|
11
|
+
animation-fill-mode: forwards;
|
12
|
+
animation-delay: 2s;
|
13
|
+
}
|
14
|
+
|
15
|
+
@keyframes hideMe {
|
16
|
+
0% {
|
17
|
+
opacity: 1;
|
18
|
+
}
|
19
|
+
|
20
|
+
100% {
|
21
|
+
opacity: 0;
|
22
|
+
}
|
23
|
+
}
|
@@ -0,0 +1 @@
|
|
1
|
+
// Override this file in your Thcore based application to add specific styles
|
@@ -1,153 +1,17 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
@import 'rails_admin/custom/theming-custom-2';
|
6
|
-
@import 'rails_admin/custom/theming-custom-3';
|
7
|
-
@import 'rails_admin/custom/theming-custom-4';
|
8
|
-
@import 'rails_admin/custom/theming-custom-5';
|
1
|
+
/*
|
2
|
+
Customize RailsAdmin theme here.
|
3
|
+
Copy this file to your app/assets/stylesheets/rails_admin/custom/theming.scss, leave this one untouched
|
4
|
+
Don't require it in your application.rb
|
9
5
|
|
10
|
-
|
11
|
-
background-color: $shadows !important;
|
6
|
+
Look at the markup in RailsAdmin and go there to get inspiration from:
|
12
7
|
|
13
|
-
|
8
|
+
http://getbootstrap.com
|
14
9
|
|
15
|
-
|
10
|
+
Test me: (actual color should be the one defined in variables.scss if you did)
|
16
11
|
|
17
|
-
|
18
|
-
|
19
|
-
padding-right: .5em !important;
|
20
|
-
color: white !important;
|
21
|
-
}
|
22
|
-
}
|
23
|
-
}
|
12
|
+
body { background-color: $link-color; }
|
13
|
+
*/
|
24
14
|
|
25
|
-
|
26
|
-
padding: 6px 15px 6px 25px !important;
|
15
|
+
/* Thecore Theming */
|
27
16
|
|
28
|
-
|
29
|
-
&:focus {
|
30
|
-
background-color: $text !important;
|
31
|
-
}
|
32
|
-
}
|
33
|
-
|
34
|
-
body {
|
35
|
-
background-color: $background !important;
|
36
|
-
}
|
37
|
-
|
38
|
-
.navbar-default {
|
39
|
-
background-color: $background !important;
|
40
|
-
border-color: $background !important;
|
41
|
-
|
42
|
-
.navbar-brand {
|
43
|
-
color: $primary !important;
|
44
|
-
font-weight: bold;
|
45
|
-
text-transform: uppercase;
|
46
|
-
font-size: 2em;
|
47
|
-
}
|
48
|
-
|
49
|
-
}
|
50
|
-
|
51
|
-
.content {
|
52
|
-
padding-right: 1em;
|
53
|
-
padding-left: 1em;
|
54
|
-
}
|
55
|
-
|
56
|
-
// .form-control.selectize-control {
|
57
|
-
// width: 62%;
|
58
|
-
// }
|
59
|
-
|
60
|
-
#secondary-navigation .navbar-nav li {
|
61
|
-
display: none;
|
62
|
-
|
63
|
-
&:nth-last-of-type(2),
|
64
|
-
&:last-of-type {
|
65
|
-
display: block !important;
|
66
|
-
}
|
67
|
-
}
|
68
|
-
|
69
|
-
#list form .well {
|
70
|
-
background-color: transparent;
|
71
|
-
border: none;
|
72
|
-
-webkit-box-shadow: none;
|
73
|
-
box-shadow: none;
|
74
|
-
}
|
75
|
-
|
76
|
-
.row {
|
77
|
-
margin-left: 0 !important;
|
78
|
-
margin-right: 0 !important;
|
79
|
-
}
|
80
|
-
|
81
|
-
.pagination>li>a,
|
82
|
-
.pagination>li>span,
|
83
|
-
a {
|
84
|
-
color: $primary;
|
85
|
-
}
|
86
|
-
|
87
|
-
.pagination>.active>a,
|
88
|
-
.pagination>.active>a:hover,
|
89
|
-
.pagination>.active>a:focus,
|
90
|
-
.pagination>.active>span,
|
91
|
-
.pagination>.active>span:hover,
|
92
|
-
.pagination>.active>span:focus,
|
93
|
-
.btn-primary {
|
94
|
-
color: $background;
|
95
|
-
background-color: $primary;
|
96
|
-
border-color: $primary;
|
97
|
-
}
|
98
|
-
|
99
|
-
.btn-primary:hover {
|
100
|
-
background-color: $text;
|
101
|
-
border-color: $text;
|
102
|
-
}
|
103
|
-
|
104
|
-
.btn-info {
|
105
|
-
color: $background;
|
106
|
-
background-color: $shadows;
|
107
|
-
border-color: $shadows;
|
108
|
-
&:hover {
|
109
|
-
background-color: $primary;
|
110
|
-
}
|
111
|
-
}
|
112
|
-
|
113
|
-
.open > .btn-info.dropdown-toggle {
|
114
|
-
color: $background;
|
115
|
-
background-color: darken($shadows, 10%);
|
116
|
-
border-color: darken($shadows, 10%);
|
117
|
-
}
|
118
|
-
|
119
|
-
.btn-info.disabled, .btn-info.disabled:hover, .btn-info.disabled:focus, .btn-info.disabled:active, .btn-info.disabled.active, .btn-info[disabled], .btn-info[disabled]:hover, .btn-info[disabled]:focus, .btn-info[disabled]:active, .btn-info.active[disabled], fieldset[disabled] .btn-info, fieldset[disabled] .btn-info:hover, fieldset[disabled] .btn-info:focus, fieldset[disabled] .btn-info:active, fieldset[disabled] .btn-info.active {
|
120
|
-
background-color: lighten($shadows, 30%);
|
121
|
-
border-color: lighten($shadows, 30%);
|
122
|
-
}
|
123
|
-
|
124
|
-
li a .label-danger {
|
125
|
-
background-color: $primary;
|
126
|
-
margin-right: 1em;
|
127
|
-
}
|
128
|
-
|
129
|
-
.breadcrumb {
|
130
|
-
// margin-top: 1em;
|
131
|
-
// margin-bottom: 2.5em;
|
132
|
-
background-color: $primary;
|
133
|
-
text-transform: uppercase;
|
134
|
-
color: $background !important;
|
135
|
-
border-radius: 2em;
|
136
|
-
}
|
137
|
-
|
138
|
-
.breadcrumb .active, .breadcrumb .active:before {
|
139
|
-
color: $background !important;
|
140
|
-
}
|
141
|
-
|
142
|
-
.breadcrumb .false a, .breadcrumb .false:before {
|
143
|
-
color: white !important;
|
144
|
-
}
|
145
|
-
|
146
|
-
#fields_to_export .form-group {
|
147
|
-
margin-left: 0;
|
148
|
-
margin-right: 0;
|
149
|
-
}
|
150
|
-
|
151
|
-
// .input-group {
|
152
|
-
// display: block;
|
153
|
-
// }
|
17
|
+
@import 'thecore/theming';
|
@@ -0,0 +1,85 @@
|
|
1
|
+
/*
|
2
|
+
Customize Sass variables from Twitter-Bootstrap/RailsAdmin theme or add new ones for your own use.
|
3
|
+
Copy this file to your app/assets/rails_admin/custom/variables.scss, leave this one untouched
|
4
|
+
Don't require it in your application.rb
|
5
|
+
|
6
|
+
Available variables to use/override:
|
7
|
+
|
8
|
+
https://github.com/twbs/bootstrap-sass/blob/master/assets/stylesheets/bootstrap/_variables.scss
|
9
|
+
https://github.com/railsadminteam/rails_admin/blob/master/src/rails_admin/styles/base/variables.scss
|
10
|
+
Plus the ones from your themes.
|
11
|
+
|
12
|
+
Test me: pink links
|
13
|
+
|
14
|
+
$link-color: #F0F;
|
15
|
+
*/
|
16
|
+
<%
|
17
|
+
@text_color = Settings.ns(:theme).text_color
|
18
|
+
@accents_color = Settings.ns(:theme).accents_color
|
19
|
+
@background_color = Settings.ns(:theme).background_color
|
20
|
+
@main_color = Settings.ns(:theme).main_color
|
21
|
+
@shadows_color = Settings.ns(:theme).shadows_color
|
22
|
+
|
23
|
+
@neutral_color = Settings.ns(:theme).neutral_color
|
24
|
+
@success_color = Settings.ns(:theme).success_color
|
25
|
+
@info_color = Settings.ns(:theme).info_color
|
26
|
+
@danger_color = Settings.ns(:theme).danger_color
|
27
|
+
@warning_color = Settings.ns(:theme).warning_color
|
28
|
+
%>
|
29
|
+
/* Thecore Variables */
|
30
|
+
//== Colors
|
31
|
+
//
|
32
|
+
//## Gray and brand colors for use across Bootstrap.
|
33
|
+
|
34
|
+
$gray-base: <%=@neutral_color%> !default;
|
35
|
+
$gray-darker: lighten($gray-base, 13.5%) !default; // #222
|
36
|
+
$gray-dark: lighten($gray-base, 20%) !default; // #333
|
37
|
+
$gray: lighten($gray-base, 33.5%) !default; // #555
|
38
|
+
$gray-light: lighten($gray-base, 46.7%) !default; // #777
|
39
|
+
$gray-lighter: lighten($gray-base, 93.5%) !default; // #eee
|
40
|
+
|
41
|
+
$brand-primary: darken(<%=@main_color%>, 6.5%) !default; // #337ab7
|
42
|
+
$brand-success: <%=@success_color%> !default;
|
43
|
+
$brand-info: <%=@info_color%> !default;
|
44
|
+
$brand-warning: <%=@warning_color%> !default;
|
45
|
+
$brand-danger: <%=@danger_color%> !default;
|
46
|
+
|
47
|
+
|
48
|
+
//== Scaffolding
|
49
|
+
//
|
50
|
+
//## Settings for some of the most global styles.
|
51
|
+
|
52
|
+
//** Background color for `<body>`.
|
53
|
+
$body-bg: #fff !default;
|
54
|
+
//** Global text color on `<body>`.
|
55
|
+
$text-color: $gray-dark !default;
|
56
|
+
|
57
|
+
//** Global textual link color.
|
58
|
+
$link-color: $brand-primary !default;
|
59
|
+
//** Link hover color set via `darken()` function.
|
60
|
+
$link-hover-color: darken($link-color, 15%) !default;
|
61
|
+
//** Link hover decoration.
|
62
|
+
$link-hover-decoration: underline !default;
|
63
|
+
|
64
|
+
nav.bg-primary {
|
65
|
+
background-color: $brand-primary !important;
|
66
|
+
}
|
67
|
+
|
68
|
+
body.rails_admin .sidebar.btn-toggle-nav .btn-toggle-nav > li > a {
|
69
|
+
&:hover, &.active {
|
70
|
+
background-color: $brand-primary !important;
|
71
|
+
}
|
72
|
+
}
|
73
|
+
|
74
|
+
.btn-primary {
|
75
|
+
background-color: $brand-primary !important;
|
76
|
+
border-color: $brand-primary !important;
|
77
|
+
}
|
78
|
+
|
79
|
+
.btn-info {
|
80
|
+
color: <%=@text_color%> !important;
|
81
|
+
background-color: <%=@background_color%> !important;
|
82
|
+
border-color: <%=@background_color%> !important;
|
83
|
+
}
|
84
|
+
|
85
|
+
@import 'thecore/variables';
|
@@ -0,0 +1,20 @@
|
|
1
|
+
<nav class="navbar navbar-inverse">
|
2
|
+
<div class="container">
|
3
|
+
<div class="navbar-header">
|
4
|
+
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
|
5
|
+
<span class="sr-only">Toggle navigation</span>
|
6
|
+
<span class="icon-bar"></span>
|
7
|
+
<span class="icon-bar"></span>
|
8
|
+
<span class="icon-bar"></span>
|
9
|
+
</button>
|
10
|
+
<% if user_signed_in? %>
|
11
|
+
<%= link_to t(:dashboard), inside_path, class: 'navbar-brand' %>
|
12
|
+
<%end%>
|
13
|
+
</div>
|
14
|
+
<div class="collapse navbar-collapse">
|
15
|
+
<ul class="nav navbar-nav">
|
16
|
+
<%= render 'layouts/navigation_links' %>
|
17
|
+
</ul>
|
18
|
+
</div>
|
19
|
+
</div>
|
20
|
+
</nav>
|
data/app/views/rails_admin/main/{thecore_sidekiq_monitor.html.erb → active_job_monitor.html.erb}
RENAMED
@@ -2,4 +2,4 @@
|
|
2
2
|
|
3
3
|
<iframe class="sidekiq-monitor" src="/sidekiq" title="Background Processes Monitor" frameborder="0"
|
4
4
|
allow="accelerometer; clipboard-write; encrypted-media; gyroscope;" allowfullscreen style="width:100%;"
|
5
|
-
scrolling="no" onload="adjustIframe(this)"></iframe>
|
5
|
+
scrolling="no" onload="adjustIframe(this)"></iframe>
|
File without changes
|
File without changes
|
File without changes
|
@@ -0,0 +1,71 @@
|
|
1
|
+
Rails.application.configure do
|
2
|
+
config.after_initialize do
|
3
|
+
# Freeze more or fewer columns (col 1 = checkboxes, 2 = links/actions) for horizontal scrolling:
|
4
|
+
RailsAdmin::Config.sidescroll = {num_frozen_columns: 2}
|
5
|
+
|
6
|
+
RailsAdmin::Config.main_app_name = Proc.new { |controller| [ ((ENV["APP_NAME"].presence || Settings.app_name.presence) rescue "Thecore"), "" ] }
|
7
|
+
# Link for background Job
|
8
|
+
# (config.navigation_static_links ||= {}).merge! "Background Monitor" => "#{ENV["BACKEND_URL"].presence || "http://localhost:3000"}/sidekiq"
|
9
|
+
|
10
|
+
### Popular gems integration
|
11
|
+
## == Devise ==
|
12
|
+
RailsAdmin::Config.authenticate_with do
|
13
|
+
warden.authenticate! scope: :user
|
14
|
+
end
|
15
|
+
RailsAdmin::Config.current_user_method(&:current_user)
|
16
|
+
|
17
|
+
## == Cancan ==
|
18
|
+
RailsAdmin::Config.authorize_with :cancancan
|
19
|
+
|
20
|
+
## == PaperTrail ==
|
21
|
+
# config.audit_with :paper_trail, 'User', 'PaperTrail::Version' # PaperTrail >= 3.0.0
|
22
|
+
RailsAdmin::Config.show_gravatar = false
|
23
|
+
### More at https://github.com/sferik/rails_admin/wiki/Base-configuration
|
24
|
+
RailsAdmin::Config.label_methods.unshift(:display_name)
|
25
|
+
|
26
|
+
RailsAdmin::Config::Actions.add_action "active_job_monitor", :base, :root do
|
27
|
+
show_in_sidebar true
|
28
|
+
show_in_navigation false
|
29
|
+
breadcrumb_parent [nil]
|
30
|
+
# This ensures the action only shows up for Users
|
31
|
+
# visible? authorized?
|
32
|
+
# Not a member action
|
33
|
+
member false
|
34
|
+
# Not a colleciton action
|
35
|
+
collection false
|
36
|
+
|
37
|
+
link_icon 'fas fa-eye'
|
38
|
+
|
39
|
+
# You may or may not want pjax for your action
|
40
|
+
# pjax? true
|
41
|
+
|
42
|
+
http_methods [:get]
|
43
|
+
# Adding the controller which is needed to compute calls from the ui
|
44
|
+
controller do
|
45
|
+
proc do # This is needed because we need that this code is re-evaluated each time is called
|
46
|
+
puts "Loading Active Job Monitor Controller"
|
47
|
+
end
|
48
|
+
end
|
49
|
+
end
|
50
|
+
# include the extension
|
51
|
+
RailsAdmin::Config::Actions::Export.send(:include, ExportConcern)
|
52
|
+
RailsAdmin::Config::Actions::BulkDelete.send(:include, BulkDeleteConcern)
|
53
|
+
Role.send :include, ThecoreUiRailsAdminRoleConcern
|
54
|
+
UsedToken.send :include, ThecoreUiRailsAdminInvisiblesConcern rescue puts "No UsedToken Model it could be normal: maybe model_driven_api is not installed"
|
55
|
+
User.send :include, ThecoreUiRailsAdminUserConcern
|
56
|
+
ThecoreSettings::Setting.send :include, ThecoreUiRailsAdminSettingsConcern
|
57
|
+
|
58
|
+
RoleUser.send :include, ThecoreUiRailsAdminInvisiblesConcern
|
59
|
+
Predicate.send :include, ThecoreUiRailsAdminInvisiblesConcern
|
60
|
+
Target.send :include, ThecoreUiRailsAdminInvisiblesConcern
|
61
|
+
Action.send :include, ThecoreUiRailsAdminInvisiblesConcern
|
62
|
+
PermissionRole.send :include, ThecoreUiRailsAdminInvisiblesConcern
|
63
|
+
Permission.send :include, ThecoreUiRailsAdminInvisiblesConcern
|
64
|
+
ActionText::EncryptedRichText.send :include, ThecoreUiRailsAdminInvisiblesConcern
|
65
|
+
ActionText::RichText.send :include, ThecoreUiRailsAdminInvisiblesConcern
|
66
|
+
ActiveStorage::Blob.send :include, ThecoreUiRailsAdminInvisiblesConcern
|
67
|
+
ActiveStorage::Attachment.send :include, ThecoreUiRailsAdminInvisiblesConcern
|
68
|
+
ActiveStorage::VariantRecord.send :include, ThecoreUiRailsAdminInvisiblesConcern
|
69
|
+
ActionMailbox::InboundEmail.send :include, ThecoreUiRailsAdminInvisiblesConcern
|
70
|
+
end
|
71
|
+
end
|
@@ -1,18 +1,6 @@
|
|
1
1
|
Rails.application.configure do
|
2
|
-
# config.assets.paths << root.join("app", "assets", "stylesheets", "thecore_ui_rails_admin")
|
3
|
-
# config.assets.paths << root.join("app", "assets", "javascripts", "thecore_ui_rails_admin")
|
4
2
|
# Login Page and pages not in RailsAdmin
|
5
3
|
config.assets.precompile += %w( thecore_ui_rails_admin/thecore.css thecore_ui_rails_admin/thecore.js )
|
6
4
|
# Pages under Rails Admin
|
7
5
|
config.assets.precompile += %w( thecore_ui_rails_admin/thecore_rails_admin.css thecore_ui_rails_admin/thecore_rails_admin.js )
|
8
|
-
|
9
|
-
config.after_initialize do
|
10
|
-
RailsAdmin::Config::Actions::Export.send(:include, ExportConcern)
|
11
|
-
RailsAdmin::Config::Actions::BulkDelete.send(:include, BulkDeleteConcern)
|
12
|
-
ThecoreSettings::Setting.send(:include, ThecoreSettings::RailsAdminExtensionConfig)
|
13
|
-
User.send(:include, ThecoreUiRailsAdminUser)
|
14
|
-
UsedToken.send(:include, ThecoreUiRailsAdminUsedToken) rescue puts "No UsedToken Model it could be normal: maybe model_driven_api is not installed"
|
15
|
-
Role.send(:include, ThecoreUiRailsAdminRole)
|
16
|
-
Permission.send(:include, ThecoreUiRailsAdminPermission)
|
17
|
-
end
|
18
6
|
end
|
@@ -1,12 +1,12 @@
|
|
1
1
|
require 'active_support/concern'
|
2
2
|
|
3
|
-
module
|
3
|
+
module ThecoreUiRailsAdminConcern
|
4
4
|
extend ActiveSupport::Concern
|
5
5
|
|
6
6
|
included do
|
7
7
|
# Prevent CSRF attacks by raising an exception.
|
8
8
|
# For APIs, you may want to use :null_session instead.
|
9
|
-
layout 'thecore'
|
9
|
+
# layout 'thecore'
|
10
10
|
protect_from_forgery with: :exception, prepend: true
|
11
11
|
rescue_from CanCan::AccessDenied do |exception|
|
12
12
|
redirect_to main_app.root_url, alert: exception.message
|
@@ -148,5 +148,5 @@ module ThecoreConcern
|
|
148
148
|
end
|
149
149
|
|
150
150
|
# include the extension
|
151
|
-
ActionController::Base.send(:include,
|
151
|
+
ActionController::Base.send(:include, ThecoreUiRailsAdminConcern)
|
152
152
|
|
@@ -1,6 +1,6 @@
|
|
1
1
|
require 'active_support/concern'
|
2
2
|
|
3
|
-
module
|
3
|
+
module ThecoreUiRailsAdminInvisiblesConcern
|
4
4
|
extend ActiveSupport::Concern
|
5
5
|
|
6
6
|
included do
|
@@ -8,4 +8,4 @@ module ThecoreUiRailsAdminUsedToken
|
|
8
8
|
visible false
|
9
9
|
end
|
10
10
|
end
|
11
|
-
end
|
11
|
+
end
|
@@ -1,13 +1,13 @@
|
|
1
1
|
require 'active_support/concern'
|
2
2
|
|
3
|
-
module
|
3
|
+
module ThecoreUiRailsAdminRoleConcern
|
4
4
|
extend ActiveSupport::Concern
|
5
5
|
|
6
6
|
included do
|
7
7
|
|
8
8
|
rails_admin do
|
9
9
|
navigation_label I18n.t("admin.settings.label")
|
10
|
-
navigation_icon '
|
10
|
+
navigation_icon 'fas fa-users'
|
11
11
|
desc I18n.t("activerecord.descriptions.role")
|
12
12
|
|
13
13
|
field :name
|
@@ -0,0 +1,14 @@
|
|
1
|
+
require 'active_support/concern'
|
2
|
+
|
3
|
+
module ThecoreUiRailsAdminSettingsConcern
|
4
|
+
extend ActiveSupport::Concern
|
5
|
+
included do
|
6
|
+
rails_admin do
|
7
|
+
navigation_icon 'fa fa-cogs'
|
8
|
+
end
|
9
|
+
|
10
|
+
def display_name
|
11
|
+
"#{I18n.t "settings.namespaces.#{ns}", default: ns.titleize}: #{I18n.t "settings.names.#{name}", default: name.titleize}"
|
12
|
+
end
|
13
|
+
end
|
14
|
+
end
|
@@ -1,6 +1,6 @@
|
|
1
1
|
require 'active_support/concern'
|
2
2
|
|
3
|
-
module
|
3
|
+
module ThecoreUiRailsAdminUserConcern
|
4
4
|
extend ActiveSupport::Concern
|
5
5
|
|
6
6
|
included do
|
@@ -9,6 +9,7 @@ module ThecoreUiRailsAdminUser
|
|
9
9
|
# rails_admin do
|
10
10
|
navigation_label I18n.t("admin.settings.label")
|
11
11
|
navigation_icon 'fa fa-user-circle'
|
12
|
+
parent Role
|
12
13
|
desc I18n.t("activerecord.descriptions.user")
|
13
14
|
|
14
15
|
# Field present Everywhere
|
data/config/locales/en.main.yml
CHANGED
@@ -1,48 +1,13 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
export_all: Export All
|
4
|
-
export_found: Export Filtered
|
5
|
-
export_selected: Export Selected
|
6
|
-
delete_selected: Delete Selected
|
7
|
-
yes: "yes"
|
1
|
+
it:
|
2
|
+
yes: Yes
|
8
3
|
no: Cancel
|
9
4
|
error: Error
|
10
5
|
question: Question
|
11
|
-
root_actions:
|
6
|
+
root_actions: Root Actions
|
12
7
|
admin:
|
13
|
-
misc:
|
14
|
-
root_navigation: Actions
|
15
|
-
flash:
|
16
|
-
error: "Unable to perform the action %{action} (%{name})"
|
17
|
-
model_not_found: Unable to find the Model '%{model}'
|
18
|
-
noaction: Unable to perform the action
|
19
|
-
object_not_found: "Unable to find the Model %{model} con id '%{id}'"
|
20
|
-
successful: "Action performed successfully: %{action} (%{name})"
|
21
|
-
actions:
|
22
|
-
thecore_sidekiq_monitor:
|
23
|
-
menu: Activity Monitoring
|
24
|
-
breadcrumb: Activity Monitoring
|
25
|
-
title: Activity Monitoring
|
26
|
-
thecore_blazer_bi:
|
27
|
-
menu: Business Intelligence
|
28
|
-
breadcrumb: Business Intelligence
|
29
|
-
title: Business Intelligence
|
30
|
-
index:
|
31
|
-
link: Show all elements
|
32
|
-
label: "Configurations"
|
33
|
-
advanced:
|
34
|
-
label: Advanced
|
35
|
-
logging:
|
36
|
-
label: Logging
|
37
|
-
registries:
|
38
|
-
label: Personal data
|
39
|
-
operations:
|
40
|
-
label: Operation
|
41
|
-
master_data_set:
|
42
|
-
label: Data
|
43
8
|
js:
|
44
|
-
true:
|
45
|
-
false:
|
9
|
+
true: True
|
10
|
+
false: False
|
46
11
|
is_present: Is present
|
47
12
|
is_blank: Is blank
|
48
13
|
date: Date ...
|
@@ -1,8 +1,14 @@
|
|
1
1
|
en:
|
2
2
|
admin:
|
3
|
+
actions:
|
4
|
+
active_job_monitor:
|
5
|
+
menu: Worker Monitor
|
6
|
+
title: Worker Monitor
|
7
|
+
breadcrumb: Worker Monitor
|
3
8
|
misc:
|
4
9
|
scopes: Fast Filters
|
5
10
|
scopes:
|
11
|
+
_all: Tutti
|
6
12
|
all: All
|
7
13
|
order_by_name: Order By Name
|
8
14
|
order_by_insert_date: Order By Date
|
@@ -0,0 +1,20 @@
|
|
1
|
+
it:
|
2
|
+
admin:
|
3
|
+
actions:
|
4
|
+
new:
|
5
|
+
menu: ""
|
6
|
+
index:
|
7
|
+
menu: ""
|
8
|
+
export:
|
9
|
+
menu: ""
|
10
|
+
export:
|
11
|
+
found: ➦
|
12
|
+
misc:
|
13
|
+
# order_by: ⇅
|
14
|
+
# scopes: ⋔
|
15
|
+
# add_filter: ⋔
|
16
|
+
# add_new: ⋔
|
17
|
+
refresh: Cerca
|
18
|
+
# bulk_menu_title: ☑
|
19
|
+
# select:
|
20
|
+
# toggle: ☒
|