Details
-
Type: Bug
-
Status: Closed
-
Priority: Major
-
Resolution: Fixed
-
Affects Version/s: 3.3
-
Fix Version/s: EE-3.3.0.GA, 4.0.BETA, 4.0
-
Component/s: ACE-Components
-
Labels:None
-
Environment:ICEfaces 3, ace:tree, single select mode
-
Assignee Priority:P1
-
Workaround Description:
Description
QA reports the following issue with showcase demo:
Breadcrumbs:
> Overview: JS error occurs in the following scenario:
click on the '+' sign to access cities for a province.
in 'Crumbs with URL's' click on the province name -> user is redirected to the wiki page for that province.
click the Back button in the browser to navigate back to showcase ace:breadcrumbs - Overview page.
select a different province from the breadcrumb menu items -> a JS error is visible in the console:
[window] Error [status: malformedXML code: 200]: During update: crumb-form:crumb-tree::0:2:0: not found
http://localhost:8080/showcase/javax.faces.resource/coalesced.js.jsf?ln=ice.core&dgst=4twnyr
Line 436
Yip's analysis:
Nothing to do with breadcrumbs component. The tree demo has the same problem. See video. Seems like some states or some node ids (the digits in the id is the key to the tree node) are lost once you navigate elsewhere and come back. And it seems to occur only in single select mode. (Tree Overview demo uses multiple select mode, change source to use single select mode to reproduce problem.)
Breadcrumbs:
> Overview: JS error occurs in the following scenario:
click on the '+' sign to access cities for a province.
in 'Crumbs with URL's' click on the province name -> user is redirected to the wiki page for that province.
click the Back button in the browser to navigate back to showcase ace:breadcrumbs - Overview page.
select a different province from the breadcrumb menu items -> a JS error is visible in the console:
[window] Error [status: malformedXML code: 200]: During update: crumb-form:crumb-tree::0:2:0: not found
http://localhost:8080/showcase/javax.faces.resource/coalesced.js.jsf?ln=ice.core&dgst=4twnyr
Line 436
Yip's analysis:
Nothing to do with breadcrumbs component. The tree demo has the same problem. See video. Seems like some states or some node ids (the digits in the id is the key to the tree node) are lost once you navigate elsewhere and come back. And it seems to occur only in single select mode. (Tree Overview demo uses multiple select mode, change source to use single select mode to reproduce problem.)
Activity
Ken Fyten
created issue -
Ken Fyten
made changes -
Field | Original Value | New Value |
---|---|---|
Assignee | Nils Lundquist [ nils.lundquist ] | |
Assignee Priority | P1 [ 10010 ] |
Nils Lundquist
made changes -
Workaround Description |
@ManagedBean(eager = true)
@ApplicationScoped public class HeaderPhaseListener implements Serializable { @PostConstruct private void initialize() { LifecycleFactory factory = (LifecycleFactory) FactoryFinder.getFactory(FactoryFinder.LIFECYCLE_FACTORY); Lifecycle lifecycle = factory.getLifecycle(LifecycleFactory.DEFAULT_LIFECYCLE); lifecycle.addPhaseListener(new PhaseListener() { public void afterPhase(PhaseEvent phaseEvent) { //To change body of implemented methods use File | Settings | File Templates. } public void beforePhase(PhaseEvent phaseEvent) { ExternalContext ec = phaseEvent.getFacesContext().getExternalContext(); ec.addResponseHeader("Cache-Control", "no-cache, no-store, must-revalidate"); ec.addResponseHeader("Pragma", "no-cache"); ec.addResponseHeader("Expires", "0"); } public PhaseId getPhaseId() { return PhaseId.RENDER_RESPONSE; } }); } } |
Nils Lundquist
made changes -
Summary | ace:tree - single select mode JS error | ace:tree - error on update following back button return |
Ken Fyten
made changes -
Assignee | Nils Lundquist [ nils.lundquist ] | Mircea Toma [ mircea.toma ] |
Repository | Revision | Date | User | Message |
ICEsoft Public SVN Repository | #35532 | Wed May 22 18:30:12 MDT 2013 | nils.lundquist | |
Files Changed | ||||
ADD
/icefaces3/trunk/icefaces/core/src/main/java/org/icefaces/util/CachingHeaderPhaseListener.java
|
Nils Lundquist
made changes -
Status | Open [ 1 ] | Resolved [ 5 ] |
Resolution | Fixed [ 1 ] |
Repository | Revision | Date | User | Message |
ICEsoft Public SVN Repository | #35533 | Wed May 22 20:54:48 MDT 2013 | nils.lundquist | |
Files Changed | ||||
MODIFY
/icefaces3/trunk/icefaces/ace/component/resources/icefaces.ace/list/list.js
|
Repository | Revision | Date | User | Message |
ICEsoft Public SVN Repository | #35593 | Fri May 24 11:09:07 MDT 2013 | deryk.sinotte | |
Files Changed | ||||
MODIFY
/icefaces3/trunk/icefaces/core/src/main/java/org/icefaces/util/CachingHeaderPhaseListener.java
MODIFY /icefaces3/trunk/icefaces/core/src/main/java/org/icefaces/util/EnvUtils.java |
Ken Fyten
made changes -
Fix Version/s | 4.0 [ 11382 ] |
Ken Fyten
made changes -
Status | Resolved [ 5 ] | Closed [ 6 ] |
This is an interesting error - when the page is refreshed instead of a navigation being performed you'd expect the behavior to be the same. The page is being reloaded fully. However when a refresh is done instead of navigation and return, the correct expansion and selection state for the Tree is shown. When a navigation is performed the previous expansion state for the tree is not rendered.