s.settings.time_format) || '24h'
const [editing, setEditing] = useState(false)
const confirmed = item.status === 'confirmed'
+ const placeFiles = files.filter(f => f.place_id === item.placeId)
const handleDelete = async () => {
if (!confirm(t('reservations.confirm.remove', { name: item.title }))) return
@@ -322,6 +323,26 @@ function PlaceReservationCard({ item, tripId }) {
{item.notes && {item.notes}
}
+
+ {/* Files attached to the place */}
+ {placeFiles.length > 0 && (
+
+ {placeFiles.map(f => (
+
+
+
{f.original_name}
+
+
+
+
+ ))}
+ {onNavigateToFiles && (
+
+ )}
+
+ )}
@@ -388,7 +409,7 @@ export default function ReservationsPanel({ tripId, reservations, days, assignme
const total = allPending.length + allConfirmed.length
function renderCard(r) {
- if (r._placeRes) return
+ if (r._placeRes) return
return
}
diff --git a/client/src/pages/TripPlannerPage.jsx b/client/src/pages/TripPlannerPage.jsx
index 906297c..f0e02c0 100644
--- a/client/src/pages/TripPlannerPage.jsx
+++ b/client/src/pages/TripPlannerPage.jsx
@@ -258,6 +258,13 @@ export default function TripPlannerPage() {
return map
}, [selectedDayId, assignments])
+ // Places assigned to selected day (with coords) — used for map fitting
+ const dayPlaces = useMemo(() => {
+ if (!selectedDayId) return []
+ const da = assignments[String(selectedDayId)] || []
+ return da.map(a => a.place).filter(p => p?.lat && p?.lng)
+ }, [selectedDayId, assignments])
+
const mapTileUrl = settings.map_tile_url || 'https://{s}.basemaps.cartocdn.com/light_all/{z}/{x}/{y}{r}.png'
const defaultCenter = [settings.default_lat || 48.8566, settings.default_lng || 2.3522]
const defaultZoom = settings.default_zoom || 10
@@ -323,6 +330,7 @@ export default function TripPlannerPage() {
{routeInfo && (
diff --git a/server/package.json b/server/package.json
index 4f2b156..af6da3a 100644
--- a/server/package.json
+++ b/server/package.json
@@ -1,6 +1,6 @@
{
"name": "nomad-server",
- "version": "2.5.3",
+ "version": "2.5.4",
"main": "src/index.js",
"scripts": {
"start": "node src/index.js",