Skip to content

Fixes the marker loading in the region admin tool after the map update

David requested to merge fix-region-admin-tool into master

What does this MR do?

Since, the map update (!1405 (merged)) it is not possible to select regions in the region admin tool (an infinite loading spinner appears). The problem is that the bounds to adjust the viewport of the map is not calculated correctly.

This MR just updates the viewport once (instead of after iterating over every foodsaver and store!?) and checks whether the bounds are valid.

It works now locally for me.

How confident are you it won't break things if deployed?

Not very, I wondered that the code is working at all

Links to related issues

Any relevant links (issues, documentation, slack discussions).

How to test

Steps a reviewer can take to verify that this MR does what it says it does e.g.

  1. Checkout branch locally
  2. Login as orga
  3. Go to the region admin tool (Settings wheel -> Regionen Verwalten)
  4. Select the region Göttingen (in all others there are no users)
  5. Verify that the users and stores appear on the map

Screenshots (if applicable)

Beta testing thread where the issue appeared: https://yunity.slack.com/archives/C74JC2V26/p1585589392052500

Checklist

  • added a test, or explain why one is not needed/possible...
  • no unrelated changes
  • asked someone for a code review
  • joined #foodsharing-beta channel at https://slackin.yunity.org
  • added an entry to CHANGELOG.md (description, merge request link, username(s))
  • Once your MR has been merged, you are responsible to update the #foodsharing-beta Slack channel about what has been changed here. They will test your work in different browsers, roles or other settings

Merge request reports