[JBoss JIRA] Created: (RF-9078) Rendered attribute on treenode not working correctly
by Thomas Andergassen (JIRA)
Rendered attribute on treenode not working correctly
----------------------------------------------------
Key: RF-9078
URL: https://jira.jboss.org/browse/RF-9078
Project: RichFaces
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: component-tree
Affects Versions: 3.3.3.Final
Environment: Jboss application server on Linux and Firefox 3.6.8
Reporter: Thomas Andergassen
I implemented a tree with treenodeadaptors and am trying to only show nodes, the user has permission to.
<rich:tree style="margin-top:20px" stateAdvisor="#{techTreeStateAdvisor}" preserveModel="ajax">
<rich:treeNodesAdaptor id="cps" nodes="#{cpList.resultList}" var="cps">
<rich:treeNode>
<h:outputText value="#{cps.name}" />
</rich:treeNode>
<rich:treeNodesAdaptor id="drd" nodes="#{cps.drd}" var="drds">
<rich:treeNode>
<h:outputText value="#{drds.name}" />
</rich:treeNode>
<rich:treeNodesAdaptor id="sns" nodes="#{drds.sns}"
var="sns">
<rich:treeNode rendered="#{s:hasPermission(sns,'read')}" >
<h:commandLink action="#{snsView.view(sns)}" value="#{sns.name}" rendered="#{s:hasPermission(sns,'read')}">
</h:commandLink>
</rich:treeNode>
</rich:treeNodesAdaptor>
</rich:treeNodesAdaptor>
</rich:treeNodesAdaptor>
</rich:tree>
The problem is, when the user has no right to see, the node is rendered anyway as text, but not as link. If I remove the rendered attribute from the treeNode, it shows me a node image, but no link or text, as the commandlink isn't rendered. Even setting rendered to false directly doesn't help.
I couln't find anything that tells me if this behavior is normal
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
15 years, 4 months
[JBoss JIRA] Created: (RF-8136) Richfaces.Calendar.parseDate using pattern "yyMMdd" is incompatible with java.text.SimpleDateFormat
by Francisco Jose Peredo Noguez (JIRA)
Richfaces.Calendar.parseDate using pattern "yyMMdd" is incompatible with java.text.SimpleDateFormat
---------------------------------------------------------------------------------------------------
Key: RF-8136
URL: https://jira.jboss.org/jira/browse/RF-8136
Project: RichFaces
Issue Type: Bug
Affects Versions: 3.3.1
Reporter: Francisco Jose Peredo Noguez
I have a rich calendar configured with the pattern "yyMMdd"
If the user writes 600210 and the user clicks the little calendar button to show the popup, he can see that the date has been translated to "February 10 of 2060" but if he writes 700210 it is translated in to "February 10 of 1970". That is not consistent the behavior of java.text.SimpleDateFormat.
The problem is at the file 3.3.1.GA\ui\calendar\src\main\resources\org\richfaces\renderkit\html\scripts\calendar.js (line 394 of the file):
At the function Richfaces.Calendar.parseDate = function(dateString, pattern, monthNames, monthNamesShort) method:
var yy = parseInt(match[y],10); if (isNaN(yy)) return null; else if (yy<70) yy+=2000; else if (yy<100) yy+=1900;
That code translates the year in 600210 to 2060 when it should translate it to 1960 (to be consistent with java.text.SimpleDateFormat behavior.
--
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
15 years, 4 months