|
| allowBlank : Boolean Specify false to validate that the value's length is > 0 (defaults to
true) | TextField |
| allowDomMove : Boolean Whether the component can move the Dom node when rendering (defaults to true). | Component |
| altFormats : StringMultiple date formats separated by "|" to try when parsing a user input value and it
does not match the defined forma... Multiple date formats separated by "|" to try when parsing a user input value and it
does not match the defined format (defaults to
@@ -129,7 +129,10 @@ Warning: This will override any size manag... The maxi
Warning: This will override any size mana... The minimum value in pixels which this BoxComponent will set its height to.
Warning: This will override any size management applied by layout managers. | BoxComponent |
| boxMinWidth : NumberThe minimum value in pixels which this BoxComponent will set its width to.
Warning: This will override any size manag... The minimum value in pixels which this BoxComponent will set its width to.
- Warning: This will override any size management applied by layout managers. | BoxComponent |
| clearCls : StringThe CSS class used to to apply to the special clearing div rendered
+ Warning: This will override any size management applied by layout managers. | BoxComponent |
| bubbleEvents : ArrayAn array of events that, when fired, should be bubbled to any parent container.
+See Ext.util.Observable.enableBubble.... | Component |
| clearCls : StringThe CSS class used to to apply to the special clearing div rendered
directly after each form field wrapper to provide... The CSS class used to to apply to the special clearing div rendered
directly after each form field wrapper to provide field clearing (defaults to
'x-form-clear-left').
@@ -467,9 +470,9 @@ validation fails (defaults to 'The minimum length for this field is {minLeng
'The date in this field must be after {minValue}'). | DateField |
| minValue : Date/StringThe minimum allowed date. Can be either a Javascript date object or a string date in a
valid format (defaults to null... The minimum allowed date. Can be either a Javascript date object or a string date in a
valid format (defaults to null). | DateField |
| msgFx : String Experimental The effect used when displaying a validation message under the field
-(defaults to 'normal'). | Field |
| msgTarget<p>The : Stringlocation where the message text set through markInvalid should display.
+(defaults to 'normal'). | Field |
| msgTarget : StringThe location where the message text set through markInvalid should display.
Must be one of the following values:
-<div cla... location where the message text set through markInvalid should display.
+<div... The location where the message text set through markInvalid should display.
Must be one of the following values:
qtip Display a quick tip containing the message when the user hovers over the field. This is the default.
@@ -478,7 +481,7 @@ Must be one of the following values:
under Add a block div beneath the field containing the error message.
side Add an error icon to the right of the field, displaying the message in a popup on hover.
[element id] Add the error message directly to the innerHTML of the specified element.
- | Field |
| name : StringThe field's HTML name attribute (defaults to '').
+ | Field |
| name : StringThe field's HTML name attribute (defaults to '').
Note: this property must be set if this field is to be automaticall... The field's HTML name attribute (defaults to '').
Note: this property must be set if this field is to be automatically included with
form submit(). | Field |
| overCls : StringAn optional extra CSS class that will be added to this component's Element when the mouse moves
@@ -788,38 +791,38 @@ should usually not need to be called directly. Enable this component and fire the 'enable' event. Enable this component and fire the 'enable' event. | Component |
| enableBubble( String/Array events )
:
- voidEnables events fired by this Observable to bubble up an owner hierarchy by calling
-this.getBubbleTarget() if present... Enables events fired by this Observable to bubble up an owner hierarchy by calling
-this.getBubbleTarget() if present. There is no implementation in the Observable base class.
- This is commonly used by Ext.Components to bubble events to owner Containers. See Ext.Component.getBubbleTarget. The default
-implementation in Ext.Component returns the Component's immediate owner. But if a known target is required, this can be overridden to
-access the required target more quickly.
- Example: Ext.override(Ext.form.Field, {
- // Add functionality to Field's initComponent to enable the change event to bubble
- initComponent : Ext.form.Field.prototype.initComponent.createSequence(function() {
- this.enableBubble('change');
- }),
-
- // We know that we want Field's events to bubble directly to the FormPanel.
- getBubbleTarget : function() {
- if (!this.formPanel) {
- this.formPanel = this.findParentByType('form');
- }
- return this.formPanel;
- }
-});
-
-var myForm = new Ext.formPanel({
- title: 'User Details',
- items: [{
- ...
- }],
- listeners: {
- change: function() {
- // Title goes red if form has been modified.
- myForm.header.setStyle('color', 'red');
- }
- }
+ voidEnables events fired by this Observable to bubble up an owner hierarchy by calling
+this.getBubbleTarget() if present.... Enables events fired by this Observable to bubble up an owner hierarchy by calling
+this.getBubbleTarget() if present. There is no implementation in the Observable base class.
+ This is commonly used by Ext.Components to bubble events to owner Containers. See Ext.Component.getBubbleTarget. The default
+implementation in Ext.Component returns the Component's immediate owner. But if a known target is required, this can be overridden to
+access the required target more quickly.
+ Example: Ext.override(Ext.form.Field, {
+ // Add functionality to Field's initComponent to enable the change event to bubble
+ initComponent : Ext.form.Field.prototype.initComponent.createSequence(function() {
+ this.enableBubble('change');
+ }),
+
+ // We know that we want Field's events to bubble directly to the FormPanel.
+ getBubbleTarget : function() {
+ if (!this.formPanel) {
+ this.formPanel = this.findParentByType('form');
+ }
+ return this.formPanel;
+ }
+});
+
+var myForm = new Ext.formPanel({
+ title: 'User Details',
+ items: [{
+ ...
+ }],
+ listeners: {
+ change: function() {
+ // Title goes red if form has been modified.
+ myForm.header.setStyle('color', 'red');
+ }
+ }
});
| Observable |
| findParentBy( Function fn )
:
Ext.ContainerFind a container above this component at any level by a custom function. If the passed function returns
@@ -857,7 +860,14 @@ or use a render listener directly: new Ext.Panel({
},
single: true // Remove the listener after first invocation
}
-});
| Component |
| getHeight()
+}); | Component |
| getErrors( Mixed value )
+ :
+ ArrayRuns all of NumberFields validations and returns an array of any errors. Note that this first
+runs TextField's valida... Runs all of NumberFields validations and returns an array of any errors. Note that this first
+runs TextField's validations, so the returned array is an amalgamation of all field errors.
+The additional validation checks are testing that the date format is valid, that the chosen
+date is within the min and max date constraints set, that the date chosen is not in the disabledDates
+regex and that the day chosed is not one of the disabledDays. | DateField |
| getHeight()
:
NumberGets the current height of the component's underlying element. Gets the current height of the component's underlying element. | BoxComponent |
| getId()
:
@@ -1033,7 +1043,12 @@ event... | Observable |
| selectText( [Number start ], [Number end ] )
:
- voidSelects text in this field Selects text in this field | TextField |
| setAutoScroll( Boolean scroll )
+ voidSelects text in this field Selects text in this field | TextField |
| setActiveError( String msg , Boolean suppressEvent )
+ :
+ voidSets the current activeError to the given string. Fires the 'invalid' event.
+This does not set up the error icon, onl... Sets the current activeError to the given string. Fires the 'invalid' event.
+This does not set up the error icon, only sets the message and fires the event. To show the error icon,
+use markInvalid instead, which calls this method internally | Field |
| setAutoScroll( Boolean scroll )
:
Ext.BoxComponentSets the overflow on the content element of the component. Sets the overflow on the content element of the component. | BoxComponent |
| setDisabled( Boolean disabled )
:
@@ -1049,10 +1064,10 @@ config for details on supported values.Returns:
Allow or prevent the user from directly editing the field text. If false is passed,
the user will only be able to modify the field using the trigger. Will also add
a click event to the text field which will call the trigger. This method
-is the runtime equivalent of setting the 'editable' config option at config time.Returns: | TriggerField |
| setHeight( Number height )
+is the runtime equivalent of setting the 'editable' config option at config time.Returns: | TriggerField |
| setHeight( Mixed height )
:
- Ext.BoxComponentSets the height of the component. This method fires the resize event. Sets the height of the component. This method fires the resize event. Parameters:height : NumberThe new height to set. This may be one of:
| BoxComponent |
| setMaxValue( Date value )
@@ -1109,10 +1124,10 @@ dateField.setValue('05/04/2006');
dateField.format = 'Y-m-d';
dateField.setValue('2006-05-04'); | DateField |
| setVisible( Boolean visible )
:
- Ext.ComponentConvenience function to hide or show this component by boolean. Convenience function to hide or show this component by boolean. | Component |
| setWidth( Number width )
+ Ext.ComponentConvenience function to hide or show this component by boolean. Convenience function to hide or show this component by boolean. | Component |
| setWidth( Mixed width )
:
- Ext.BoxComponentSets the width of the component. This method fires the resize event. Sets the width of the component. This method fires the resize event. Parameters:width : NumberThe new width to setThis may be one of:
| BoxComponent |
| show()
:
@@ -1126,7 +1141,11 @@ after the Force the component's size to recalculate based on the underlying element's current height and width. Force the component's size to recalculate based on the underlying element's current height and width. | BoxComponent |
| un( String eventName , Function handler , [Object scope ] )
:
- voidRemoves an event handler (shorthand for removeListener.) | Observable |
| update( Mixed htmlOrData , [Boolean loadScripts ], [Function callback ] )
+ voidRemoves an event handler (shorthand for removeListener.) | Observable |
| unsetActiveError( Boolean suppressEvent )
+ :
+ voidClears the activeError and fires the 'valid' event. This is called internally by clearInvalid and would not
+usually n... Clears the activeError and fires the 'valid' event. This is called internally by clearInvalid and would not
+usually need to be called manually | Field |
| update( Mixed htmlOrData , [Boolean loadScripts ], [Function callback ] )
:
voidUpdate the content area of a component. Update the content area of a component. Parameters:htmlOrData : MixedIf this component has been configured with a template via the tpl config
then it will use this argument as data to populate the template.
@@ -1135,63 +1154,13 @@ content area will be updated via Ext.Element update loadScri
:
Ext.BoxComponentSets the current box measurements of the component's underlying element. Sets the current box measurements of the component's underlying element.
| BoxComponent |
| validate()
:
- BooleanValidates the field value Validates the field value | Field |
| validateValue( Mixed value )
+ BooleanValidates the field value Validates the field value | Field |
| validateValue( Mixed The )
:
- BooleanValidates a value according to the field's validation rules and marks the field as invalid
-if the validation fails. V... Validates a value according to the field's validation rules and marks the field as invalid
-if the validation fails. Validation rules are processed in the following order:
-
-- 1. Field specific validator
-
- A validator offers a way to customize and reuse a validation specification.
-If a field is configured with a validator
-function, it will be passed the current field value. The validator
-function is expected to return either:
-
-- Boolean true if the value is valid (validation continues).
-- a String to represent the invalid message if invalid (validation halts).
-
-
-- 2. Basic Validation
-
- If the validator has not halted validation,
-basic validation proceeds as follows:
-
-allowBlank : (Invalid message =
-emptyText )
-Depending on the configuration of allowBlank , a
-blank field will cause validation to halt at this step and return
-Boolean true or false accordingly.
-
-minLength : (Invalid message =
-minLengthText )
-If the passed value does not satisfy the minLength
-specified, validation halts.
-
-maxLength : (Invalid message =
-maxLengthText )
-If the passed value does not satisfy the maxLength
-specified, validation halts.
-
-
-
-- 3. Preconfigured Validation Types (VTypes)
-
- If none of the prior validation steps halts validation, a field
-configured with a vtype will utilize the
-corresponding VTypes validation function.
-If invalid, either the field's vtypeText or
-the VTypes vtype Text property will be used for the invalid message.
-Keystrokes on the field will be filtered according to the VTypes
-vtype Mask property.
-
-- 4. Field specific regex test
-
- If none of the prior validation steps halts validation, a field's
-configured regex test will be processed.
-The invalid message for this test is configured with
-regexText .
- Parameters:value : MixedThe value to validate Returns: | TextField |