tramway-admin 1.11.2 → 1.12
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a503c8ac204e6d2d36cbbe4168b72f0ce843fc744cda0c6fb3106082de4cc701
|
4
|
+
data.tar.gz: 76a0541f594c9a3eb2a22cfd3f500a0674af4f8bf54219538716ccc7fda2e999
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 77d5cb62cdf5700b915c0c8c870290f47c236d5bcbb4889effc7db5f4db3df0d8f9deb552a582bf0fc192ac9a3c98deef5afbd97a2bb7d0f80853ff5e8ddcffe
|
7
|
+
data.tar.gz: cf97934893fec436f5ade4751f8049738d94b40bf466bdd8621e68abf103a07da8400a476ac4efdc65cc71bd78e6920841c49bfdeb1dae46242b0d85e3002290
|
@@ -17,6 +17,10 @@ module Tramway::Admin
|
|
17
17
|
records_path args, options.merge(model: params[:model])
|
18
18
|
end
|
19
19
|
|
20
|
+
def public_path(record)
|
21
|
+
record.public_path || try("#{record.class.name.underscore.gsub('/', '_')}_path", record)
|
22
|
+
end
|
23
|
+
|
20
24
|
def model_class
|
21
25
|
params[:model].constantize
|
22
26
|
end
|
@@ -13,6 +13,8 @@
|
|
13
13
|
= current_title
|
14
14
|
- edit_path = object_type(object) == :singleton ? edit_current_model_singleton_path : edit_current_model_record_path(object.id)
|
15
15
|
= link_to fa_icon(:pencil), edit_path, class: 'btn btn-warning btn-xs'
|
16
|
+
- if public_path(object)
|
17
|
+
= link_to fa_icon(:share), public_path(object), class: 'btn btn-primary btn-xs'
|
16
18
|
%hr
|
17
19
|
.row
|
18
20
|
%table.table.table-striped.table-bordered
|
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: 1.
|
4
|
+
version: '1.12'
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Pavel Kalashnikov
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-04-
|
11
|
+
date: 2019-04-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bootstrap-kaminari-views
|