Forum /
Ext JS 2.x - Unsupported /
Ext 2.x: Help & Discussion /
How to make a call to a spring bean??
How to make a call to a spring bean??
Hello!
I am totally new at Ext and I am working on an application with Spring + DWR + Ext 2.0 + Java... bla bla bla... but I am just starting and I would like to know how could I make a call to a BEAN defined on my app-servlet.xml from a handler I have defined for a button which is not in a Form.
Thank you!
/*app-servlet.xml */
----------
<bean name="/generarInforme.htm" class="org.sescam.cardio.control.InformesControl">
</bean>
---------
/** js code **/
/** ******** Genera Informes ********* */
generaInforme: function(){
( here is where I need the code )
}
----------
/**this code is part of a FormPanel ***/
items: [{
xtype: 'button',
text: 'Imprimir',
id: 'btnImprimir',
handler: this.generaInforme
}]
}
I am getting different errors trying things like :
/** ******** Genera Informes ********* */
generaInforme: function(){
Ext.data.HttpProxy({url: 'generarInforme.htm'})
}
in the way...
in the way...
Ok, I did this and now it seems it redirects... but NOWHERE... jejeje
I added this:
***********************************
crearPanelCabecera: function(){
this.cabecera = new Ext.FormPanel({
frame: true,
id: 'cabecera',
renderTo: 'cabeceraPrincipal',
submit: function() {
this.getForm().getEl().dom.action ='/generarInforme.htm';
this.getForm().getEl().dom.value="Execute";
this.getForm().getEl().dom.submit();
},
*************************
generaInforme: function(){
panelPrincipal_cabeceraPincipal.cabecera.submit();
}
*****************************
layout: 'form',
items: [{
xtype: 'button',
text: 'Imprimir',
id: 'btnImprimir',
handler: this.generaInforme
}]
}
*********************
I must have a problem with spring or I dont know... I was used to use struts and I want to do the same effect as with *.do but I dont know how...
Sencha is used by over two million developers. Join the community, wherever you’d like that community to be
or Join Us