PDA

View Full Version : How transport combobox value to url (proxy) - sencha 4



jorgepereira.eng
2 Jan 2012, 5:12 AM
Hi everybody,

I would like to transport a value from a combobox to an url.

I have tried this, but d'ont works:


...
...
var mycombo = Ext.create('Ext.form.ComboBox', {
id: 'mycombo',
fieldLabel: 'Campaign',
displayField: 'col1',
valueField: 'col2',
store: campaign,
triggerAction: 'all',
autoHeight: true
});
...
var myproxy = new Ext.data.HttpProxy({
extraParams: { "campaign": Ext.getCmp('mycombo').getValue() },
url: 'getReport.ashx',
reader: new Ext.data.JsonReader({
type: 'json',
root: 'data',
totalProperty: 'totalCount'
})
});

Any ideas...i need help!!!:((

mitchellsimoens
2 Jan 2012, 6:25 AM
Please post in the appropriate forum. I have moved this to the Ext JS 4 Q&A forum for you.
What is the value of the combobox when you try to get it?
You should use Ext.data.proxy.Ajax and not Ext.data.HttpProxy.
Please always wrap your code in code tags.

jorgepereira.eng
2 Jan 2012, 8:18 AM
Please post in the appropriate forum. I have moved this to the Ext JS 4 Q&A forum for you.
What is the value of the combobox when you try to get it?
You should use Ext.data.proxy.Ajax and not Ext.data.HttpProxy.
Please always wrap your code in code tags.


1. Sorry and Thanks.
2. The parameter campaign reach the Handler with null value.
3. Ok, but is that relevante for my issue?
4. OK. Sorry again.

ThulgalaphJah
2 Jan 2012, 8:39 AM
http://www.louisvuittonreplicanew.com/ louis vuitton knockoff