zutils 0.1.9 → 0.2.0

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: 87774d0b4bade17dbfbf691b7fdbbf66605bd3d154598f28f7d650f2ec10bd2c
4
- data.tar.gz: ee5cb78bbb9e22450155327e43bf37c5bb857aab83a3d807ad9a9f21bc97326f
3
+ metadata.gz: f2ac69d536e8f34424c3ab2c4712d04068893dfb2adc79dc7f9754a227a1e42c
4
+ data.tar.gz: 46d91b3491276ce9512b249bf9787f91f9e0ce77d6033c8a24ac1ffe04ce0b11
5
5
  SHA512:
6
- metadata.gz: '04683de51005f1081a62816385b693b62e956e71d64da67807c03e4a8bc9ef56f3834fa3c7978e920762726561831ecf419f7e6cd854efcd58b09c2df857230b'
7
- data.tar.gz: b88db9d689fc9318ace4f9a7cfc2d399af965c73ce677742b7c17f7fef95012fd5f07235eef34b401672a039874b1008a9700ef509d4ee4e021febf0d511d9f1
6
+ metadata.gz: b46ba2f6530ccf0657c064ca823665c02ccb4b2db2cec965552040ac0284c0f7bc6047b88b7773bf69e6fc76b1f201f86fe666845424f47ace2e116d74ccee02
7
+ data.tar.gz: 8a843eff1ad8a617c8436d4870840d11883ee2d1968d6789de2067c0bed95d1027aacd5a96e86bfc0df585cca06aae4b2ba49342a99c85cf16b2926a5f3d6c95
@@ -11,7 +11,7 @@
11
11
  <%=t Kernel.const_get(controller_name.singularize.camelize).model_name.human.pluralize %>
12
12
  </h3>
13
13
  </div>
14
- <div class="box-body">
14
+ <div class="box-body no-padding">
15
15
  <% unless search_fields.empty? %>
16
16
  <div class="row">
17
17
  <%= search_form_for @q, url: eval(nested_resource ? "#{parent_resource}_#{controller_name}_path" : "#{controller_name}_path") do |f| %>
@@ -27,7 +27,7 @@
27
27
  <dl>
28
28
  <% (form_ordered_fields - ['id', 'created_at', 'updated_at', 'deleted_at'] - excluded_columns).each do |column| %>
29
29
  <% wphtml = "col-md-#{(form_fields[column.to_sym].class == Hash ? form_fields[column.to_sym][:size] : form_fields[column.to_sym] ) || 12}" %>
30
- <% icon = (form_fields[column.to_sym].class == Hash ? form_fields[column.to_sym][:icon] : 'id-card-o') %>
30
+ <% icon = (form_fields[column.to_sym].class == Hash ? (form_fields[column.to_sym][:icon].blank? ? 'id-card-o' : form_fields[column.to_sym][:icon]) : 'id-card-o') %>
31
31
  <div class="<%= wphtml %>">
32
32
  <dt>
33
33
  <i class="fa fa-<%= icon %> margin-r-5"></i>
@@ -133,19 +133,3 @@
133
133
  </div>
134
134
  <% end %>
135
135
  <% end %>
136
-
137
- <div class="box box-<%= box_class %>">
138
- <div class="box-footer">
139
- <% if can? :edit, object %> <!--verificando se o usuario esta logado-->
140
- <%= link_to eval_with_rescue("edit_#{controller_name.singularize}_path(#{object.id})"), class: "btn btn-warning", data: { toggle: 'tooltip', placement: 'top', title: 'Editar' } do %>
141
- <i class="fa fa-pencil"></i> Editar
142
- <% end %>
143
- <% end %>
144
-
145
- <% if nested_resource %>
146
- <%= link_to 'Listagem', eval_with_rescue("#{parent_resource.class.model_name.to_s.downcase}_#{controller_name}_path(#{parent_resource.id})"), class: "btn btn-default" %>
147
- <% else %>
148
- <%= link_to 'Listagem', eval_with_rescue("#{controller_name}_path"), class: "btn btn-default" %>
149
- <% end %>
150
- </div>
151
- </div>
@@ -1,3 +1,3 @@
1
1
  module Zutils
2
- VERSION = "0.1.9"
2
+ VERSION = "0.2.0"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: zutils
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.9
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ricardo Viana