Improved pagination

This commit is contained in:
Frank Schubert
2022-03-24 16:46:11 +01:00
parent 455a5af4aa
commit cd88c4f57c
10 changed files with 371 additions and 116 deletions

View File

@@ -106,6 +106,9 @@
</div>
<div class="row hidden" id="map-row">
<div id="building-map" style="height:50vh; width: 100%"></div>
<div class="mt-1">
<button type="button" class="btn btn-sm btn-outline-secondary" onclick="centerMap()"><i class="far fa-dot-circle"></i> Zentrieren</button>
</div>
</div>
</div>
</div>
@@ -444,13 +447,17 @@
console.log(all_coords);
// calculate center position
var center_pos = GetCenterFromDegrees(all_coords);
console.log(center_pos);
buildingMap.setView(center_pos, 12);
mapCenterPos = GetCenterFromDegrees(all_coords);
console.log(mapCenterPos);
buildingMap.setView(mapCenterPos, 12);
return true;
}
function centerMap() {
buildingMap.setView(mapCenterPos, 12);
}
// gets buildings and calls renderMap()
function getMapdata() {
filter = getFilter();