You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by "Peter Mahoney (JIRA)" <my...@incubator.apache.org> on 2005/07/19 16:37:48 UTC

[jira] Updated: (MYFACES-337) Nested dataTable buttons not working

     [ http://issues.apache.org/jira/browse/MYFACES-337?page=all ]

Peter Mahoney updated MYFACES-337:
----------------------------------

    Attachment: testtable.zip

The attached zip contains the files necessary to reproduce the problem. Click the button and the answer text values are replaced.

> Nested dataTable buttons not working
> ------------------------------------
>
>          Key: MYFACES-337
>          URL: http://issues.apache.org/jira/browse/MYFACES-337
>      Project: MyFaces
>         Type: Bug
>     Versions: Nightly Build
>     Reporter: Peter Mahoney
>     Assignee: Mathias Broekelmann
>  Attachments: testtable.zip
>
> Buttons within a nested dataTable always call the action methods bound to the first row of the outer table:
> For example, using the JSP below, if the delete button is clicked for the third answer of question 2, answer.deleteAnswer() is called on the third answer of question 1 instead.
> <h:dataTable value="#{handler.poll.questions}" var="question">
> 	<h:column> 
> 		<h:dataTable value="#{question.answers}" var="answer">
> 			<h:column>
> 				<h:outputLabel for="answerText" value="Q#{question.questionNumber} A#{answer.answerNumber}"/>
> 				<h:inputText id="answerText" value="#{answer.text}"/>
> 			</h:column>
> 			<h:column>
> 				<h:commandButton action="#{answer.deleteAnswer}" value="Delete"/>
> 			</h:column>
> 		</h:dataTable>    
> 	</h:column>
> </h:dataTable>
> Probably related is that the text of all other answers for the first question becomes the text from the last answer of the last question following clicking on the delete button. This did not occur using the RI.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira