Roo.util.Observable Roo.form.BasicForm
Package: | Roo.form |
Defined In: | Roo/form/BasicForm.js. |
Class: | BasicForm |
Subclasses: | Roo.form.Form |
Extends: | Roo.util.Observable |
Options | Defined By | |
---|---|---|
baseParams : Object
Parameters to pass with all requests.
Parameters to pass with all requests. e.g. baseParams: {id: '123', foo: 'bar'}.
|
Roo.form.BasicForm | |
errorReader : DataReader
An Roo.data.DataReader (e.g.
An Roo.data.DataReader (e.g. {link Roo.data.XmlReader}) to be used to read data when reading validation errors on "submit" actions.
This is completely optional as there is built-in support for processing JSON. |
Roo.form.BasicForm | |
fileUpload : Boolean
Set to true if this form is a file upload.
Set to true if this form is a file upload.
|
Roo.form.BasicForm | |
listeners : Object
list of events and functions to call for this object,
For example :
list of events and functions to call for this object,
For example :
|
Roo.util.Observable | |
method : String
The request method to use (GET or POST) for form actions if one isn't supplied in the action options.
The request method to use (GET or POST) for form actions if one isn't supplied in the action options.
|
Roo.form.BasicForm | |
reader : DataReader
An Roo.data.DataReader (e.g.
An Roo.data.DataReader (e.g. {link Roo.data.XmlReader}) to be used to read data when executing "load" actions.
This is optional as there is built-in support for processing JSON. |
Roo.form.BasicForm | |
timeout : Number
Timeout for form actions in seconds (default is 30 seconds).
Timeout for form actions in seconds (default is 30 seconds).
|
Roo.form.BasicForm | |
trackResetOnLoad : Boolean
If set to true, form.reset() resets to the last loaded
or setValues() data instead of when the form was first created.
If set to true, form.reset() resets to the last loaded
or setValues() data instead of when the form was first created. |
Roo.form.BasicForm | |
url : String
The URL to use for form actions if one isn't supplied in the action options.
The URL to use for form actions if one isn't supplied in the action options.
|
Roo.form.BasicForm |
Method | Defined By | |
---|---|---|
add
(Field field1, Field field2, Field etc)
:
BasicForm
Add Roo.form components to this form.
Add Roo.form components to this form.
|
Roo.form.BasicForm | |
addEvents
(Object object)
Used to define events on this Observable
Used to define events on this Observable
|
Roo.util.Observable | |
addForm
(Roo.form.Form form)
Add a secondary form to this one,
Used to provide tabbed forms.
Add a secondary form to this one,
Used to provide tabbed forms. One form is primary, with hidden values which mirror the elements from the other forms.
|
Roo.form.BasicForm | |
Appends an event handler to this component
Appends an event handler to this component
|
Roo.util.Observable | |
applyIfToFields
(Object values)
:
BasicForm
Calls {link ExtapplyIf} for all field in this form with the passed object.
Calls {link ExtapplyIf} for all field in this form with the passed object.
|
Roo.form.BasicForm | |
applyToFields
(Object values)
:
BasicForm
Calls {link Extapply} for all fields in this form with the passed object.
Calls {link Extapply} for all fields in this form with the passed object.
|
Roo.form.BasicForm | |
clearInvalid
()
:
BasicForm
Clears all invalid messages in this form.
Clears all invalid messages in this form.
|
Roo.form.BasicForm | |
Performs a predefined action (submit or load) or custom actions you define on this form.
Performs a predefined action (submit or load) or custom actions you define on this form.
|
Roo.form.BasicForm | |
findField
(String id)
:
Find a Roo.form.Field in this form by id, dataIndex, name or hiddenName
Find a Roo.form.Field in this form by id, dataIndex, name or hiddenName
|
Roo.form.BasicForm | |
Fires the specified event with the passed parameters (minus the event name).
|
Roo.util.Observable | |
getFieldValues
()
:
Object
Returns the fields in this form as an object with key/value pairs.
Returns the fields in this form as an object with key/value pairs.
This differs from getValues as it calls getValue on each child item, rather than using dom data.
|
Roo.form.BasicForm | |
Roo.form.BasicForm | ||
hasChanged
()
:
Returns true if any fields in this form have changed since their original load.
Returns true if any fields in this form have changed since their original load. (New version)
|
Roo.form.BasicForm | |
Roo.util.Observable | ||
isDirty
()
:
DEPRICATED Returns true if any fields in this form have changed since their original load.
DEPRICATED Returns true if any fields in this form have changed since their original load.
|
Roo.form.BasicForm | |
isValid
()
:
Returns true if client-side validation on the form is successful.
Returns true if client-side validation on the form is successful.
|
Roo.form.BasicForm | |
load
(Object options)
:
BasicForm
Shortcut to do a load action.
Shortcut to do a load action.
|
Roo.form.BasicForm | |
loadRecord
(Record record)
:
BasicForm
Loads an Roo.data.Record into this form.
Loads an Roo.data.Record into this form.
|
Roo.form.BasicForm | |
markInvalid
(Array/Object errors)
:
BasicForm
Mark fields in this form invalid in bulk.
Mark fields in this form invalid in bulk.
|
Roo.form.BasicForm | |
Appends an event handler to this element (shorthand for addListener)
Appends an event handler to this element (shorthand for addListener)
|
Roo.util.Observable | |
purgeListeners
()
Removes all listeners for this object
Removes all listeners for this object
|
Roo.util.Observable | |
remove
(Field field)
:
BasicForm
Removes a field from the items collection (does NOT remove its markup).
Removes a field from the items collection (does NOT remove its markup).
|
Roo.form.BasicForm | |
Roo.util.Observable | ||
render
()
:
BasicForm
Looks at the fields in this form, checks them for an id attribute,
and calls applyTo on the existing dom element with that id.
Looks at the fields in this form, checks them for an id attribute,
and calls applyTo on the existing dom element with that id.
|
Roo.form.BasicForm | |
reset
()
:
BasicForm
Resets this form.
Resets this form.
|
Roo.form.BasicForm | |
resetHasChanged
()
:
Resets all hasChanged to 'false' -
The old 'isDirty' used 'original value.
Resets all hasChanged to 'false' -
The old 'isDirty' used 'original value..' however this breaks reset() and a few other things. So hasChanged storage is only to be used for this purpose
|
Roo.form.BasicForm | |
setValues
(Array/Object values)
:
BasicForm
Set values for fields in this form in bulk.
Set values for fields in this form in bulk.
|
Roo.form.BasicForm | |
submit
(Object options)
:
BasicForm
Shortcut to do a submit action.
Shortcut to do a submit action.
|
Roo.form.BasicForm | |
Roo.util.Observable | ||
updateRecord
(Record record)
:
BasicForm
Persists the values in this form into the passed Roo.data.Record object in a beginEdit/endEdit block.
Persists the values in this form into the passed Roo.data.Record object in a beginEdit/endEdit block.
|
Roo.form.BasicForm |