06-20-2023 06:16 AM
Hi all,
I'm developing a dashboard that will likely be used by 10 different people. I'd like to lock the access to other users if one user has the dashboard already open (and maybe until he/she clicks on a button to unlock it?)
Does anyone have a reliable approach to do this?
Thanks in advance!
Solved! Go to Solution.
06-20-2023 10:29 AM
I suspect that this will give issues, as security rights are refreshed fairly rarely (i.e. at login).
I more classic approach would be:
As you mention, unlocking is an issue. I think there is a "page unload" event somewhere, but can't look it up right now; but keeping track of the last-locked time, you can basically use it with session-expiration strategies that will unlock it no matter what.
06-20-2023 07:54 AM
Hey fc!
I have never done that and never heard of a functionality to do that, as it is meant for group work, right?
If you need to take that road, my thinking could be to create a specific group security group for this dashboard.
You would have the starting dashboard page to "activate" the dashboard. On the back, a BR would add the username to this security group and check that there is only one user in this security group. If more then one, it drops a message saying that the other person is already using it... Now the limitation is that if the user does not "unlock" the dashboard after use, then it will always be blocked. You should maybe make this automatic too.
As you see it is not straighforward, but possible.
06-20-2023 10:29 AM
I suspect that this will give issues, as security rights are refreshed fairly rarely (i.e. at login).
I more classic approach would be:
As you mention, unlocking is an issue. I think there is a "page unload" event somewhere, but can't look it up right now; but keeping track of the last-locked time, you can basically use it with session-expiration strategies that will unlock it no matter what.
06-23-2023 05:41 AM
thank you both, I indeed followed Jack's suggestion to use a custom table to store the information of each user and lock them out in case another user is currently using the dashboard. It works!