File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JSF and the fly likes Richfaces context menu is triggering itself Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSF
Bookmark "Richfaces context menu is triggering itself" Watch "Richfaces context menu is triggering itself" New topic

Richfaces context menu is triggering itself

J Miller
Ranch Hand

Joined: Oct 21, 2010
Posts: 79
I’m having some trouble with a rich:context menu. It’s functionally working, it just has a strange side-effect. I have a dataGrid, and each name in the name column is a link that produces a context menu when clicked. The context menu allows you to see details or cancel. When you click a menuItem, it performs the task it should, but the context menu hides and shows again. It’s like clicking a menuItem in the context menu is triggering the context menu again. I’m nesting the context menu inside the commandLink as shown below. Any ideas?

Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 17417

I can't really say, but what you are coding is a set of JavaScript function calls (detailsRedirect, cancelBatchJob) that will be called BEFORE the actual AJAX submit for the related menu is done and the parmeters passed to those JavaScript funcitons calls will be the value of the job id WHEN THE PAGE WAS LOADED (it's not dynamically updated).

So if that isn't what you'd intended, keep it in mind.

An IDE is no substitute for an Intelligent Developer.
I agree. Here's the link:
subject: Richfaces context menu is triggering itself
It's not a secret anymore!