Hi,
I've got a search page with some select boxes and a search button.
Upon a search the data model list is filled and a series of action buttons below
is enabled or disabled depending on the values that have been
selected in the h:selectOneMenu lists.
So far so good. I wanted to automate this by rerendering the result list
and the buttons every time the user selects another entry:
anonymous wrote :
| <h:selectOneMenu value="#{arztAbrechnung.krankenhaus}" id="krankenhaus">
|
<s:selectItems value="#{arztAbrechnung.krankenhausData}"
var="krankenhaus" label="#{krankenhaus.name}" id="krankenhausItems" />
| <a4j:support eventsQueue="queue" requestDelay="100" event="onchange"
action="#{arztAbrechnung.suche}" reRender="leistungen,excelExport"/>
|
| <s:convertEntity />
| </h:selectOneMenu>
|
Some where below there is the data table and the button:
anonymous wrote :
| <t:dataTable var="l" value="#{leistungenSuche}" rows="10"
rowClasses="odd-row, even-row" id="leistungen"
| renderedIfEmpty="false"
| sortable="true"
|
sortColumn="#{arztAbrechnung.sortColumn}"
|
sortAscending="#{arztAbrechnung.sortAscending}"
| preserveDataModel="false"
| preserveSort="true"
| >
| ....
|
| <s:button id="excelExport" target="contentWindow" view="/content/data"
value="Export Arzt-Abrechnung"
|
rendered="#{leistungenSuche.rowCount > 0}" disabled="#{not
arztAbrechnung.arztAbrechnung}">
| <f:param name="dataId"
value="exportExcelArztAbrechnung"/>
| </s:button>
|
Alas, this does not work correctly. When I choose an item in the select list,
the result list and the button are indeed rerendered. However, I can not click
the button since as the source code of the page reveals, the button's property
"disabled" is still set (to the value "disabled").
I'm not sure whether this due to Seam or A4JSF. I tried with the latest version
1.1.1 of A4J. How can I make sure the disabled flag is also reset?
It depends on a query to the bean which in turn takes a look at the selected
values. May there be some problem in the order in which everything gets
executed?
Cheers
Markus
P.S. The button is *rerendered* correctly, i.e. it is not gray anymore, but not
clickable
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4076261#4076261
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4076261
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user