Details
-
Type:
Bug
-
Status: Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 2.1-Beta
-
Component/s: ACE-Components
-
Labels:None
-
Environment:All
-
Assignee Priority:P1
Description
In the Williams app they have an action menu that can be changed depending on what view or tab is shown/selected. They are using the MenuModel to programatically change the menu items. This includes adding some JavaScript to the onclick event. Upon initial load the menu's onlcik events render without any issues. When the view/tab has been changed these onclick events get removed and only the ICEfaces events remain.
The issue seems to be in the encodeEnd method of the MenubarRenderer. When the menubar is first loaded the following gets called:
if(menu.shouldBuildFromModel()) {
menu.buildMenuFromModel();
}
When the menubar is reinitialized the above code is skipped and just the "encodeMarkup(context, menu);" is just called. This causes the model to not be built with the customized code.
The issue seems to be in the encodeEnd method of the MenubarRenderer. When the menubar is first loaded the following gets called:
if(menu.shouldBuildFromModel()) {
menu.buildMenuFromModel();
}
When the menubar is reinitialized the above code is skipped and just the "encodeMarkup(context, menu);" is just called. This causes the model to not be built with the customized code.
Issue Links
- blocks
-
ICE-9771 menuItem actionListener not firing consistently when using menuModel attribute
-
- Closed
-
This has been fixed by a preliminary generator change related to
ICE-7321. The new approach will be improved, but the basic idea seems to fix this particular problem.