Switch
<div id="switch_control"
data-win-control="HFWinJSCtrl.Switch"
data-win-options="{
label: 'Switch',
messages: {
checked: 'On',
unchecked: 'OFF'
}
}">
</div>
Property | Type | How to use | Description |
---|---|---|---|
doNotCopy | Boolean | doNotCopy: true | Set "true" whenever the field should get deleted if form is copied. |
label | String | label: 'Switch' | Define a label for your control element. |
required | Boolean | required: true | Set "true" if the control has to be filled in. |
tooltip | String | tooltip: 'Please indicate at least one cause of damage.' | Write a comment to provide further information about the field. A question mark will then be shown within the label and with a click/tap on it, the information will occur. |
Stored data
For each RadioBox group inside your forms there are several value pairs of stored data – at least there are three:
One for the checked radio button
{
"id": "billing_free_warranty",
"value": true
}
one for the unchecked radio button
{
"id": "billing_invoice",
"value": false
}
and one value pair for the "result" i.e. the selected value
{
"id": "billing_HFValue",
"value": "Free repair"
}
Info
If you don't provide an HTML value, the label text next to and of the selected radio button will be stored.