tramway-admin 1.1 → 1.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/views/tramway/admin/records/_form.html.haml +2 -2
- data/lib/tramway/admin/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 006b7f42bf5ce7ef78e8473313d6f9f9ceb380d4c4c7449d4eddad7419c4e4ad
|
4
|
+
data.tar.gz: 9e5e80889695bc9b3e40264a8b03938c9ecb22ce029d8c5e3927ae3eb60571f1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4ccb51eab026d6536dcd3ef52ef6fc7f6f692e2e0ab134614dd56d07837843dcd16cea99526e265ee0cec68c0c6a28a038f17f4ccbba634f87f60e2c33564d75
|
7
|
+
data.tar.gz: 662a5073833ed6cbf8e61071702bbdef321aafcea6f41a8a297595bd926dce040e8c3a58a4503cbb135e852eb2cc53f21a3229b39ed07350eaeaaf1b04f1398e
|
@@ -12,8 +12,8 @@
|
|
12
12
|
- @record_form.properties.each do |property, type|
|
13
13
|
- value = params.dig(model_class.to_s.underscore, property.to_s)
|
14
14
|
- if type == :default
|
15
|
-
= f.input property, input_html: { name: "record[#{property}]", id: "record_#{property}", value: value }, selected: value
|
15
|
+
= f.input property, input_html: { name: "record[#{property}]", id: "record_#{property}", value: (@record_form.model.send(property) || value) }, selected: (@record_form.model.send(property) || value)
|
16
16
|
- else
|
17
|
-
= f.input property, as: type, input_html: { name: "record[#{property}]", id: "record_#{property}", value: value }
|
17
|
+
= f.input property, as: type, input_html: { name: "record[#{property}]", id: "record_#{property}", value: (@record_form.model.send(property) || value) }
|
18
18
|
= f.button :submit, t('helpers.links.save'), class: 'btn-success'
|
19
19
|
= link_to t('helpers.links.back'), current_model_records_path, class: 'btn btn-secondary'
|