No that is not the issue. The that AFTER a selection is made from the drop down, the select menu's selected item immediately reverts back to the default value, "Select Employee..."
No that is not the issue. The that AFTER a selection is made from the drop down, the select menu's selected item immediately reverts back to the default value, "Select Employee..."
It is related to the service "mgr_payroll_time_list" which runs on "value change" event of this select component.
That service re-create your select component, so it lost selected value.
You have to set it's value before running mgr_payroll_time_list into storage variable and read that variable on mgr_payroll_time_list's success event as I described you before.
Mgr_payroll_time_list does not recreate the the select component to the best of my knowledge. It simply populates a list based off of that is in the select component.
Are you saying that a service that has a where query on it from a select menu will reset the selected value of that select menu? That sounds unintentional.
I got the workaround working where I save the selected value to storage on value change then after the list-populating success triggers, I map the LSV back to the select menu.
Is this a bug?
I reviewed your app again. The reason of such behavior is:
You run the service "mgr_payroll_user" on the page show event, which is always triggered after closing a dialog of the emp_select. This service rewrites your select component: http://prntscr.com/9cyaz5
So you lose it's value.
If you use Native Menu - it doesn't open dialog, so "page show" event isn't triggered and as a result - service mgr_payroll_user isn't called and you don't lose emp_select's value.
You nailed it! Issue is now resolved, and I learned something very valuable.
Thank you for all of the time you put into this.