Constructor
new module:crm/Validator()
Example
createLayout: function() {
return this.layout || (this.layout = [{
label: this.accountText,
name: 'AccountName',
property: 'AccountName',
type: 'text',
validator: validator.notEmpty
}, {
label: this.webText,
name: 'WebAddress',
property: 'WebAddress',
renderer: format.link,
type: 'text',
inputType: 'url',
maxTextLength: 128,
validator: validator.exceedsMaxTextLength
}]);
}
Members
(static) exceedsMaxTextLength
Properties:
Type | Description |
---|---|
Object |
(static) exists
Properties:
Name | Type | Description |
---|---|---|
exists |
Object | Validator that ensures the field contains a value. |
(static) hasText
Properties:
Name | Type | Description |
---|---|---|
Validator |
Object | that ensures a field has text. Warning This does not work with unicode. |
- Deprecated:
- Yes
- Source:
(static) isCurrency
Properties:
Name | Type | Description |
---|---|---|
Validator |
Object | that ensures a field is valid currency. |
(static) isDateInRange
Properties:
Type | Description |
---|---|
Object |
(static) isDecimal
Properties:
Name | Type | Description |
---|---|---|
Validator |
Object | that ensures a field is a valid decimal. |
(static) isGreaterThan
Properties:
Type | Description |
---|---|
Object |
(static) isInt32
Properties:
Name | Type | Description |
---|---|---|
Validator |
Object | that ensures a field is a valid Int32. |
(static) isInteger
Properties:
Name | Type | Description |
---|---|---|
Validator |
Object | that ensures a field is a valid number. |
(static) isLessThan
Properties:
Type | Description |
---|---|
Object |
(static) isPhoneNumber
Properties:
Type | Description |
---|---|
Object |
- Deprecated:
- Yes
- Source:
(static) name
Properties:
Name | Type | Description |
---|---|---|
name |
Object | Validator that ensures a FirstName and LastName property have been specified. |
(static) notEmpty
Properties:
Name | Type | Description |
---|---|---|
Validator |
Object | that ensures a field is not empty. |