cutlass_js_rails 0.3.5 → 0.3.6

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
  SHA1:
3
- metadata.gz: a58eb429c2b7b35f198d62897987f9d41a74afe1
4
- data.tar.gz: dc448f83f5d622296a118c6c06df07fb1ea8d17d
3
+ metadata.gz: 04b45311f9a47df3d45a53107243e32f084abc82
4
+ data.tar.gz: dcbd4032cc53c92e98980fb03705dcc6b0057589
5
5
  SHA512:
6
- metadata.gz: e5e0af76f60d9f480a26c4e6ba6295f3960cd335fd83552f4cc5de097082c776b3a01748510843e368c2888f49a6d841dc5a0dc45013c534b0e76eb1bb43a7ee
7
- data.tar.gz: bb2c8fbd0b7c0d9340a2ba40d0f325c5bf8b90e2879aef51fd6aa7375fdabb231af78eba76c0c6c155ff3ed4c27a3a743144c45697180cc10c88ff014092da6c
6
+ metadata.gz: 354aa3a1614fc538848c8356c005aaa5ce1cdbc474fa1f1977c2f2c08b2a870059940d21fe8be730043e7ff9ffb160438b0dca1472f363e9e3fa923998e2f474
7
+ data.tar.gz: f53069989153f8601068afff8e9707cdc6cd5e11563cbcff06b4e61c5c54537f97f67f87f2279f6a0d2b9e4275e6d2f5833ae8d22e9be28f0b7388871e746eea
@@ -1,5 +1,6 @@
1
1
  <% css_classes = (defined? css_classes) ? css_classes : '' %>
2
2
  <% props = (defined? props) ? props.to_h : {} %>
3
3
  <% code = local_assigns.fetch(:code) %>
4
+ <% error_code = local_assigns.fetch(:error_code, code) || code %>
4
5
  <% value = local_assigns.fetch(:value, '') %>
5
- <%= f.text_field code, class: "Cutlass-input-text #{css_classes}", value: value, **({ 'data-label' => label, 'data-error' => model.errors[code][0] }.merge(props).symbolize_keys) %>
6
+ <%= f.text_field code, class: "Cutlass-input-text #{css_classes}", value: value, **({ 'data-label' => label, 'data-error' => model.errors[error_code][0] }.merge(props).symbolize_keys) %>
@@ -1,3 +1,3 @@
1
1
  module CutlassJsRails
2
- VERSION = '0.3.5'
2
+ VERSION = '0.3.6'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cutlass_js_rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.5
4
+ version: 0.3.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - chardos
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-06-20 00:00:00.000000000 Z
11
+ date: 2016-06-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler