只要在容器组件初始化的时候传入这个参数:
例如:
var p= new Ext.panel({
title:'pppp',
getValues:function(asString){
var setEl = this.getEl();
var setElements = setEl.select("*[name][type]");
var fs = Ext.lib.Ajax.serializeForm(setElements);
if(asString === true)
{
return fs;
}
return Ext.urlDecode(fs);
}
});
//使用方法
var values = p.getValues();