From efcf9a9e915fb94ef55e11536c7566ccedbd9b06 Mon Sep 17 00:00:00 2001 From: Varun Patil Date: Thu, 9 Feb 2023 18:14:12 -0800 Subject: [PATCH] map: fix wrong URL for preview --- lib/Db/TimelineQueryMap.php | 4 +--- src/components/top-matter/MapSplitMatter.vue | 7 +------ 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/lib/Db/TimelineQueryMap.php b/lib/Db/TimelineQueryMap.php index d051866a..7a93c052 100644 --- a/lib/Db/TimelineQueryMap.php +++ b/lib/Db/TimelineQueryMap.php @@ -42,9 +42,8 @@ trait TimelineQueryMap $lat = $query->createFunction('AVG(c.lat) AS lat'); $lon = $query->createFunction('AVG(c.lon) AS lon'); $count = $query->createFunction('COUNT(m.fileid) AS count'); - $update = $query->createFunction('MAX(c.last_update) as u'); - $query->select($lat, $lon, $update, $count) + $query->select($lat, $lon, $count) ->from('memories_mapclusters', 'c') ; @@ -81,7 +80,6 @@ trait TimelineQueryMap (float) $cluster['lon'], ], 'count' => (float) $cluster['count'], - 'u' => (int) $cluster['u'], ]; if (\array_key_exists('id', $cluster)) { $c['id'] = (int) $cluster['id']; diff --git a/src/components/top-matter/MapSplitMatter.vue b/src/components/top-matter/MapSplitMatter.vue index d8ec3218..17508ee8 100644 --- a/src/components/top-matter/MapSplitMatter.vue +++ b/src/components/top-matter/MapSplitMatter.vue @@ -55,7 +55,6 @@ const STAMEN_ATTRIBUTION = `Map tiles by Stamen Desi type IMarkerCluster = { id?: number; - u?: any; center: [number, number]; count: number; preview?: IPhoto; @@ -129,11 +128,7 @@ export default defineComponent({ }, clusterPreviewUrl(cluster: IMarkerCluster) { - let url = getPreviewUrl(cluster.preview, false, 256); - if (cluster.u) { - url += `?u=${cluster.u}`; - } - return url; + return getPreviewUrl(cluster.preview, false, 256); }, zoomTo(cluster: IMarkerCluster) {