[JBoss JIRA] (RF-12098) PickList doesn't accept comma in string value
by Stefan Risto (JIRA)
Stefan Risto created RF-12098:
---------------------------------
Summary: PickList doesn't accept comma in string value
Key: RF-12098
URL: https://issues.jboss.org/browse/RF-12098
Project: RichFaces
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: component-selects
Affects Versions: 4.2.0.Final
Reporter: Stefan Risto
The rich:pickList Component does not handle values containing commas.
I used a converter and in the getAsString - Method a String containing a comma was returned, such as "You,Me". After selecting this value in the pick list the converters getAsObject method is called twice, once for "You" and once for "Me".
I would expect to get the same value in getAsObject as the converters getAsString returned. Maybe the comma should be escaped by the component and/or the javascript code.
This Bug seems to be related to RF-6766, but that bug is not targeted for RF 4.X
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 9 months
[JBoss JIRA] (RF-12096) Push: there is delay between repeated subscribtion
by Lukáš Fryč (JIRA)
Lukáš Fryč created RF-12096:
-------------------------------
Summary: Push: there is delay between repeated subscribtion
Key: RF-12096
URL: https://issues.jboss.org/browse/RF-12096
Project: RichFaces
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: component-push/poll
Affects Versions: 4.2.0.Final
Reporter: Lukáš Fryč
When you have conditionally rendered {{a4j:push}} component and you disable it,
then it stops to receive push events.
Once you enable it, there is delay before it will start to receive events again.
Sample code for reproduction:
{code:xml}
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core" xmlns:a4j="http://richfaces.org/a4j">
<f:view>
<h:head>
</h:head>
<h:body>
<h:form>
<br /><br /><br /><br />
<!-- PUSH 1 -->
<a4j:commandButton value="Push 1!" action="#{richBean.push}" />
<a4j:outputPanel id="pushPanel">
<a4j:push id="push" rendered="#{not pushDisabled}" address="sampleAddress" ondataavailable="$('*[id$=outputDate]').text(event.rf.data)" onsubscribed="alert('subscribed')" />
</a4j:outputPanel>
<a4j:outputPanel id="pushDisablementPanel">
<h:selectBooleanCheckbox value="#{pushDisabled}">
<a4j:ajax render="pushPanel pushDisablementPanel" />
</h:selectBooleanCheckbox>
<h:outputText value="#{pushDisabled ? 'disabled' : 'enabled'}" />
</a4j:outputPanel>
<br />
<a4j:outputPanel id="outputDate">
#{richBean.date}
</a4j:outputPanel>
<br />
</h:form>
</h:body>
</f:view>
</html>
{code}
{code:java}
package demo;
import java.util.Date;
import javax.faces.bean.ManagedBean;
import org.richfaces.application.push.MessageException;
import org.richfaces.application.push.TopicKey;
import org.richfaces.application.push.TopicsContext;
@ManagedBean
public class RichBean {
public Date getDate() {
return new Date();
}
public void push() throws MessageException {
TopicKey topicKey = new TopicKey("sampleAddress");
TopicsContext topicsContext = TopicsContext.lookup();
topicsContext.publish(topicKey, new Date().toString());
System.out.println("push event");
}
}
{code}
Steps to reproduce:
1. open the sample page (the "subscribed" message appears)
2. click on Push! button (the date is changed)
3. check the checkbox
4. click on Push! button (the date is not changed anymore)
5. uncheck the checkbox (the "subscribed" message appears again)
6. click on Push!
EXPECTED: the date should be changed
ACTUAL: the date is not changed
If you will wait for some seconds, the Push! button will cause change of the date,
but in this delay, client can lose data updates (since "subscribed" event does not show that the client is starting to receive data).
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 9 months
[JBoss JIRA] (RF-12040) Multi-form document - command button (submit) does not work after rendering
by Jean ANDRE (JIRA)
Jean ANDRE created RF-12040:
-------------------------------
Summary: Multi-form document - command button (submit) does not work after rendering
Key: RF-12040
URL: https://issues.jboss.org/browse/RF-12040
Project: RichFaces
Issue Type: Bug
Security Level: Public (Everyone can see)
Environment: cssparser-0.9.6 - guava-11.0.1 - hibernate-validator-4.2.0.Final - JSF/Mojarra 2.1.6 - springframework-3.0.6.RELEASE - sac-1.3 - Windows 7 - FireFox 10 - RichFaces 4.2 Final
Reporter: Jean ANDRE
We have one page that contains two forms. The first form contain a menus bar (ajax switchType) while the second contains a tabPanel (also in ajax switchType). When a user select a menu, we select the corresponding tab that contains a submit button. Once the tab is selected, the submit button does not work. We have to click twice for submitting.
1) If we move the menu bar inside the second forms, it is working.
2) If we set the menu bar in client switchType, selecting the menu doesn't do anything.
3) If we set the menu bar in server switchType it's working.
As the rendering is well executed, the submit button should works but is not whatever we set as render="@all, or any valid id".
We have prepared a small application that demonstrates the case. This is a simple but realistic application. Edit the index.xhtml to play with the menu. Let us know if we doing something wrong.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 9 months
[JBoss JIRA] (RF-12104) BeanValidator: label not handled using MessageFactory
by Markus Staab (JIRA)
Markus Staab created RF-12104:
---------------------------------
Summary: BeanValidator: label not handled using MessageFactory
Key: RF-12104
URL: https://issues.jboss.org/browse/RF-12104
Project: RichFaces
Issue Type: Bug
Security Level: Public (Everyone can see)
Affects Versions: 3.3.3.Final
Environment: Liferay 5.2.4, Portlet 2.0, JSF 1.2
Reporter: Markus Staab
The BeanValidator, in contrast to most JSF validators e.g. LongRangeValidator, does not use the MessageFactory to handle validation error message.
see LongRangeValidators' validate-method:
{code}
....
throw new ValidatorException(MessageFactory.getMessage
(context,
NOT_IN_RANGE_MESSAGE_ID,
stringValue(component, minimum, context),
stringValue(component, maximum, context),
MessageFactory.getLabel(context, component)));
...
{code}
Therefore error-message of a BeanValidator will neither prepand the String which is provided from the components' label-attribute nor the components' client id.
see BeanValidator's validate & extractMessages-method
{code}
....
private Collection<String> extractMessages(Set<ConstraintViolation<Object>> violations) {
Collection<String> messages = null;
if (null != violations && violations.size() > 0) {
messages = new ArrayList<String>(violations.size());
for (ConstraintViolation<? extends Object> constraintViolation : violations) {
messages.add(constraintViolation.getMessage());
}
}
return messages;
}
...
{code}
All error messages are taken 1:1 from the BeanValidator.
While e.g. the error-message of LongRangeValidtor looks like "Startdate: Value is greater than allowable maximum of ''{0}''." the error looks like "Value is greater than allowable maximum of ''{0}''.".
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 9 months