Class CAF.Input
Object
|
+--CAF.Input
- class
CAF.Input
Input utilities.
Defined in core.js
Method Summary |
<static> void
|
addValidator(id, validator, key, nowait)
Registers a validator.
|
<static> void
|
synchronizeValues(ids)
Synchronizes the values of the specified controls
(ie when one control's value changes, updates the other controls' values).
|
<static> Object
|
validate(form, setfocus)
Validates all the input controls in the specified form,
returning an aggregate error message.
|
checkValueChangesInterval
<static> Object checkValueChangesInterval
check for value changes every x ms
ValidatorTimeout
<static> Object ValidatorTimeout
CAF.Input
CAF.Input()
addValidator
<static> void addValidator(id, validator, key, nowait)
Parameters:
id
- Client-side control id or element.
validator
- Validator object that has a validate(id, value) method, where the first arg to validate() is the control id, and the second arg is the control value. The return value of the custom validate function should be the error message string if there are errors, or an empty string if the value is valid.
synchronizeValues
<static> void synchronizeValues(ids)
Synchronizes the values of the specified controls
(ie when one control's value changes, updates the other controls' values).
Parameters:
ids
- Array of client-side control ids.
validate
<static> Object validate(form, setfocus)
Validates all the input controls in the specified form,
returning an aggregate error message.
Parameters:
form
- Form element or id.
setfocus
- (optional) True to set focus to the first invalid control.
Returns:
Aggregate error detail (un-escaped html) if invalid, or empty string if valid.
Documentation generated by
JSDoc on Mon Aug 30 14:56:06 2021