swop 0.1.0 → 0.1.1
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/assets/javascripts/rails_admin/application.js.erb +3 -2
- data/app/assets/javascripts/rails_admin/custom/abstract-select.js +30 -0
- data/app/assets/javascripts/rails_admin/custom/filter-box.js +363 -0
- data/app/assets/javascripts/rails_admin/custom/filtering-multiselect.js +387 -0
- data/app/assets/javascripts/rails_admin/custom/filtering-select.js +1 -1
- data/app/assets/stylesheets/rails_admin/application.scss.erb +19 -33
- data/app/assets/stylesheets/rails_admin/{custom → themes}/base/base.scss +4 -0
- data/app/assets/stylesheets/rails_admin/themes/base/bootstrap-variables.scss +252 -0
- data/app/assets/stylesheets/rails_admin/{custom → themes}/base/mixins.scss +0 -16
- data/app/assets/stylesheets/rails_admin/themes/base/theming.scss +22 -0
- data/app/assets/stylesheets/rails_admin/themes/base/variables.scss +71 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/base/typography.scss +22 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/base/variables-dark.scss +74 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/base/variables-light.scss +77 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/base/variables-navy.scss +74 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/base/variables.scss +129 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/components/alerts.scss +88 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/components/breadcrumbs.scss +44 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/components/buttons.scss +138 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/components/containers.scss +15 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/components/dropdowns.scss +12 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/components/filter-box.scss +8 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/components/filtering-multiselect.scss +40 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/components/filtering-select.scss +42 -0
- data/app/assets/stylesheets/rails_admin/{custom → themes/simple}/components/forms.scss +4 -2
- data/app/assets/stylesheets/rails_admin/{custom → themes/simple}/components/images.scss +4 -6
- data/app/assets/stylesheets/rails_admin/themes/simple/components/links.scss +25 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/components/navs.scss +73 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/components/progress.scss +4 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/components/sidebar.scss +84 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/components/tables.scss +84 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/layouts/rows.scss +34 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/light/components/links.scss +15 -0
- data/app/assets/stylesheets/rails_admin/themes/simple/light/components/sidebar.scss +25 -0
- data/app/assets/stylesheets/rails_admin/themes/simple.scss.erb +37 -0
- data/app/helpers/rails_admin/application_helper.rb +34 -46
- data/app/helpers/rails_admin/form_builder.rb +166 -0
- data/app/views/layouts/rails_admin/_custom_navigation.html.erb +10 -0
- data/app/views/layouts/rails_admin/_head.html.erb +32 -0
- data/app/views/layouts/rails_admin/_header.html.erb +43 -0
- data/app/views/layouts/rails_admin/_sidebar_navigation.html.erb +3 -1
- data/app/views/layouts/rails_admin/application.html.erb +15 -12
- data/app/views/layouts/rails_admin/content.html.erb +6 -51
- data/app/views/rails_admin/main/_form_polymorphic_association.html.erb +15 -0
- data/app/views/rails_admin/main/_submit_buttons.html.erb +22 -18
- data/app/views/rails_admin/main/dashboard.html.erb +49 -55
- data/app/views/rails_admin/main/export.html.erb +23 -23
- data/app/views/rails_admin/main/history.html.erb +87 -0
- data/app/views/rails_admin/main/index.html.erb +60 -56
- data/app/views/rails_admin/main/show.html.erb +15 -23
- data/config/locales/rails_admin.en.yml +158 -0
- data/lib/swop/version.rb +1 -1
- data/lib/swop.rb +1 -0
- metadata +41 -28
- data/app/assets/javascripts/rails_admin/custom/sidescroll.js +0 -20
- data/app/assets/javascripts/rails_admin/custom/ui.js +0 -11
- data/app/assets/stylesheets/rails_admin/custom/base/bootstrap-variables.scss +0 -196
- data/app/assets/stylesheets/rails_admin/custom/base/typography.scss +0 -16
- data/app/assets/stylesheets/rails_admin/custom/base/variables.scss +0 -86
- data/app/assets/stylesheets/rails_admin/custom/components/breadcrumbs.scss +0 -18
- data/app/assets/stylesheets/rails_admin/custom/components/buttons.scss +0 -55
- data/app/assets/stylesheets/rails_admin/custom/components/dropdowns.scss +0 -40
- data/app/assets/stylesheets/rails_admin/custom/components/filtering-select.scss +0 -43
- data/app/assets/stylesheets/rails_admin/custom/components/navbar.scss +0 -18
- data/app/assets/stylesheets/rails_admin/custom/components/navs.scss +0 -28
- data/app/assets/stylesheets/rails_admin/custom/components/offcanvas.scss +0 -18
- data/app/assets/stylesheets/rails_admin/custom/components/progress.scss +0 -11
- data/app/assets/stylesheets/rails_admin/custom/components/sidebar.scss +0 -115
- data/app/assets/stylesheets/rails_admin/custom/components/table.scss +0 -59
- data/app/assets/stylesheets/rails_admin/custom/components/tiles.scss +0 -20
- data/app/assets/stylesheets/rails_admin/custom/layouts/body.scss +0 -10
- data/app/assets/stylesheets/rails_admin/custom/layouts/containers.scss +0 -31
- data/app/views/layouts/rails_admin/custom/_nav.html.erb +0 -10
- data/app/views/rails_admin/main/delete.html.erb +0 -19
- data/app/views/rails_admin/main/edit.html.erb +0 -5
- data/app/views/rails_admin/main/new.html.erb +0 -5
@@ -18,10 +18,29 @@
|
|
18
18
|
%>
|
19
19
|
|
20
20
|
<% content_for :contextual_tabs do %>
|
21
|
+
<% if filterable_fields.present? %>
|
22
|
+
<li class="nav-item dropdown">
|
23
|
+
<a class="nav-link dropdown-toggle" data-bs-toggle="dropdown" href="#">
|
24
|
+
<%= t('admin.misc.add_filter') %>
|
25
|
+
<b class="caret"></b>
|
26
|
+
</a>
|
27
|
+
<ul class="dropdown-menu dropdown-menu-end" id="filters">
|
28
|
+
<% filterable_fields.each do |field| %>
|
29
|
+
<li>
|
30
|
+
<a
|
31
|
+
href="#"
|
32
|
+
class="dropdown-item"
|
33
|
+
data-options="<%= field.with(view: self).filter_options.to_json %>"
|
34
|
+
>
|
35
|
+
<%= field.label %>
|
36
|
+
</a>
|
37
|
+
</li>
|
38
|
+
<% end %>
|
39
|
+
</ul>
|
40
|
+
</li>
|
41
|
+
<% end %>
|
21
42
|
<% if checkboxes %>
|
22
|
-
|
23
|
-
<%= bulk_menu %>
|
24
|
-
</div>
|
43
|
+
<%= bulk_menu %>
|
25
44
|
<% end %>
|
26
45
|
<% end %>
|
27
46
|
|
@@ -34,11 +53,10 @@
|
|
34
53
|
|
35
54
|
<div id="list">
|
36
55
|
<%= form_tag(index_path(params.except(*%w[page f query])), method: :get) do %>
|
37
|
-
<
|
56
|
+
<div class="mb-6 mb-md-7">
|
38
57
|
<div class="row" data-options="<%= ordered_filter_options.to_json %>" id="filters_box"></div>
|
39
|
-
<hr class="filters_box" style="display:<%= ordered_filters.empty? ? 'none' : 'block' %>"/>
|
40
|
-
<div class="row justify-content-
|
41
|
-
<%= content_for :contextual_tabs %>
|
58
|
+
<hr class="filters_box mt-2 mb-4 mb-md-5" style="display:<%= ordered_filters.empty? ? 'none' : 'block' %>"/>
|
59
|
+
<div class="row justify-content-between gy-3 gy-md-0">
|
42
60
|
<div class="col-md-auto">
|
43
61
|
<div class="input-group">
|
44
62
|
<input class="form-control" name="query" placeholder="<%= t("admin.misc.search") %>" type="search" value="<%= query %>" />
|
@@ -54,9 +72,13 @@
|
|
54
72
|
<div class="form-text"><%= @model_config.list.search_help %></div>
|
55
73
|
<% end %>
|
56
74
|
</div>
|
57
|
-
|
75
|
+
<div class="col-md-auto text-end">
|
76
|
+
<% if export_action %>
|
77
|
+
<%= link_to wording_for(:link, export_action), export_path(params.except('page')), class: 'btn btn-white w-100' %>
|
78
|
+
<% end %>
|
79
|
+
</div>
|
58
80
|
</div>
|
59
|
-
</
|
81
|
+
</div>
|
60
82
|
<% end %>
|
61
83
|
<% unless @model_config.list.scopes.empty? %>
|
62
84
|
<ul class="nav nav-tabs" id="scope_selector">
|
@@ -70,7 +92,7 @@
|
|
70
92
|
<% end %>
|
71
93
|
</ul>
|
72
94
|
<% end %>
|
73
|
-
<%= form_tag bulk_action_path(model_name: @abstract_model.to_param), method: :post, id: "bulk_form", class: ["form", "mb-3"] do %>
|
95
|
+
<%= form_tag bulk_action_path(model_name: @abstract_model.to_param), method: :post, id: "bulk_form", class: ["form", "mb-3", "overflow-hidden"] do %>
|
74
96
|
<%= hidden_field_tag :bulk_action %>
|
75
97
|
<% if description.present? %>
|
76
98
|
<p>
|
@@ -79,14 +101,13 @@
|
|
79
101
|
</strong>
|
80
102
|
</p>
|
81
103
|
<% end %>
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
<table class="table table-condensed new">
|
104
|
+
<div id="sidescroll">
|
105
|
+
<div class="table-responsive mb-4 mb-md-5">
|
106
|
+
<table class="table table-condensed table-hover">
|
86
107
|
<thead>
|
87
108
|
<tr>
|
88
109
|
<% if checkboxes %>
|
89
|
-
<th class="shrink sticky">
|
110
|
+
<th class="shrink sticky z-1">
|
90
111
|
<input class="toggle form-check-input" type="checkbox" />
|
91
112
|
</th>
|
92
113
|
<% end %>
|
@@ -96,16 +117,16 @@
|
|
96
117
|
<% sort_location = index_path params.except('sort_reverse').except('page').merge(sort: property.name).merge(selected && sort_reverse != "true" ? {sort_reverse: "true"} : {}) %>
|
97
118
|
<% sort_direction = (sort_reverse == 'true' ? "headerSortUp" : "headerSortDown" if selected) %>
|
98
119
|
<% end %>
|
99
|
-
<th class="<%= [property.sortable && "header", property.sortable && sort_direction, property.sticky? && 'sticky', property.css_class, property.type_css_class
|
120
|
+
<th class="<%= [property.sortable && "header", property.sortable && sort_direction, property.sticky? && 'sticky', property.css_class, property.type_css_class].select(&:present?).join(' ') %>" data-href="<%= property.sortable && sort_location %>" rel="tooltip" title="<%= property.hint %>">
|
100
121
|
<%= property.label %>
|
101
122
|
</th>
|
102
123
|
<% end %>
|
103
124
|
<th class="last shrink"></th>
|
104
125
|
</tr>
|
105
126
|
</thead>
|
106
|
-
<tbody
|
127
|
+
<tbody>
|
107
128
|
<% @objects.each do |object| %>
|
108
|
-
<tr class="<%= @abstract_model.param_key %>_row <%= @model_config.list.with(object: object).row_css_class %>
|
129
|
+
<tr class="<%= @abstract_model.param_key %>_row <%= @model_config.list.with(object: object).row_css_class %>">
|
109
130
|
<% if checkboxes %>
|
110
131
|
<td class="sticky align-middle">
|
111
132
|
<%= check_box_tag "bulk_ids[]", object.id.to_s, false, class: "form-check-input" %>
|
@@ -113,24 +134,19 @@
|
|
113
134
|
<% end %>
|
114
135
|
<% properties.map{ |property| property.bind(:object, object) }.each do |property| %>
|
115
136
|
<% value = property.pretty_value %>
|
116
|
-
<%= content_tag(:td, class: [property.sticky? && 'sticky', 'align-middle', property.css_class, property.type_css_class].select(&:present?), title: strip_tags(value.to_s)) do %>
|
137
|
+
<%= content_tag(:td, class: [property.sticky? && 'sticky', 'align-middle', 'overflow-hidden', property.css_class, property.type_css_class].select(&:present?), title: strip_tags(value.to_s)) do %>
|
117
138
|
<%= value %>
|
118
139
|
<% end %>
|
119
140
|
<% end %>
|
120
|
-
<td class="last links ra-sidescroll-frozen
|
121
|
-
<
|
122
|
-
|
123
|
-
|
124
|
-
</button>
|
125
|
-
<ul class="dropdown-menu">
|
126
|
-
<%= menu_for :member, @abstract_model, object, false %>
|
127
|
-
</ul>
|
128
|
-
</div>
|
141
|
+
<td class="last links ra-sidescroll-frozen">
|
142
|
+
<ul class="nav d-flex align-items-center justify-content-end flex-nowrap gap-2 gap-md-3 mb-0">
|
143
|
+
<%= menu_for :member, @abstract_model, object, true %>
|
144
|
+
</ul>
|
129
145
|
</td>
|
130
146
|
</tr>
|
131
147
|
<% end %>
|
132
148
|
<% if @objects.empty? %>
|
133
|
-
<tr class="
|
149
|
+
<tr class="empty_row">
|
134
150
|
<td colspan="<%= table_table_header_count %>">
|
135
151
|
<%= I18n.t('admin.actions.index.no_records') %>
|
136
152
|
</td>
|
@@ -139,32 +155,20 @@
|
|
139
155
|
</tbody>
|
140
156
|
</table>
|
141
157
|
</div>
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
<%= link_to(t("admin.misc.show_all"), index_path(params.merge(all: true)), class: "show-all btn btn-light clearfix") unless total_count > 100 || total_count <= @objects.to_a.size %>
|
158
|
-
</div>
|
159
|
-
</div>
|
160
|
-
<div class="small clearfix total-count">
|
161
|
-
<%= "#{total_count} #{@model_config.pluralize(total_count).downcase}" %>
|
162
|
-
</div>
|
163
|
-
<% else %>
|
164
|
-
<div class="small clearfix total-count">
|
165
|
-
<%= "#{@objects.size} #{@model_config.pluralize(@objects.size).downcase}" %>
|
166
|
-
</div>
|
167
|
-
<% end %>
|
168
|
-
</section>
|
158
|
+
</div>
|
159
|
+
<% if @model_config.list.limited_pagination %>
|
160
|
+
<%= paginate(@objects, theme: 'ra-twitter-bootstrap/without_count', total_pages: Float::INFINITY) %>
|
161
|
+
<% elsif @objects.respond_to?(:total_count) %>
|
162
|
+
<% total_count = @objects.total_count.to_i %>
|
163
|
+
<%= paginate(@objects, theme: 'ra-twitter-bootstrap') %>
|
164
|
+
<%= link_to(t("admin.misc.show_all"), index_path(params.merge(all: true)), class: "show-all clearfix") unless total_count > 100 || total_count <= @objects.to_a.size %>
|
165
|
+
<div class="clearfix total-count mt-4 mt-md-5">
|
166
|
+
<%= "#{total_count} #{@model_config.pluralize(total_count).downcase}" %>
|
167
|
+
</div>
|
168
|
+
<% else %>
|
169
|
+
<div class="clearfix total-count">
|
170
|
+
<%= "#{@objects.size} #{@model_config.pluralize(@objects.size).downcase}" %>
|
171
|
+
</div>
|
172
|
+
<% end %>
|
169
173
|
<% end %>
|
170
174
|
</div>
|
@@ -1,28 +1,20 @@
|
|
1
|
-
|
2
|
-
<%
|
3
|
-
<% unless (fields =
|
4
|
-
|
5
|
-
|
6
|
-
<
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
<p class="mb-4 mb-md-0"><%= fieldset.help %></p>
|
11
|
-
<% end %>
|
12
|
-
</div>
|
13
|
-
<ul class="nav nav-tabs nav-tabs-main-show mb-4 mb-md-0 ms-auto">
|
14
|
-
<%= menu_for((@abstract_model ? (@object.try(:persisted?) ? :member : :collection) : :root), @abstract_model, @object) %>
|
15
|
-
<%= content_for :contextual_tabs %>
|
16
|
-
</ul>
|
17
|
-
</div>
|
1
|
+
<% @model_config.show.with(object: @object, view: self, controller: self.controller).visible_groups.each do |fieldset| %>
|
2
|
+
<% unless (fields = fieldset.with(object: @object, view: self, controller: self.controller).visible_fields).empty? %>
|
3
|
+
<% unless (fields = fields.reject{ |f| RailsAdmin::config.compact_show_view && (f.formatted_value.nil? || f.formatted_value == '') }).empty? %>
|
4
|
+
<div class="fieldset">
|
5
|
+
<% if fieldset.help %>
|
6
|
+
<h4><%= fieldset.label %></h4>
|
7
|
+
<p><%= fieldset.help %></p>
|
8
|
+
<% end %>
|
9
|
+
<div class="list-group">
|
18
10
|
<% fields.each_with_index do |field, index| %>
|
19
|
-
<div class="
|
20
|
-
<
|
21
|
-
<div class="
|
11
|
+
<div class="list-group-item border-0 <%= field.type_css_class %> <%= field.css_class %> mb-3">
|
12
|
+
<div class="text-muted"><%= field.label %></div>
|
13
|
+
<div class="fw-semibold text-dark"><%= field.pretty_value %></div>
|
22
14
|
</div>
|
23
15
|
<% end %>
|
24
|
-
</
|
25
|
-
|
16
|
+
</dl>
|
17
|
+
</div>
|
26
18
|
<% end %>
|
27
19
|
<% end %>
|
28
|
-
|
20
|
+
<% end %>
|
@@ -0,0 +1,158 @@
|
|
1
|
+
en:
|
2
|
+
admin:
|
3
|
+
js:
|
4
|
+
true: "True"
|
5
|
+
false: "False"
|
6
|
+
is_present: Is present
|
7
|
+
is_blank: Is blank
|
8
|
+
date: Date ...
|
9
|
+
between_and_: Between ... and ...
|
10
|
+
today: Today
|
11
|
+
yesterday: Yesterday
|
12
|
+
this_week: This week
|
13
|
+
last_week: Last week
|
14
|
+
time: Time ...
|
15
|
+
number: Number ...
|
16
|
+
contains: Contains
|
17
|
+
does_not_contain: Does not contain
|
18
|
+
is_exactly: Is exactly
|
19
|
+
starts_with: Starts with
|
20
|
+
ends_with: Ends with
|
21
|
+
too_many_objects: "Too many objects, use search box above"
|
22
|
+
no_objects: "No objects found"
|
23
|
+
clear: Clear
|
24
|
+
loading: "Loading..."
|
25
|
+
toggle_navigation: Toggle navigation
|
26
|
+
home:
|
27
|
+
name: "Home"
|
28
|
+
pagination:
|
29
|
+
previous: "« Prev"
|
30
|
+
next: "Next »"
|
31
|
+
truncate: "…"
|
32
|
+
misc:
|
33
|
+
search: "Search"
|
34
|
+
filter: "Filter"
|
35
|
+
reset_filters: "Reset filters"
|
36
|
+
refresh: "Refresh"
|
37
|
+
show_all: "Show all"
|
38
|
+
add_filter: "Add filter"
|
39
|
+
bulk_menu_title: "Selected items"
|
40
|
+
remove: "Remove"
|
41
|
+
add_new: "Add new"
|
42
|
+
chose_all: "Choose all"
|
43
|
+
clear_all: "Clear all"
|
44
|
+
up: "Up"
|
45
|
+
down: "Down"
|
46
|
+
navigation: "Navigation"
|
47
|
+
root_navigation: "Actions"
|
48
|
+
navigation_static_label: "Links"
|
49
|
+
log_out: "Log out"
|
50
|
+
time_ago: "%{time} ago"
|
51
|
+
ago: "ago"
|
52
|
+
more: "Plus %{count} more %{models_name}"
|
53
|
+
flash:
|
54
|
+
successful: "%{name} successfully %{action}"
|
55
|
+
error: "%{name} failed to be %{action}"
|
56
|
+
noaction: "No actions were taken"
|
57
|
+
model_not_found: "Model '%{model}' could not be found"
|
58
|
+
object_not_found: "%{model} with id '%{id}' could not be found"
|
59
|
+
table_headers:
|
60
|
+
model_name: "Model name"
|
61
|
+
last_created: "Last created"
|
62
|
+
records: "Records"
|
63
|
+
username: "User"
|
64
|
+
changes: "Changes"
|
65
|
+
created_at: "Date/Time"
|
66
|
+
item: "Item"
|
67
|
+
message: "Message"
|
68
|
+
actions:
|
69
|
+
dashboard:
|
70
|
+
title: "Site Administration"
|
71
|
+
menu: "Dashboard"
|
72
|
+
breadcrumb: "Dashboard"
|
73
|
+
index:
|
74
|
+
title: "List of %{model_label_plural}"
|
75
|
+
menu: "List"
|
76
|
+
breadcrumb: "%{model_label_plural}"
|
77
|
+
no_records: "No records found"
|
78
|
+
show:
|
79
|
+
title: "Details for %{model_label} '%{object_label}'"
|
80
|
+
menu: "Show"
|
81
|
+
breadcrumb: "%{object_label}"
|
82
|
+
show_in_app:
|
83
|
+
menu: "Show in app"
|
84
|
+
new:
|
85
|
+
title: "New %{model_label}"
|
86
|
+
menu: "Add new"
|
87
|
+
breadcrumb: "New"
|
88
|
+
link: "Add a new %{model_label}"
|
89
|
+
done: "created"
|
90
|
+
edit:
|
91
|
+
title: "Edit %{model_label} '%{object_label}'"
|
92
|
+
menu: "Edit"
|
93
|
+
breadcrumb: "Edit"
|
94
|
+
link: "Edit this %{model_label}"
|
95
|
+
done: "updated"
|
96
|
+
delete:
|
97
|
+
title: "Delete %{model_label} '%{object_label}'"
|
98
|
+
menu: "Delete"
|
99
|
+
breadcrumb: "Delete"
|
100
|
+
link: "Delete '%{object_label}'"
|
101
|
+
done: "deleted"
|
102
|
+
bulk_delete:
|
103
|
+
title: "Delete %{model_label_plural}"
|
104
|
+
menu: "Multiple delete"
|
105
|
+
breadcrumb: "Multiple delete"
|
106
|
+
bulk_link: "Delete selected %{model_label_plural}"
|
107
|
+
export:
|
108
|
+
title: "Export %{model_label_plural}"
|
109
|
+
menu: "Export"
|
110
|
+
breadcrumb: "Export"
|
111
|
+
link: "Export found %{model_label_plural}"
|
112
|
+
bulk_link: "Export selected %{model_label_plural}"
|
113
|
+
done: "exported"
|
114
|
+
history_index:
|
115
|
+
title: "History for %{model_label_plural}"
|
116
|
+
menu: "History"
|
117
|
+
breadcrumb: "History"
|
118
|
+
history_show:
|
119
|
+
title: "History for %{model_label} '%{object_label}'"
|
120
|
+
menu: "History"
|
121
|
+
breadcrumb: "History"
|
122
|
+
form:
|
123
|
+
cancel: "Cancel"
|
124
|
+
basic_info: "Basic info"
|
125
|
+
required: "Required"
|
126
|
+
optional: "Optional"
|
127
|
+
one_char: "character"
|
128
|
+
char_length_up_to: "length up to"
|
129
|
+
char_length_of: "length of"
|
130
|
+
save: "Save"
|
131
|
+
save_and_add_another: "Save and add another"
|
132
|
+
save_and_edit: "Save and edit"
|
133
|
+
delete_file: "Delete '%{field_label}' #%{number}"
|
134
|
+
all_of_the_following_related_items_will_be_deleted: "? The following related items may be deleted or orphaned:"
|
135
|
+
are_you_sure_you_want_to_delete_the_object: "Are you sure you want to delete this %{model_name}"
|
136
|
+
confirmation: "Yes, I'm sure"
|
137
|
+
bulk_delete: "The following objects will be deleted, which may delete or orphan some of their related dependencies:"
|
138
|
+
new_model: "%{name} (new)"
|
139
|
+
export:
|
140
|
+
confirmation: "Export to %{name}"
|
141
|
+
select: "Select fields to export"
|
142
|
+
select_all_fields: "Select All Fields"
|
143
|
+
fields_from: "%{name}"
|
144
|
+
fields_from_associated: "%{name}"
|
145
|
+
display: "Display %{name}: %{type}"
|
146
|
+
options_for: "Options for %{name}"
|
147
|
+
empty_value_for_associated_objects: "<empty>"
|
148
|
+
click_to_reverse_selection: "Click to reverse selection"
|
149
|
+
csv:
|
150
|
+
header_for_root_methods: "%{name}" # 'model' is available
|
151
|
+
header_for_association_methods: "%{name} [%{association}]"
|
152
|
+
encoding_to: "Encode to"
|
153
|
+
encoding_to_help: "Choose output encoding. Leave empty to let current input encoding untouched: (%{name})"
|
154
|
+
skip_header: "No header"
|
155
|
+
skip_header_help: "Do not output a header (no fields description)"
|
156
|
+
default_col_sep: ","
|
157
|
+
col_sep: "Column separator"
|
158
|
+
col_sep_help: "Leave blank for default ('%{value}')" # value is default_col_sep
|
data/lib/swop/version.rb
CHANGED
data/lib/swop.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: swop
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Kamil Wodzinski
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: exe
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2025-06-28 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rails
|
@@ -73,43 +73,56 @@ files:
|
|
73
73
|
- README.md
|
74
74
|
- Rakefile
|
75
75
|
- app/assets/javascripts/rails_admin/application.js.erb
|
76
|
+
- app/assets/javascripts/rails_admin/custom/abstract-select.js
|
77
|
+
- app/assets/javascripts/rails_admin/custom/filter-box.js
|
78
|
+
- app/assets/javascripts/rails_admin/custom/filtering-multiselect.js
|
76
79
|
- app/assets/javascripts/rails_admin/custom/filtering-select.js
|
77
|
-
- app/assets/javascripts/rails_admin/custom/sidescroll.js
|
78
|
-
- app/assets/javascripts/rails_admin/custom/ui.js
|
79
80
|
- app/assets/stylesheets/rails_admin/application.scss.erb
|
80
|
-
- app/assets/stylesheets/rails_admin/
|
81
|
-
- app/assets/stylesheets/rails_admin/
|
82
|
-
- app/assets/stylesheets/rails_admin/
|
83
|
-
- app/assets/stylesheets/rails_admin/
|
84
|
-
- app/assets/stylesheets/rails_admin/
|
85
|
-
- app/assets/stylesheets/rails_admin/
|
86
|
-
- app/assets/stylesheets/rails_admin/
|
87
|
-
- app/assets/stylesheets/rails_admin/
|
88
|
-
- app/assets/stylesheets/rails_admin/
|
89
|
-
- app/assets/stylesheets/rails_admin/
|
90
|
-
- app/assets/stylesheets/rails_admin/
|
91
|
-
- app/assets/stylesheets/rails_admin/
|
92
|
-
- app/assets/stylesheets/rails_admin/
|
93
|
-
- app/assets/stylesheets/rails_admin/
|
94
|
-
- app/assets/stylesheets/rails_admin/
|
95
|
-
- app/assets/stylesheets/rails_admin/
|
96
|
-
- app/assets/stylesheets/rails_admin/
|
97
|
-
- app/assets/stylesheets/rails_admin/
|
98
|
-
- app/assets/stylesheets/rails_admin/
|
99
|
-
- app/assets/stylesheets/rails_admin/
|
81
|
+
- app/assets/stylesheets/rails_admin/themes/base/base.scss
|
82
|
+
- app/assets/stylesheets/rails_admin/themes/base/bootstrap-variables.scss
|
83
|
+
- app/assets/stylesheets/rails_admin/themes/base/mixins.scss
|
84
|
+
- app/assets/stylesheets/rails_admin/themes/base/theming.scss
|
85
|
+
- app/assets/stylesheets/rails_admin/themes/base/variables.scss
|
86
|
+
- app/assets/stylesheets/rails_admin/themes/simple.scss.erb
|
87
|
+
- app/assets/stylesheets/rails_admin/themes/simple/base/typography.scss
|
88
|
+
- app/assets/stylesheets/rails_admin/themes/simple/base/variables-dark.scss
|
89
|
+
- app/assets/stylesheets/rails_admin/themes/simple/base/variables-light.scss
|
90
|
+
- app/assets/stylesheets/rails_admin/themes/simple/base/variables-navy.scss
|
91
|
+
- app/assets/stylesheets/rails_admin/themes/simple/base/variables.scss
|
92
|
+
- app/assets/stylesheets/rails_admin/themes/simple/components/alerts.scss
|
93
|
+
- app/assets/stylesheets/rails_admin/themes/simple/components/breadcrumbs.scss
|
94
|
+
- app/assets/stylesheets/rails_admin/themes/simple/components/buttons.scss
|
95
|
+
- app/assets/stylesheets/rails_admin/themes/simple/components/containers.scss
|
96
|
+
- app/assets/stylesheets/rails_admin/themes/simple/components/dropdowns.scss
|
97
|
+
- app/assets/stylesheets/rails_admin/themes/simple/components/filter-box.scss
|
98
|
+
- app/assets/stylesheets/rails_admin/themes/simple/components/filtering-multiselect.scss
|
99
|
+
- app/assets/stylesheets/rails_admin/themes/simple/components/filtering-select.scss
|
100
|
+
- app/assets/stylesheets/rails_admin/themes/simple/components/forms.scss
|
101
|
+
- app/assets/stylesheets/rails_admin/themes/simple/components/images.scss
|
102
|
+
- app/assets/stylesheets/rails_admin/themes/simple/components/links.scss
|
103
|
+
- app/assets/stylesheets/rails_admin/themes/simple/components/navs.scss
|
104
|
+
- app/assets/stylesheets/rails_admin/themes/simple/components/progress.scss
|
105
|
+
- app/assets/stylesheets/rails_admin/themes/simple/components/sidebar.scss
|
106
|
+
- app/assets/stylesheets/rails_admin/themes/simple/components/tables.scss
|
107
|
+
- app/assets/stylesheets/rails_admin/themes/simple/layouts/rows.scss
|
108
|
+
- app/assets/stylesheets/rails_admin/themes/simple/light/components/links.scss
|
109
|
+
- app/assets/stylesheets/rails_admin/themes/simple/light/components/sidebar.scss
|
100
110
|
- app/helpers/rails_admin/application_helper.rb
|
111
|
+
- app/helpers/rails_admin/form_builder.rb
|
112
|
+
- app/views/layouts/rails_admin/_custom_navigation.html.erb
|
113
|
+
- app/views/layouts/rails_admin/_head.html.erb
|
114
|
+
- app/views/layouts/rails_admin/_header.html.erb
|
101
115
|
- app/views/layouts/rails_admin/_sidebar_navigation.html.erb
|
102
116
|
- app/views/layouts/rails_admin/application.html.erb
|
103
117
|
- app/views/layouts/rails_admin/content.html.erb
|
104
|
-
- app/views/
|
118
|
+
- app/views/rails_admin/main/_form_polymorphic_association.html.erb
|
105
119
|
- app/views/rails_admin/main/_submit_buttons.html.erb
|
106
120
|
- app/views/rails_admin/main/dashboard.html.erb
|
107
|
-
- app/views/rails_admin/main/delete.html.erb
|
108
|
-
- app/views/rails_admin/main/edit.html.erb
|
109
121
|
- app/views/rails_admin/main/export.html.erb
|
122
|
+
- app/views/rails_admin/main/history.html.erb
|
110
123
|
- app/views/rails_admin/main/index.html.erb
|
111
|
-
- app/views/rails_admin/main/new.html.erb
|
112
124
|
- app/views/rails_admin/main/show.html.erb
|
125
|
+
- config/locales/rails_admin.en.yml
|
113
126
|
- lib/swop.rb
|
114
127
|
- lib/swop/engine.rb
|
115
128
|
- lib/swop/version.rb
|
@@ -1,20 +0,0 @@
|
|
1
|
-
"use strict";
|
2
|
-
|
3
|
-
{
|
4
|
-
document.addEventListener("rails_admin.dom_ready", () => {
|
5
|
-
const scroller = document.getElementById("sidescroll");
|
6
|
-
if (!scroller) {
|
7
|
-
return;
|
8
|
-
}
|
9
|
-
|
10
|
-
scroller.querySelectorAll("tr").forEach((tr, index) => {
|
11
|
-
let firstPosition;
|
12
|
-
tr.querySelectorAll("th.sticky, td.sticky").forEach((td, idx) => {
|
13
|
-
if (idx === 0) {
|
14
|
-
firstPosition = td.offsetLeft;
|
15
|
-
}
|
16
|
-
td.style.left = `${td.offsetLeft + -12 - firstPosition}px`;
|
17
|
-
});
|
18
|
-
});
|
19
|
-
});
|
20
|
-
}
|
@@ -1,11 +0,0 @@
|
|
1
|
-
import jQuery from "jquery";
|
2
|
-
import "jquery-ui/ui/effect.js";
|
3
|
-
|
4
|
-
(function ($) {
|
5
|
-
|
6
|
-
$(document).on("change", "#reverse-selection", function () {
|
7
|
-
const isChecked = $(this).is(":checked"); // true if checked, false if unchecked
|
8
|
-
$(this).closest(".checkbox").next(".control-group").find(".controls input:checkbox").prop("checked", isChecked);
|
9
|
-
});
|
10
|
-
|
11
|
-
})(jQuery);
|