mirror of
https://github.com/seanmorley15/AdventureLog.git
synced 2025-07-19 12:59:36 +02:00
feat(calendar): add adventure detail link in event modal
This commit is contained in:
parent
36f9022872
commit
a6b39f64d6
2 changed files with 12 additions and 1 deletions
|
@ -34,6 +34,7 @@ export const load = (async (event) => {
|
||||||
formattedEnd: string;
|
formattedEnd: string;
|
||||||
location?: string;
|
location?: string;
|
||||||
description?: string;
|
description?: string;
|
||||||
|
adventureId?: string;
|
||||||
};
|
};
|
||||||
}> = [];
|
}> = [];
|
||||||
|
|
||||||
|
@ -119,7 +120,8 @@ export const load = (async (event) => {
|
||||||
? formatAllDayDate(visit.end_date || visit.start_date)
|
? formatAllDayDate(visit.end_date || visit.start_date)
|
||||||
: formatDateInTimezone(visit.end_date || visit.start_date, targetTimezone),
|
: formatDateInTimezone(visit.end_date || visit.start_date, targetTimezone),
|
||||||
location: adventure.location || '',
|
location: adventure.location || '',
|
||||||
description: adventure.description || ''
|
description: adventure.description || '',
|
||||||
|
adventureId: adventure.id
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
@ -408,6 +408,15 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{/if}
|
{/if}
|
||||||
|
|
||||||
|
{#if selectedEvent.extendedProps.adventureId}
|
||||||
|
<a
|
||||||
|
href={`/adventures/${selectedEvent.extendedProps.adventureId}`}
|
||||||
|
class="btn btn-neutral btn-block mt-4"
|
||||||
|
>
|
||||||
|
{$t('map.view_details')}
|
||||||
|
</a>
|
||||||
|
{/if}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="modal-action mt-8">
|
<div class="modal-action mt-8">
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue