[
https://issues.jboss.org/browse/RF-10951?page=com.atlassian.jira.plugin.s...
]
Lukáš Fryč commented on RF-10951:
---------------------------------
Hi Richard, I have debugged your sample and got final conclusion, there are actually two
things wrong.
You are generating panels for "viewing" mode and they got j_id23 and j_id25 ids
implicitly. But when you are switching to "editation" mode, you are creating new
tab which will got j_id54. The current tab is described by tab name, which defaults to tab
id. So when tabPanel tries to discover second tab with name=j_id25 it doesn't find and
fails with NPE on check item.isDisabled().
You should rather:
1. reuse the second tab and populate it with new components
2. use explicit names which will not dependent on ids
But it changes nothing on fact that I will rewrite the condition on disabled more
defensively.
Dynamically created components lose CSS/JavaScript on POSTback
--------------------------------------------------------------
Key: RF-10951
URL:
https://issues.jboss.org/browse/RF-10951
Project: RichFaces
Issue Type: Bug
Security Level: Public(Everyone can see)
Affects Versions: 4.0.0.Final
Reporter: Richard Kennard
Assignee: Lukáš Fryč
Fix For: 4.1.0.Milestone1
Attachments: addressbook-myfaces2-richfaces.war,
RichFacesDynamicComponentTest.zip
Hi guys,
First, thanks for a great release in RichFaces 4!
I have come across (what I think is) a bug and have put together a small test app that
reproduces it. RichFaces components that are creating dynamically (programmatically)
using...
application.createComponent( context, componentType, rendererType )
...do not automatically re-inject their CSS/JavaScript resources into <h:head/>
following a POSTback. For example, if an incorrect value is entered into a field and a
validation error occurs, no programmatically created RichFaces components work when
redisplayed. In fact, they may not redisplay at all (having lost their CSS).
--
This message is automatically generated by JIRA.
For more information on JIRA, see:
http://www.atlassian.com/software/jira