Hi Carlos,
What do you think of this enhancement :
Add IsFavourite on AD_TreeBar (Yes/No field, mandatory)
Add AutomaticOpenSeqNo on AD_TreeBar (Numeric, non mandatory field)
Add a window based on that table
Then when a record is added on DPFavourites, we check if the AD_Menu_ID is already present in the table.
If yes, IsFavourite is set to Y.
Otherwise, we do the insert (and set IsFavourite = Y)
When a record is removed, if AutomaticOpenSeqNo is not null (means the record is automatically opened on login), we just set IsFavourite = N.
Otherwise, we remove the record (as today)
And when a user want to open a record at login, he opens the new window, search for the menu entry and write a sequence in AutomaticOpenSeqNo.
To remove it, he must empty the field or delete the record (which will also remove it from the favourites)
(Note that the records will be linked to user, not role)
Then for opening at login, we just add that code at the end of LoginCompleted :
Search record with AutomaticOpenSeqNo > 0 for current user.
For each :
if AD_Menu.Action = InfoWindow
-> MInfoWindow iw = MInfoWindow.get("XXA_Dossier", null);
if (iw != null)
SessionManager.getAppDesktop().openInfo(iw.getAD_InfoWindow_ID());
if AD_Menu.Action = Window
-> ...
WDYT ?
Regards,
Nicolas
Le vendredi 18 décembre 2015 20:03:09 UTC+1, Carlos Antonio Ruiz Gómez a écrit :