struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alvaro Sanchez-Mariscal" <alvaro.sanc...@salenda.es>
Subject Re: [S2][Tabbed panel] posting data from one tab
Date Sun, 19 Aug 2007 14:31:52 GMT
Try prepending an slash, ie, "/addProduct". Without it, it also didn't
worked to me.

Also, what happens exactly? Javascript errors? Have you tried
inspecting it with firebug?

Alvaro.

On 8/19/07, Eugen Stoianovici <eugen.stoianovici@gmail.com> wrote:
> Alvaro Sanchez-Mariscal wrote:
> > Hi,
> >
> > I've done the same using topics:
> >
> > 1) Publish on a topic after the request is executed (eg,
> > notifyTopics="/submit" in the s:submit).
> >
> > 2) Register to the same topic in the s:div corresponding to the tab
> > (eg, listenTopics="/submit" in the s:div).
> >
> > Alvaro.
> >
> >
> Can you give me an example? what i did was:
>
> the master file: (the one where i define the tabbedpanel)
>     <s:tabbedPanel id="tabbedpanel">
>         <s:div id="vendor" label="Vendor" href="%{#vendor_tab}"
> theme="ajax" />
>         <s:div id="shipment" label="Shipment" href="%{#shipment_tab}"
> theme="ajax"  />
>         <s:div id="products" label="Products" href="%{#products_tab}"
> theme="ajax" listenTopics="addProduct" />
>     </s:tabbedPanel>
>
>
> the add product form:
>
> <s:form action="addproduct" validate="true">
>     <s:textfield id="description" name="product.description"
>         label="Description" />
>     <s:textfield id="quantity" name="product.quantity" label="Quantity" />
>     <s:textfield id="taxrate" name="product.taxRate" label="Tax Rate" />
>     <s:textfield id="unitprice" name="product.unitPrice" label="Unit
> Price" />
>     <s:submit value="Add" notifyTopics="addProduct" />
> </s:form>
>
>
> Now, is there anything else i need to do in my action class or in those
> two jsp's? Because it doesn't work like this :(
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>


-- 
Alvaro Sanchez-Mariscal
Arquitecto de Software Java EE
Salenda - www.salenda.es
Avd. Rey Juan Carlos I, 92. 28916 - Legan├ęs (Madrid).
T: 91 101 0607 ext. 301 / F: 91 101 0608
M: +34.647.94.44.30
E: alvaro.sanchez@salenda.es

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message