[
https://jira.jboss.org/jira/browse/RF-5592?page=com.atlassian.jira.plugin...
]
Igor Dikhtyaruk commented on RF-5592:
-------------------------------------
Hi,
Ok, the example with <ui:repeat> may be incorrect. But, will you consider that the
following example is correct:
<h:inputText id="text" value="#{myBean.texts[0]}">
<a4j:support
ajaxSingle="true"
event="onchange"
reRender="text"
bypassUpdates="true"/>
</h:inputText>
We don't want to update the model with the invalid value, we just want to check if
it's valid. That example works.
With <a4j:repeat> (if you put the above inputText inside of the repeater) this
becomes impossible.
Just to be consistent with the stand alone input control the repeater should re-render the
new value, even if bypassUpdates="true", should'nt it?
Thanks,
Igor
User is unable to update the text in the input field, if this field
is inside of <a4j:repeat> and <a4j:support> is used to re-Render that field
-----------------------------------------------------------------------------------------------------------------------------------------------
Key: RF-5592
URL:
https://jira.jboss.org/jira/browse/RF-5592
Project: RichFaces
Issue Type: Bug
Affects Versions: 3.2.2
Reporter: Igor Dikhtyaruk
Assignee: Tsikhon Kuprevich
example:
xhtml:
<a4j:repeat value="#{myBean.texts}" rowKeyVar="index">
<h:inputText id="text" value="#{myBean.texts[index]}">
<a4j:support
ajaxSingle="true"
event="onchange"
reRender="text"
bypassUpdates="true"/>
</h:inputText>
</a4j:repeat>
Java bean:
package au.gov.austrac;
import java.util.Arrays;
import java.util.Date;
import java.util.List;
import org.jboss.seam.ScopeType;
import org.jboss.seam.annotations.Name;
import org.jboss.seam.annotations.Scope;
@Name("myBean")
@Scope(ScopeType.SESSION)
public class MyBean {
private List<String> texts = Arrays.asList(new String[]{"First"});
public List<String> getTexts() {
return texts;
}
public void setTexts(List<String> texts) {
this.texts = texts;
}
}
BTW,
the following works well:
<ui:repeat value="#{myBean.texts}">
<h:inputText id="text" value="#{myBean.texts[0]}">
<a4j:support
ajaxSingle="true"
event="onchange"
reRender="text"
bypassUpdates="true"/>
</h:inputText>
</ui:repeat>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira