Particular / ServicePulse

Production monitoring for distributed systems.
https://docs.particular.net/servicepulse/
Other
34 stars 27 forks source link

Clicking custom check Dismiss, scrolls page to the top #439

Open ramonsmits opened 7 years ago

ramonsmits commented 7 years ago

Clicking the Dismiss button on the custom check page will scroll the page to the top which isn't expected. If you want to dismiss multiple rows you need to scroll back down.

2017-04-21_12-44-57


Technical information if reporting bug:

WojcikMike commented 6 years ago

Ok at the moment we can't implement this. When anything related to Custom Checks changes (new is created, old one is muted etc.), An event is send from SC holding information that something have changed. On that information what we do is refresh the loaded data (meaning loading the 1st page of custom checks). To make this screen not scroll to the top we need more finely grained events from SC informing about new, deleted, updated custom checks so that we can respond to that change without refreshing the whole page. For now on we can't introduce this change. So I am removing this issue from this milestone

WilliamBZA commented 6 years ago

We could still implement this by being a bit smarter about the reload function being called.

  1. When dismissing the event, remove it from the in-memory list
  2. When the CustomChecksUpdated load the current set of custom checks and merge the lists together. I.e. don't simply re-set the model to the data coming from the server, but actually check what data has changed.

This does mean we'd have to associate each row with the page number that it came from and load the page and possible the preceeding and the following page too, but it is still possible.