Home  >  Article  >  Web Front-end  >  ext combox drop-down box does not appear automatically prompt, automatic selection solution_extjs

ext combox drop-down box does not appear automatically prompt, automatic selection solution_extjs

WBOY
WBOYOriginal
2016-05-16 18:34:041582browse

Look at the code

Copy the code The code is as follows:

var comboxContractType = new Ext.form.ComboBox( {
name:'logisticsId',
fieldLabel:'logistics company',
displayField:'logisticsName',
valueField:'logisticsId',
emptyText:'Please select',
width:330,
editable:true,
allowBlank:false,
mode:'local',
loadingText:'loading...',
hiddenName:'logisticsId',
//pageSize:10,
selectOnFocus: true,
triggerAction:'all',
store:comboxContractTypeStore = new Ext.data.JsonStore({
url:'/pcms/dictionary/ logistics.do?method=findLogistics',
root:'Datas',
totalProperty: 'TotalRecords',
fields:[
{name:'logisticsId', mapping:'logisticsid'},
{name:'logisticsName', mapping:'shortname'}
]
})
});
comboxContractTypeStore.load({params:{start:0,limit:100} });


Note 3 points:

Don’t set the PageSize attribute
Set the mode attribute to local local mode
Finally, you need to manually change the strobe used Perform load operation. stoe.load();
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn