Page 1 of 1

personalize query combo

Posted: Tue May 30, 2017 9:12 am
by gnweb
Hi!
I need to customize the values displayed in a combo. In a table there are three fields (id, type, client). The "type" field identifies the type of customer. In a combo, I only want to display clients with the type = 3 field, for example. How can I do? The following code displays all records in the table clients:

items:[{
xtype:'combo',
fieldLabel: GO.clients.lang.idclient,
hiddenName:'idclient',
anchor:'100%',
emptyText:GO.lang.strPleaseSelect,
store: new GO.data.JsonStore({
url: GO.url('clients/client/store'),
baseParams: {
permissionLevel:GO.permissionLevels.write
},
fields: ['idclient', 'clientname']
}),
valueField:'idclient',
displayField:'clientname',
triggerAction: 'all',
editable: true,
forceSelection: true,
allowBlank: false
}]

Any suggestions? Thank you.