zutils 0.4.3 → 0.4.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/views/shared/_list.html.erb +6 -2
- data/lib/zutils/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: df6c3780c457eeaa243e2ad25e0b3f353fc8e9901bcef670cbda4fb446cda471
|
4
|
+
data.tar.gz: afcf7a3976c562678cbced427916b0ffe22b536c8a205bf6e161b8b29997dd75
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f392ba6d0989f76f4fbcc34920d3f446d7f233965845118df10931431ddfc9a3334b3940b7971a80d100722e5c5a48aae408c74daf984ccb71dda25d421b9048
|
7
|
+
data.tar.gz: 3a58ed27dadb041688132507c7d42455b76b50b7a34f874b132df1c17e96005c2e578c5446f6a3c89e4311be88a272f5a1cea245d95a33ef62fb9f48cfee1493
|
@@ -51,16 +51,20 @@
|
|
51
51
|
<% show_columns.each do |column| %>
|
52
52
|
<% next if /_currency$/ =~ column %>
|
53
53
|
<td>
|
54
|
-
|
54
|
+
<% if object.respond_to?(column) && (
|
55
|
+
object.send(column).class == Date or
|
55
56
|
object.send(column).class == DateTime or
|
56
57
|
object.send(column).class == ActiveSupport::TimeWithZone or
|
57
|
-
object.send(column).class == Time %>
|
58
|
+
object.send(column).class == Time) %>
|
58
59
|
<%=l object.send(column) %>
|
59
60
|
<% elsif /_id$/ =~ column && object.respond_to?(column.split('_id')[0]) %>
|
60
61
|
<%= object.send(column.split("_id")[0])&.name %>
|
61
62
|
<% elsif /_cents$/ =~ column %>
|
62
63
|
<%= number_to_currency object.send(column.split("_cents")[0]) %>
|
63
64
|
<% elsif /_currency$/ =~ column %>
|
65
|
+
<!-- faz nada -->
|
66
|
+
<% elsif column.include?(".") %>
|
67
|
+
<%= eval("object.#{column}") %>
|
64
68
|
<% elsif column == 'id' %>
|
65
69
|
<%= link_to object.id, object %>
|
66
70
|
<% else %>
|
data/lib/zutils/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: zutils
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ricardo Viana
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-
|
11
|
+
date: 2019-06-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -99,7 +99,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
99
99
|
- !ruby/object:Gem::Version
|
100
100
|
version: '0'
|
101
101
|
requirements: []
|
102
|
-
rubygems_version: 3.0.
|
102
|
+
rubygems_version: 3.0.3
|
103
103
|
signing_key:
|
104
104
|
specification_version: 4
|
105
105
|
summary: Utilidades gerais para aplicações rails
|