mirror of
https://0xacab.org/sutty/sutty
synced 2024-11-15 04:01:43 +00:00
mostrar mejor los checkboxes #51
This commit is contained in:
parent
92252851b9
commit
dedd6b4e4c
5 changed files with 13 additions and 7 deletions
|
@ -84,12 +84,12 @@
|
|||
%small.text-muted.form-text= t('posts.lang_help')
|
||||
- @post.template_fields.each do |template|
|
||||
- next unless type = template.type
|
||||
- value = @post.new? ? template.values : @post.get_front_matter(template)
|
||||
.form-group
|
||||
= label_tag "post_#{template}", id: template do
|
||||
- if template.private?
|
||||
= fa_icon 'lock', title: t('posts.private')
|
||||
= template.help
|
||||
- value = @post.new? ? template.values : @post.get_front_matter(template)
|
||||
= render "posts/template_field/#{type}", template: template, name: template.key, value: value
|
||||
.invalid-feedback= t('posts.invalid')
|
||||
.form-group
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
= hidden_field_tag field_name_for_post_as_string(name), value: 'false'
|
||||
= check_box_tag field_name_for_post_as_string(name),
|
||||
'true',
|
||||
value == 'true',
|
||||
class: 'form-control'
|
||||
- field_name = field_name_for_post_as_string(name)
|
||||
= hidden_field_tag field_name, value: 'false'
|
||||
.form-check
|
||||
= check_box_tag field_name,
|
||||
'true',
|
||||
value == 'true',
|
||||
class: 'form-check-input'
|
||||
= label_tag field_name, t('posts.checkbox'), class: 'form-check-label'
|
||||
|
|
|
@ -3,4 +3,5 @@
|
|||
= render "posts/template_field/#{template.type}",
|
||||
template: template,
|
||||
name: name,
|
||||
value: value
|
||||
value: value,
|
||||
nested: true
|
||||
|
|
|
@ -211,3 +211,4 @@ en:
|
|||
row:
|
||||
add: 'Add group'
|
||||
del: 'Remove group'
|
||||
checkbox: 'Yes'
|
||||
|
|
|
@ -207,3 +207,4 @@ es:
|
|||
row:
|
||||
add: 'Agregar grupo'
|
||||
del: 'Eliminar grupo'
|
||||
checkbox: 'Sí'
|
||||
|
|
Loading…
Reference in a new issue