更改组合框分页后,getValue和getRawValue返回相同的值
after change Combobox pagination, getValue and getRawValue returned the same value
我使用Ext js 3.4组合框查找器
假设组合框的存储使用分页。
首先,当我选择某个项目时,它会给出例如:getValue()=>1000和getRawValue()>>"项目名称",但在我更改分页(不选择任何项目)后,getValue(。
有人能帮我吗?
Combobox = Ext.extend(Ext.form.ComboBox, {
allowBlank: false,
autoSelect: false,
baseParams: {},
cls: "remote-server-finder",
displayField: 'name',
emptyText: "",
forceSelection: false,
itemSelector: 'div.remote-server-finder-item',
minChars: 0,
pageSize: 10,
queryDelay: 10,
store: null,
triggerAction: 'all',
typeAhead: true,
valueField: 'id',
minListWidth: 235,
maxHeight: 400,
/**
* Setup the data store and template for the finder.
*/
initComponent: function () {
this.blankText = helpsys.locale.javascript.field_required;
this.loadingText = helpsys.locale.common.searching;
this.listEmptyText = helpsys.locale.javascript.no_matching_record;
this.store = new Ext.data.JsonStore({
baseParams: this.baseParams,
fields: [
{
name: 'id'
},
{
name: 'name'
},
{
name: 'description'
},
{
name: 'type'
}
],
idProperty: 'id',
proxy: new Ext.data.HttpProxy({
url: this.url,
method: 'GET',
listeners:{
beforeload:{
scope:this,
fn:function(dp, params){
if(dp.activeRequest['read']){
dp.activeRequest['read'].conn.abort();
}
}
}
}
}),
root: 'items',
totalProperty: "totalResultsAvailable"
});
this.tpl = new Ext.XTemplate('<tpl for="."><div class="remote-server-finder-item finder-item x-combo-list-item">',
'<div class="remote_server_finder_text finder_text">', '<h2 class="name">{name}</h2>', '<p class="description">{description}</p>', '</div>', '</div></tpl>');
);
}
相关文章:
- 节点导出返回一个空对象
- ES6构造函数返回基类的实例
- 监视函数从服务返回不起作用,但作用域函数起作用
- 控制台返回var不是't定义,但它是
- 从函数返回角度承诺
- Javascript返回值只在循环中返回一次
- 从控制器返回后Ajax启动事件激发
- CKFinder 3为所选文件返回错误的URL
- 如何在d3.js中返回路径的y坐标
- 如何从jquery函数返回变量
- Angular js-返回一个包含类似
- JSONP请求返回结果,但也触发error_callback
- 如何使用Spring MVC将Facebook返回的响应数据保存在Java类中
- 从HTTPGET返回一个自定义对象列表,以便在Angular 2应用程序中使用
- JS验证ajax返回的html中的表单数据
- 使用谷歌应用程序脚本将服务器端数据表返回到客户端
- AJAX:$_GET不返回任何值
- 从Javascript方法返回全局变量
- Meteor方法在客户端返回null,在客户端运行的相同方法返回正确的值
- 更改组合框分页后,getValue和getRawValue返回相同的值