Hi all,
I have a script that is adding custom columns to the OIS301/B grid, using API's to gather the required data and then populating the sub file info and refreshing the list.
I have used attachEvents to capture scrolling events, which then gathers the required data for the new rows, populates the sub file info and refreshes the list again.
The issue:
If the user enters a value into one of the sorting position fields on the grid and hits ENTER, the script is not triggered and the data doesn't populate.
I've tried capturing the event for command type KEY and value ENTER - however this appears to run both the full script, and whatever code I have inside the captured event. Because of this, it actually runs the populate data a second time, and also attaches a second (and third and fourth) event listener. I have tried using the instance cache to only allow a single instance of the script to be attached, which does seem to stop the additional listeners, however the data still doesn't repopulate.
My question is for advice on the best approach to deal with this?
This can be easily replicated with the latest version of the H5SampleCustomColumns.js from the H5 sample scripts. Attach the script to any panel with a list in M3, run it, then enter a value in the sorting option screen and press ENTER.
Before sorting option:

After sorting option:
