Documentation
Modal Form
getData #
Returns: Object
Get key=value object of the modal form fields when the key is name of field and the value is value of field.
onmodal: {
modalname: {
save: function($modal, $form)
{
var data = $form.getData();
}
}
}
setData #
data | Object |
Set key=value object to the modal form when the key is name of field and the value is value of field.
onmodal: {
modalname: {
save: function($modal, $form)
{
$form.setData({ fieldname: value });
}
}
}
getField #
name | String |
Returns: Dom
Boolean
Get the field of modal form by the name.
onmodal: {
modalname: {
save: function($modal, $form)
{
var $field = $form.getField('name');
}
}
}
setError #
name | String |
Mark the modal form field with the error class.
onmodal: {
modalname: {
save: function($modal, $form)
{
$form.setError('name');
}
}
}