var remoteLookupJsonStore = new Ext.data.JsonStore({
root : 'records',
baseParams : {
column : 'fullName'
},
fields : [
{
name : 'name',
mapping : 'fullName'
},
{
name : 'id',
mapping : 'id'
}
],
proxy : new Ext.data.ScriptTagProxy({
url : 'LookupLoader.ashx'
//url: 'http://tdg-i.com/dataQuery.php' similar data
})
});
var combo2 = {
xtype : 'combo',
fieldLabel : 'Search by name',
forceSelection : true,
displayField : 'name',
valueField : 'id',
hiddenName : 'customerId',
loadingText : 'Querying....',
minChars : 1,
triggerAction : 'name',
store : remoteLookupJsonStore
};
This sample works with the original data store 'http://tdg-i.com/dataQuery.php'. My ashx handler returns data in the same format, but the data is different. Anyhow, when I use my ashx handler, the handler gets invoked, it returns data, but combo always stays in the loading state, and never displays the data. I am assuming that the problem is with the data I am returning, but its format is fine,the last thing I changed was setting the Content Type
context.Response.ContentType = "application/json";
but I still cannot get this thing to work, any suggestions?
this is data coming from my handler.
({"totalCount": "4","records":[{"id":1,"fullName": "aaa bbb"},{"id":2,"fullName":"cc dd"},{"id":3,"fullName":"ee ff"},{"id":4,"fullName":"gg hh"}]});