myfaces-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Madhav Bhargava" <unmarsh...@gmail.com>
Subject Re: Problem
Date Fri, 26 Jan 2007 21:35:32 GMT
I did not clearly understand your problem.
You can try putting t:saveState for the lists defined in the backing bean

Also there is a better way to submit a form on change of selection in the
list or for that matter any input field
Try using sandbox <s:submitOnEvent>

~madhav

On 1/27/07, urswagner@bluemail.ch <urswagner@bluemail.ch> wrote:
>
> My problem is I have a select menu and three listboxes in the page.
> The control content should be loaded from top to down resp. left
> to
> right.
> Unfortunately thie control content is always ereased.
> I use internal bean properties topCatId, firstCatId, ...
> thirdCatId. These properties are equal 0 after each submit.
> I think this should be work, why it doesn't, I do not understand.
>
>   <managed-bean>
>     <managed-bean-name>sellArticle</managed-bean-name>
>     <managed-bean-class>org.troedel.bean.SellArticleBean</managed-
> bean-class>
>     <managed-bean-scope>request</managed-bean-scope>
>   </managed-bean>
>
> <f:view>
> <f:loadBundle basename="org.troedel.resource.TextResources" var="
> text" />
> <h:form>
> <h:outputText value="#{text.maincategory}:" />
> <h:selectOneMenu onchange="submit();" valueChangeListener="#
> {sellArticle.selectedTopCatChanged}">
> <f:selectItems value="#{sellArticle.selectTopCat}" />
> </h:selectOneMenu>
> </h:form>
> <br/>
> <h:outputText value="#{text.choosecategories}" />
> <table>
> <tr>
> <td>
> <h:form>
> <h:selectOneListbox size="8" onchange="submit();"
> valueChangeListener="#{sellArticle.selectedFirstChanged}">
> <f:selectItems value="#{sellArticle.selectFirstCat}" />
> </h:selectOneListbox>
> </h:form>
> </td>
> <td>
> <h:form>
> <h:selectOneListbox size="8" onchange="submit();"
> valueChangeListener="#{sellArticle.selectedSecondChanged}">
> <f:selectItems value="#{sellArticle.selectSecondCat}" />
> </h:selectOneListbox>
> </h:form>
> </td>
> <td>
> <h:form>
> <h:selectOneListbox size="8" onchange="submit();"
> valueChangeListener="#{sellArticle.selectedSecondChanged}">
> <f:selectItems value="#{sellArticle.selectThirdCat}" />
> </h:selectOneListbox>
> </h:form>
> </td>
> </tr>
> </table>
> </f:view>
>



-- 
When I tell the truth, it is not for the sake of convincing those who do not
know it, but for the sake of defending those that do

Mime
View raw message