tramway-admin 2.1.3.2 → 2.1.3.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +2 -1
- data/app/views/tramway/admin/records/_search.html.haml +1 -1
- data/lib/tramway/admin/version.rb +1 -1
- metadata +3 -4
- data/lib/tramway/admin/preview.rb +0 -15
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: dcf7895786074971f30f08a973c8bc290a533faff676f5ecc65c444076d7f397
|
4
|
+
data.tar.gz: 0d445fbf425502399899e0d66be21acb78ee0f673ec06abb94d7f2743a29e239
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9d2619f6ab1f3eef6bc2a330f0dd17f91272fad60c478a07329892fd986bcd13c38bfd5312c69576df533946fca4f20219857ac34a68e8b87aa72e8bebb989f4
|
7
|
+
data.tar.gz: b1bb886e6bb88028d7665b545c3b8c1550398e19c585cda994e7863a10eeb45dff197837b2a2b5137a5189c47c60103e063695918880adaad097766f1cf8d48d
|
data/README.md
CHANGED
@@ -541,7 +541,8 @@ class YourModelDecorator < Tramway::Core::ApplicationDecorator
|
|
541
541
|
inner: lambda do # inner HTML you want to see in the button
|
542
542
|
fa_icon 'file-excel'
|
543
543
|
end,
|
544
|
-
color: :success # bootstrap button color
|
544
|
+
color: :success, # bootstrap button color
|
545
|
+
method: :get # HTTP method. get method is a default. Available: :post, :patch: delete
|
545
546
|
}
|
546
547
|
]
|
547
548
|
}
|
@@ -8,7 +8,7 @@
|
|
8
8
|
= hidden_field_tag :model, params[:model]
|
9
9
|
= hidden_field_tag :scope, params[:scope]
|
10
10
|
= hidden_field_tag :filter, (params[:filter].is_a?(ActionController::Parameters) ? params[:filter].permit!.to_h.to_json : params[:filter])
|
11
|
-
- decorator_class(model_class).list_filters
|
11
|
+
- decorator_class(model_class).list_filters&.each_slice(3) do |slice|
|
12
12
|
.row-fluid.filters
|
13
13
|
- slice.each do |filter|
|
14
14
|
- case filter[1][:type]
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tramway-admin
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.1.3.
|
4
|
+
version: 2.1.3.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Pavel Kalashnikov
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-11-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: tramway-core
|
@@ -305,7 +305,6 @@ files:
|
|
305
305
|
- lib/tramway/admin/generators/templates/form.rb.erb
|
306
306
|
- lib/tramway/admin/navbar.rb
|
307
307
|
- lib/tramway/admin/notifications.rb
|
308
|
-
- lib/tramway/admin/preview.rb
|
309
308
|
- lib/tramway/admin/record_routes_helper.rb
|
310
309
|
- lib/tramway/admin/records_models.rb
|
311
310
|
- lib/tramway/admin/singleton_models.rb
|
@@ -331,7 +330,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
331
330
|
- !ruby/object:Gem::Version
|
332
331
|
version: '0'
|
333
332
|
requirements: []
|
334
|
-
rubygems_version: 3.1.
|
333
|
+
rubygems_version: 3.1.2
|
335
334
|
signing_key:
|
336
335
|
specification_version: 4
|
337
336
|
summary: Engine for admin
|
@@ -1,15 +0,0 @@
|
|
1
|
-
module Tramway::Admin::Preview
|
2
|
-
def set_previewable_models(*models)
|
3
|
-
@previewable_models ||= []
|
4
|
-
@previewable_models += models.map(&:to_s)
|
5
|
-
end
|
6
|
-
|
7
|
-
def previewable_models
|
8
|
-
@previewable_models
|
9
|
-
end
|
10
|
-
|
11
|
-
def is_available_to_preview?(model_class)
|
12
|
-
@previewable_models ||= []
|
13
|
-
@previewable_models.include? model_class.to_s
|
14
|
-
end
|
15
|
-
end
|