Open lbwexler opened 1 month ago
We could refresh the entire grid but in a non-blocking way - ie show the dialog, allow the user to potentially start inputting edits, but keep the save button disabled until a refresh has happened.
If the refresh updates other records, we could let the user proceed as they were. If the refresh updates the record under edit, we'd have to do something like show a modal alert or (better) banner with an option to reload the form with the latest data. At that point I think we should go ahead and drop any already-entered user changes - it's a shame for that user, but should be a pretty rare edge case.
I don't think we should require a lastUpdated timestamp - although agreed we could write code that leveraged it if available, but would have to fall back on some more complete comparison.
Some ideas Tom and I had:
1) Best Practice, include lastUpdated in Domain object and view 2) Refresh Data before showing edit dialog 3) Potentially look at version flag before submit of updates and warn user.
Re: 2 -- should we update entire grid or just record of interest? If entire grid, could make working with it laggy, but could also combine with changes to do a smart refresh only if data had changed by checking timestamps