SO i have a checkbox in my template which is (jade)
input(type='checkbox' name='flag' class='pure-checkbox onoffswitch-checkbox' id='myonoffswitch')
and i use this custom template form my flag field
schema:
flag:
template: require ('templates/onoff-switch.hbs')
threshold:
type: 'Text'
title: 'Threshold($)'
editorClass: 'pure-input-1-3'
but when i submit my form the flag value is not set, its empty. I hope i
have to bind my value to the checkbox value but i am sure how.
i tried
input(type='checkbox' name='flag' class='pure-checkbox onoffswitch-checkbox' id='myonoffswitch' checked="{{#if flag}}checked{{/if}}")
Any idea?