| Package: | Ext.grid |
| Defined In: | .js |
| Class: | |
| Extends: | Ext.util.Observable |
var myForm = new Ext.form.BasicForm("form-el-id", {
onSubmit: Ext.emptyFn,
submit: function() {
this.getEl().dom.submit();
}
});| 属性 | 定义者 | |
|---|---|---|
|
this: MixedCollection
/* The Ext.form.Field items in this...
/* The Ext.form.Field items in this form.
|
BasicForm | |
| 方法 | 定义者 | |
|---|---|---|
|
getEl
(
)
:
Get the HTML form Element
Get the HTML form Element
参数项:
|
BasicForm | |
|
isValid
(
)
:
Returns true if client-side validat...
Returns true if client-side validation on the form is successful.
参数项:
|
BasicForm | |
|
isDirty
(
)
:
Returns true if any fields in this ...
Returns true if any fields in this form have changed since their original load.
参数项:
|
BasicForm | |
doAction
(
String/Object actionName,
Object options
)
: BasicForm
Performs a predefined action ({@lin...
Performs a predefined action ({@link Ext.form.Action.Submit} or {@link Ext.form.Action.Load}) or a custom extension of {@link Ext.form.Action} to perform application-specific processing.
or instance of {@link Ext.form.Action} to perform.
All of the config options listed below are supported by both the submit and load actions unless otherwise noted (custom actions could also accept other config options):
参数项:
|
BasicForm | |
submit
(
Object options
)
: BasicForm
Shortcut to do a submit action.
Shortcut to do a submit action.
参数项:
|
BasicForm | |
load
(
Object options
)
: BasicForm
Shortcut to do a load action.
Shortcut to do a load action.
参数项:
|
BasicForm | |
updateRecord
(
Record record
)
: BasicForm
Persists the values in this form in...
Persists the values in this form into the passed Ext.data.Record object in a beginEdit/endEdit block.
参数项:
|
BasicForm | |
loadRecord
(
Record record
)
: BasicForm
Loads an Ext.data.Record into this ...
Loads an Ext.data.Record into this form.
参数项:
|
BasicForm | |
findField
(
String id
)
:
Find a Ext.form.Field in this form ...
Find a Ext.form.Field in this form by id, dataIndex, name or hiddenName.
参数项:
|
BasicForm | |
markInvalid
(
Array/Object errors
)
: BasicForm
Mark fields in this form invalid in...
Mark fields in this form invalid in bulk.
参数项:
|
BasicForm | |
setValues
(
Array/Object values
)
: BasicForm
Set values for fields in this form ...
Set values for fields in this form in bulk.
[{id:'clientName', value:'Fred. Olsen Lines'},
{id:'portOfLoading', value:'FXT'},
{id:'portOfDischarge', value:'OSL'} ]
or an object hash of the form: 参数项:
|
BasicForm | |
getValues
(
Boolean asString
)
:
Returns the fields in this form as ...
Returns the fields in this form as an object with key/value pairs as they would be submitted using a standard form submit. If multiple fields exist with the same name they are returned as an array.
参数项:
|
BasicForm | |
|
clearInvalid
(
)
: BasicForm
Clears all invalid messages in this...
Clears all invalid messages in this form.
参数项:
|
BasicForm | |
|
reset
(
)
: BasicForm
Resets this form.
Resets this form.
参数项:
|
BasicForm | |
add
(
Field field1,
Field field2,
Field etc
)
: BasicForm
Add Ext.form components to this form.
Add Ext.form components to this form.
参数项:
|
BasicForm | |
remove
(
Field field
)
: BasicForm
Removes a field from the items coll...
Removes a field from the items collection (does NOT remove its markup).
参数项:
|
BasicForm | |
|
render
(
)
: BasicForm
Looks at the fields in this form, c...
Looks at the fields in this form, checks them for an id attribute, and calls applyTo on the existing dom element with that id.
参数项:
|
BasicForm | |
applyToFields
(
Object values
)
: BasicForm
Calls {@link Ext#apply} for all fie...
Calls {@link Ext#apply} for all fields in this form with the passed object.
参数项:
|
BasicForm | |
applyIfToFields
(
Object values
)
: BasicForm
Calls {@link Ext#applyIf} for all f...
Calls {@link Ext#applyIf} for all field in this form with the passed object.
参数项:
|
BasicForm | |
fireEvent
(
String eventName,
)
: Boolean
触发指定的事件,并将参数传入(至少要有事件名称)。
触发指定的事件,并将参数传入(至少要有事件名称)。
参数项:
|
Observable | |
addListener
(
String eventName,
Function handler,
[Object scope],
[Object options]
)
为该组件加入事件句柄(event handler)
为该组件加入事件句柄(event handler)
句柄函数执行时所在的作用域。句柄函数“this”的上下文。 触发事件后开始执行句柄的延时时间(invocation:the act of making a particular function start),单位:毫秒 true代表为下次事件触发加入一个要处理的句柄,然后再移除本身。 不同配搭方式的选项 一次调用加入上多个句柄(handlers) 或者是以简写的方式书写,前提是只允许同一个的作用域对象传入到所有的句柄中:
参数项:
|
Observable | |
removeListener
(
String eventName,
Function handler,
Object scope
)
移除侦听器
移除侦听器
参数项:
|
Observable | |
|
purgeListeners
(
)
从这个对象身上移除所有的侦听器
从这个对象身上移除所有的侦听器
参数项:
|
Observable | |
addEvents
(
Object object
)
定义观察者的事件。
定义观察者的事件。
参数项:
|
Observable | |
hasListener
(
String eventName
)
: Boolean
查询该对象是否有指定事件的侦听器
查询该对象是否有指定事件的侦听器
参数项:
|
Observable | |
|
suspendEvents
(
)
暂停触发所有的事件(参阅{@link #resumeEvents})
暂停触发所有的事件(参阅{@link #resumeEvents})
参数项:
|
Observable | |
|
resumeEvents
(
)
重新触发事件(参阅{@link #suspendEvents})
重新触发事件(参阅{@link #suspendEvents})
参数项:
|
Observable | |
Ext.util.Observable.prototype.on
(
String eventName,
[Object scope],
Function handler,
[Object options]
)
为该元素添加事件句柄(event handler),addListen...
为该元素添加事件句柄(event handler),addListener的简写方式 @param {String} eventName 侦听事件的类型 @param {Object} scope (可选的) 执行句柄的作用域 @param {Function} handler 事件涉及的方法 @param {Object} options (可选的) @method
参数项:
|
Observable | |
Ext.util.Observable.prototype.un
(
String eventName,
Function handler,
[Object scope]
)
移除侦听器 @param {String} eventName ...
移除侦听器 @param {String} eventName 侦听事件的类型 @param {Function} handler 事件涉及的方法 @param {Object} scope (可选的)句柄的作用域 @method
参数项:
|
Observable | |
Ext.util.Observable.capture
(
Observable o,
Function fn,
[Object scope]
)
. 开始捕捉特定的观察者。 在事件触发之前,所有的事件会...
. 开始捕捉特定的观察者。 在事件触发之前,所有的事件会以"事件名称+标准签名"的形式传入到函数(传入的参数是function类型)。 如果传入的函数执行后返回false,则接下的事件将不会触发。 @param {Observable} o 要捕捉的观察者 @param {Function} fn 要调用的函数 @param {Object} scope (可选的)函数作用域 @static
参数项:
|
Observable | |
Ext.util.Observable.releaseCapture
(
Observable o
)
从Observable身上移除所有已加入的捕捉captu...
从Observable身上移除所有已加入的捕捉captures @param {Observable} o 要释放的观察者 @static
参数项:
|
Observable | |