[英]ExtJs 4 - Form panel submit without params
我正在使用ExtJs 4.2。
我有一個表單面板,其中包含一些文本字段。
例如:
items: [{
fieldLabel: 'User Name',
afterLabelTextTpl: required,
name: 'userName',
allowBlank: false,
tooltip: 'Enter admin user name'
},{
fieldLabel: 'Password',
inputType:'password',
afterLabelTextTpl: required,
name: 'password',
allowBlank: false,
tooltip: 'Enter admin user paswword'
}
],
我通過使用以下方式提交表單:
this.up('form').getForm().submit({
method: 'POST',
url: 'someUrl',
params: <SomeOtherParams>,
success: function(form, action) {
Ext.Msg.alert('Success', action.result.msg);
},
failure: function(form, action) {
Ext.Msg.alert('Failure', action.result.msg);
}
});
我只需要提交表單附加參數“ SomeOtherParams”,而不提交表單基本參數。
在我的情況下,基本參數是:“ userName”和“ password”。
我能以某種方式使這些參數消失嗎?
我嘗試配置“ baseParams:null”,但似乎沒有進行任何更改。
有人可以幫忙嗎?
謝謝。
您可以簡單地將2個不需要的字段的submitValue
屬性設置為false
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.