diff --git a/geonode_mapstore_client/client/js/components/DetailsPanel/DetailsPanel.jsx b/geonode_mapstore_client/client/js/components/DetailsPanel/DetailsPanel.jsx
index 3bdd720104..1d6040c5a2 100644
--- a/geonode_mapstore_client/client/js/components/DetailsPanel/DetailsPanel.jsx
+++ b/geonode_mapstore_client/client/js/components/DetailsPanel/DetailsPanel.jsx
@@ -76,11 +76,11 @@ const EditThumbnail = ({ image, onEdit, thumbnailUpdating }) => (
);
-function formatResourceLinkUrl(resourceUrl = '') {
- if (resourceUrl.indexOf('http') === 0) {
- return resourceUrl;
+function formatResourceLinkUrl(resource) {
+ if (resource?.uuid) {
+ return window.location.href.replace(/#.+$/, `uuid/${resource.uuid}`);
}
- return window.location.href;
+ return window.location.href
}
function ThumbnailPreview({
@@ -568,14 +568,14 @@ function DetailsPanel({
}
- {detailUrl &&
- }
+
{detailUrl && !editThumbnail &&