Dialog Framework : unable to display multiple dialogs using same URL

UI Components for JSF
Post Reply
xav
Posts: 5
Joined: 12 Feb 2020, 21:29

12 Feb 2020, 21:53

Hi,

It seems it is impossible to launch several dialogs using the same URL.

Code: Select all

	
private void launchNewDialog(String url)
{
	Map<String,Object> options = new HashMap<String, Object>();
	options.put("draggable", true);
	options.put("resizable", true);
	options.put("minimizable", true);
	options.put("maximizable", true);
	options.put("width", 640);
	options.put("height", 340);
	options.put("contentWidth", "100%");
	options.put("contentHeight", "100%");

	Logger.getGlobal().info("Opening " + url);
	PrimeFaces.current().dialog().openDynamic(url, options, null);
}
When calling this method with different URLs, it works.
But nothing happens when trying to display a dialog with the same URL than another dialog (no error and nothing displayed).

Is it an expected behavior ? Or am I doing something wrong ?

I'm using Primefaces 7.0 and Mojarra 2.3.9

Regards.
--
Xavier

Melloware
Posts: 3717
Joined: 22 Apr 2013, 15:48

13 Feb 2020, 14:21

Hmm so you are trying to open two of the same exact dialog at the same time? I don't know if I have ever tried that before.
PrimeFaces Developer | PrimeFaces Extensions Developer
GitHub Profile: https://github.com/melloware
PrimeFaces Elite 13.0.0 / PF Extensions 13.0.0
PrimeReact 9.6.1

xav
Posts: 5
Joined: 12 Feb 2020, 21:29

14 Feb 2020, 13:40

Melloware wrote:
13 Feb 2020, 14:21
Hmm so you are trying to open two of the same exact dialog at the same time?
Yes...

Melloware
Posts: 3717
Joined: 22 Apr 2013, 15:48

14 Feb 2020, 14:04

See if you can debug, i wonder if there is something in the dialog framework where the URL is what makes it unique so it thinks the dialog is already created and open.
PrimeFaces Developer | PrimeFaces Extensions Developer
GitHub Profile: https://github.com/melloware
PrimeFaces Elite 13.0.0 / PF Extensions 13.0.0
PrimeReact 9.6.1

xav
Posts: 5
Joined: 12 Feb 2020, 21:29

14 Feb 2020, 15:44

As far as I can tell, the openDynamic() case is handled in DialogNavigationHandler.handleNavigation().

Unfortunately I don't know the JSF and PrimeFaces internals so I cannot tell after a quick look if the NavigationCase would be the same in that particular case.

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 32 guests