diff --git a/templates/partials/projects/location_map.html b/templates/partials/projects/location_map.html new file mode 100644 index 0000000..d9c9fde --- /dev/null +++ b/templates/partials/projects/location_map.html @@ -0,0 +1,159 @@ + +
+
+

Location Map

+ +
+
+
+ + +
+ + diff --git a/templates/partials/projects/project_dashboard.html b/templates/partials/projects/project_dashboard.html index d8daf49..c4ff551 100644 --- a/templates/partials/projects/project_dashboard.html +++ b/templates/partials/projects/project_dashboard.html @@ -78,173 +78,19 @@ - -
-
-

Location Map

- {% if upcoming_actions %} - - {{ upcoming_actions | length }} upcoming action{{ '' if upcoming_actions | length == 1 else 's' }} → - - {% endif %} -
- -
- - -
+ {# Location map — uses the reusable partial that fetches from + /api/projects/{p}/locations-json. Same render is reused on the + deeper Vibration tab so both surfaces stay in sync. #} + {% with project_id=project.id %} + {% include 'partials/projects/location_map.html' %} + {% endwith %} - +{% if upcoming_actions %} +
+ + {{ upcoming_actions | length }} upcoming action{{ '' if upcoming_actions | length == 1 else 's' }} → + +
+{% endif %} diff --git a/templates/projects/detail.html b/templates/projects/detail.html index 4f75550..ba971f3 100644 --- a/templates/projects/detail.html +++ b/templates/projects/detail.html @@ -101,22 +101,33 @@ -
-
-

Monitoring Locations

- +
+
+
+

Monitoring Locations

+ +
+
+
Loading locations...
+
-
-
Loading locations...
+ + {# Reusable location map — fetches from /locations-json + on its own. Hovering any of the location cards on the + left highlights the matching pin on this map. #} +
+ {% with project_id=project_id, location_type='vibration', map_height='450px' %} + {% include 'partials/projects/location_map.html' %} + {% endwith %}