nycmeshnet / meshdb

A convenient, stable, and sane database for tracking Members and Nodes for use with robots and humans
https://db.nycmesh.net
MIT License
12 stars 14 forks source link

Fix: 404 on hyperlinks to Sector and AP objects #636

Closed Andrew-Dickinson closed 1 month ago

Andrew-Dickinson commented 1 month ago

Our exclusion of Sector and AP objects from the device queryset (so they don't show on the devices list or the device search pages) has the unintended consequence of breaking hyperlinks to the change pages for these objects. These pages end up 404ing, since the objects aren't in the queryset. To fix this, we detect this case and insert a redirect to the more specific admin page

codecov[bot] commented 1 month ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 94.22%. Comparing base (46d6597) to head (23c7f29). Report is 1 commits behind head on main.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #636 +/- ## ========================================== + Coverage 94.18% 94.22% +0.04% ========================================== Files 79 80 +1 Lines 3235 3258 +23 ========================================== + Hits 3047 3070 +23 Misses 188 188 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.