Prevent users from opening iDempiere in two tabs on the same browser
Description
Bad things happen when user open two different tabs on browser pointing to the same iDempiere webui.
For example, opening login on one tab, then login on second tab, then refresh first, and then login on second throws this:
SEVERE: >>java.lang.NullPointerException
>> at org.adempiere.webui.panel.UserPanel.onCreate(UserPanel.java:104)
>> at org.adempiere.webui.panel.UserPanel.doAfterCompose(UserPanel.java:210)
If user succeeds to open two tabs and try to do operations on both tabs - one of the tabs will go to sessiontimeout.zul - or throw errors like:
SEVERE: [Desktop z_d2v:/index.zul] client error: Fail to process
script
dt is null (TypeError)
On usability terms maybe is better simply to notify the user that there is another session running on a different tab and forbid to open it again (if possible with zk)
Bad things happen when user open two different tabs on browser pointing to the same iDempiere webui.
For example, opening login on one tab, then login on second tab, then refresh first, and then login on second throws this:
SEVERE: >>java.lang.NullPointerException >> at org.adempiere.webui.panel.UserPanel.onCreate(UserPanel.java:104) >> at org.adempiere.webui.panel.UserPanel.doAfterCompose(UserPanel.java:210)
If user succeeds to open two tabs and try to do operations on both tabs - one of the tabs will go to sessiontimeout.zul - or throw errors like:
SEVERE: [Desktop z_d2v:/index.zul] client error: Fail to process script dt is null (TypeError)
On usability terms maybe is better simply to notify the user that there is another session running on a different tab and forbid to open it again (if possible with zk)
Regards,
Carlos Ruiz