[JBoss JIRA] Created: (RF-11365) onbeforedomupdate and oncomplete not working in Portlet environment
by Detlef Pleiss (JIRA)
onbeforedomupdate and oncomplete not working in Portlet environment
-------------------------------------------------------------------
Key: RF-11365
URL: https://issues.jboss.org/browse/RF-11365
Project: RichFaces
Issue Type: Bug
Security Level: Public (Everyone can see)
Affects Versions: 4.0.0.Final
Reporter: Detlef Pleiss
example page:
<ui:composition 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"
xmlns:rich="http://richfaces.org/rich">
<h:head/>
<h:form>
<h:panelGrid columns="2">
<h:outputText value="Text:" />
<h:inputText value="#{echoBean.text}" >
<a4j:ajax event="keyup"
onbeforesubmit="alert('beforesubmit')"
onbegin="alert('begin')"
onbeforedomupdate="alert('beforedomupdate')"
oncomplete="alert('complete')"
render="text,count" listener="#{echoBean.countListener}"/>
</h:inputText>
<h:outputText value="Echo:" />
<h:outputText id="text" value="#{echoBean.text}" />
<h:outputText value="Count:" />
<h:outputText id="count" value="#{echoBean.count}" />
</h:panelGrid>
</h:form>
</ui:composition>
The alerts for onbeforedomupdate and oncomplete do not appear in a portal environment; they do in a non-portal web environment.
The Ajax XML response in a non portal web environment contains the tag <extension id="org.richfaces.extension"> with the Javascript code from the named attributes.
But, in a portal environment the id gets prefixed like i.e. <extension id="A3331org.richfaces.extension">
In fact Richfaces asks for this prefix in richfaces-core-api-4.0.0.Final-sources : org.richfaces.renderkit.util.CoreAjaxRendererUtils.java
line 96 by calling facesContext.getExternalContext().encodeNamespace(EXTENSION_ID))
In a Servlet environment this leaves EXTENSION_ID = "org.richfaces.extension" unchanged, but in a Portlet environment its function is to
"Return the specified name, after prefixing it with a namespace that ensures that it will be unique within the context of a particular page" (quoted from Javadoc).
Only, the Javascript meant to react on the extension tag is hardcoded to react on the ID "org.richfaces.extension" only without any prefix:
META-INF/resources/richfaces.js line 333 :
var getExtensionResponseElement = function(responseXML) {
return jQuery("partial-response extension#org\\.richfaces\\.extension", responseXML);
};
So, in a Portlet environment the partial-response/extension is ignored due to the prefixed ID.
A possible solution might be to have the Javascript accept any prefix in front of the ID, like:
var getExtensionResponseElement = function(responseXML) {
return jQuery("partial-response extension[id$='org\\.richfaces\\.extension']", responseXML);
};
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 6 months
[JBoss JIRA] (RF-12271) Generation of custom tag for converter is not available
by Marek Novotny (JIRA)
Marek Novotny created RF-12271:
----------------------------------
Summary: Generation of custom tag for converter is not available
Key: RF-12271
URL: https://issues.jboss.org/browse/RF-12271
Project: RichFaces
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: cdk
Affects Versions: 4.2.2.Final
Reporter: Marek Novotny
Seam 2.2 has got faces-config.xml CDK 3 proprietary template for generation of custom tags for custom converters. CDK 4 this doesn't allow if you use @JsfConverter annotation.
Link to real config - https://anonsvn.jboss.org/repos/seam/branches/community/Seam_2_2/ui/src/m...
<snip>
{code:xml}
<components>
...
<converter generate="false">
<id>org.jboss.seam.ui.DateTimeConverter</id>
<classname>org.jboss.seam.ui.converter.DateTimeConverter</classname>
<description>
<![CDATA[Perform date or time conversions in the Seam timezone.]]>
</description>
<tag>
<name>convertDateTime</name>
<classname>org.jboss.seam.ui.taglib.ConvertDateTimeTag</classname>
<superclass>
javax.faces.webapp.ConverterELTag
</superclass>
</tag>
...
</converter>
...
</components>
{code}
</snip>
It is clear that JSF2 can use <f:converter id="org.jboss.seam.ui.DateTimeConverter"/> instead of creating custom tag, but you may need some additional things to add to custom tag like attributes etc.
--
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, 6 months
[JBoss JIRA] (RF-12210) _Lang.byId - reference a reference node or an identifier must be passed
by Jean ANDRE (JIRA)
Jean ANDRE created RF-12210:
-------------------------------
Summary: _Lang.byId - reference a reference node or an identifier must be passed
Key: RF-12210
URL: https://issues.jboss.org/browse/RF-12210
Project: RichFaces
Issue Type: Bug
Security Level: Public (Everyone can see)
Affects Versions: 4.2.0.Final
Environment: FireFox 12 or 8.0.7601 - GlassFish 3.1.2 - Mojarra 2.1.7 - Windows 7
Reporter: Jean ANDRE
We got the following javascript error message under firebug:
_Lang.byId: reference un noeud de référence ou un identifiant doit être passé -
jsf.js.jsf?ln=javax.faces (ligne 1).
Under IE the error message is:
Message : Erreur non spécifiée.
Ligne : 1
Caractère : 37254
Code : 0
URI : http://localhost:8080/NestedWeb/javax.faces.resource/jsf.js.jsf?ln=javax....
At this code:
){throw this.makeException(new Error(),null,null,this._nameSpace,"byId",this.getMessage("ERR_REF_OR_ID",null,"_Lang.byId","reference"));
This error did not appear in previous version of JSF - More over we have also new another error related to
<rich:tab id="#{tab.id}" onenter="enterTab('#{tab.id}');" headerClass="tab-header">
The error occurs when we want to close a dynamic tab.
--
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, 6 months
[JBoss JIRA] (RF-12286) selectOneMenu with f:ajax cause a OutOfMemory under IE and slowdown under Firefox - listener
by Jean ANDRE (JIRA)
Jean ANDRE created RF-12286:
-------------------------------
Summary: selectOneMenu with f:ajax cause a OutOfMemory under IE and slowdown under Firefox - listener
Key: RF-12286
URL: https://issues.jboss.org/browse/RF-12286
Project: RichFaces
Issue Type: Bug
Security Level: Public (Everyone can see)
Affects Versions: 4.2.2.Final
Environment: JSF Mojarra 2.1.7 - FireFox 12 or IE 8 - annotations-4.2.0.Final - aspectjrt-1.6.12 - cglib-nodep-2.2.2 - commons-collections-3.2.1 - commons-lang-2.4 - commons-logging-1.1.1 - commons-validator-1.4.0 - cssparser-0.9.6 - guava-11.0.1 - hibernate-validator-4.2.0.Final - junit-4.10 - log4j-1.2.16 - org.springframework.xxx-3.0.6.RELEASE - richfaces-xxxx-xxx-4.2.0.Final - sac-1.3 - slf4j-api-1.6.4 - slf4j-log4j12-1.6.4
Reporter: Jean ANDRE
Priority: Critical
We got an "Out of memory at line 249" under IE and a deep slowdown when we use f:ajax with <h:selectOneMenu> tag.
{code}
<h:selectOneMenu id="McMpList" value="#{currentUser.businessUnit}" immediate="true">
<f:ajax event="change" listener="#{menuController.doChangeDesktop}" render="@all" />
<f:selectItems value="#{menuController.businessUnits}" />
</h:selectOneMenu>
{code}
When we remove the f:ajax, the behavior is "normal".
--
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, 6 months