mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-12-05 10:24:05 +00:00
feat(journey): keep the route recorded on a journey day from Dawarich, previewed first, with its gaps
A day header in the journey timeline now carries the Dawarich mark for an editor whose Dawarich answers (dimmed with the reason while offline). It opens a dialog that names the journey and the day and reads that one local day from the caller's own connection: a sketch of the route, distance, first and last time, pieces, gaps without recording, modes and whether tracks or thinned points answered. The day is cut in the zone Dawarich records in where its answer shows one, else in this device's, and a picker cuts it in any other. Nothing is kept before "Keep route". On a phone the same sheet opens from the journey's More options for the day of the card shown. What is kept is the preview that was seen: the save reads the day again and refuses with recording_changed when its hash moved, and the dialog shows the new version. The same day taken over twice keeps one version and announces nothing; a different version is replaced only on "Replace", never touching an entry or text. A failed read throws before any write, so the kept version stays. Gaps stay gaps: points are split where silence ends elsewhere, and no day is joined to the one before. The dialog says how many other people will see the route; editors may keep their own recording. Kept days show in the day header (distance, whose recording, since when, still running) and on the desktop and phone journey maps in the colour of their day's pins, winning over the live trail of their date, and stay drawn without Dawarich. A trip's GPX track is now drawn dashed as the plan, recorded routes solid. Shared links do not show recorded days. Remove route asks first and works without a connection. Server: migration 046160 adds journey_recorded_days (one row per journey, local day and source, segments as JSON, zone, window, fetch time, hash, importer kept past their account). The journey domain owns the rows through JourneyRecordedDaysService; the new journey-recordings domain takes a day over through DawarichTracksService.fetchDay, which reads past the cache, asks a window wide enough for every zone and refuses with DomainErrors. REST under /api/journeys/:id/recordings (list, preview, PUT and DELETE /:date) with @trek/shared contracts, and MCP list_journey_recorded_days, preview_journey_recorded_day, save_journey_recorded_day and delete_journey_recorded_day on the same service and access. A new user event journey:recording:updated keeps every open map current. JourneyTrack gains an optional kind. All 27 locales carry the strings; the Journey and Dawarich wiki pages and the MCP tool list say what it does.
This commit is contained in:
@@ -682,5 +682,60 @@ const journey: TranslationStrings = {
|
||||
'journey.settings.showWeather': 'สภาพอากาศ',
|
||||
'journey.entry.suggestion': 'คำแนะนำ',
|
||||
'journey.editor.addDetails': '+ รายละเอียด',
|
||||
'journey.recording.mapLine': 'บันทึกเมื่อ {date}',
|
||||
'journey.recording.keptBy': 'บันทึกเส้นทางที่บันทึกไว้แล้ว: {distance} นำเข้าโดย {name} เมื่อ {date}',
|
||||
'journey.recording.keptOn': 'บันทึกเส้นทางที่บันทึกไว้แล้ว: {distance} นำเข้าเมื่อ {date}',
|
||||
'journey.recording.keptRunning': 'ตอนนั้นวันยังไม่จบ',
|
||||
'journey.recording.takeOver': 'นำเข้าการบันทึก',
|
||||
'journey.recording.takeOverDay': 'การบันทึกวันที่ {date}',
|
||||
'journey.recording.sub': 'เฉพาะวันนี้ จาก Dawarich ของคุณ จะไม่มีการบันทึกอะไรจนกว่าคุณจะยืนยัน',
|
||||
'journey.recording.zone': 'เขตเวลาของวัน',
|
||||
'journey.recording.zoneHint': 'วันนี้นับจากเที่ยงคืนถึงเที่ยงคืนในเขตเวลานี้ เลือกเขตเวลาที่คุณเดินทางอยู่',
|
||||
'journey.recording.zoneSource': 'ตาม Dawarich',
|
||||
'journey.recording.zoneDevice': 'อุปกรณ์นี้',
|
||||
'journey.recording.scope': 'การบันทึก',
|
||||
'journey.recording.loading': 'กำลังอ่านวันนี้จาก Dawarich…',
|
||||
'journey.recording.keptStays': 'เส้นทางที่ทริปนี้เก็บไว้ยังคงเหมือนเดิม',
|
||||
'journey.recording.retry': 'ลองอีกครั้ง',
|
||||
'journey.recording.empty': 'Dawarich ไม่ได้บันทึกอะไรในวันนี้ในเขตเวลานี้',
|
||||
'journey.recording.span': '{from} ถึง {to}',
|
||||
'journey.recording.pieces': '{count} ช่วง',
|
||||
'journey.recording.gaps': 'ขาดหาย {count} จุด',
|
||||
'journey.recording.gapsHint': 'ที่ใดการบันทึกหยุด เส้นก็หยุดด้วย จะไม่วาดเส้นทางที่ไม่ได้บันทึก',
|
||||
'journey.recording.sourceHint':
|
||||
'แทร็กคือเส้นทางที่ Dawarich แบ่งตามวิธีเดินทางแล้ว จุดคือตำแหน่งดิบ ลดเหลือ 600 จุดต่อวัน',
|
||||
'journey.recording.sourceTracks': 'แทร็ก',
|
||||
'journey.recording.sourcePoints': 'จุด',
|
||||
'journey.recording.changedSincePreview':
|
||||
'การบันทึกใน Dawarich เปลี่ยนไประหว่างที่คุณดูอยู่ ตรวจสอบอีกครั้งแล้วจึงบันทึก',
|
||||
'journey.recording.truncated': 'Dawarich ส่งมาเพียงบางส่วนของวันนี้ เส้นทางจึงไม่ครบ',
|
||||
'journey.recording.provisional': 'วันนี้ยังไม่จบในเขตเวลานี้ คุณเปลี่ยนเส้นทางเป็นทั้งวันได้ภายหลัง',
|
||||
'journey.recording.same': 'ทริปนี้เก็บการบันทึกนี้ไว้แล้วทุกประการ',
|
||||
'journey.recording.differs': 'ทริปนี้เก็บอีกเวอร์ชันจาก {date} ({distance}) การแทนที่จะไม่เปลี่ยนรายการหรือข้อความใด',
|
||||
'journey.recording.audience': 'อีก {count} คนในทริปนี้จะเห็นเส้นทางบนแผนที่ ลิงก์ที่แชร์จะไม่แสดง',
|
||||
'journey.recording.replace': 'แทนที่',
|
||||
'journey.recording.alreadyKept': 'บันทึกแล้ว',
|
||||
'journey.recording.keep': 'บันทึกเส้นทาง',
|
||||
'journey.recording.remove': 'ลบเส้นทาง',
|
||||
'journey.recording.removeTitle': 'ลบเส้นทางที่บันทึกไว้หรือไม่',
|
||||
'journey.recording.removeMessage':
|
||||
'เส้นทางของวันนี้จะหายไปจากแผนที่ทริป รายการและข้อความยังอยู่ และ Dawarich ยังเก็บการบันทึกของตัวเองไว้',
|
||||
'journey.recording.keptToast': 'บันทึกเส้นทางในทริปแล้ว',
|
||||
'journey.recording.replacedToast': 'แทนที่เส้นทางแล้ว',
|
||||
'journey.recording.removedToast': 'ลบเส้นทางออกจากทริปแล้ว',
|
||||
'journey.recording.error.recording_exists': 'ทริปนี้เก็บการบันทึกอื่นของวันนั้นไว้แล้ว',
|
||||
'journey.recording.error.recording_changed': 'การบันทึกเปลี่ยนไปตั้งแต่ดูตัวอย่าง',
|
||||
'journey.recording.error.recording_empty': 'Dawarich ไม่ได้บันทึกอะไรในวันนั้น',
|
||||
'journey.recording.mode.walking': 'เดิน',
|
||||
'journey.recording.mode.running': 'วิ่ง',
|
||||
'journey.recording.mode.cycling': 'จักรยาน',
|
||||
'journey.recording.mode.driving': 'รถยนต์',
|
||||
'journey.recording.mode.motorcycle': 'มอเตอร์ไซค์',
|
||||
'journey.recording.mode.bus': 'รถบัส',
|
||||
'journey.recording.mode.train': 'รถไฟ',
|
||||
'journey.recording.mode.flying': 'เครื่องบิน',
|
||||
'journey.recording.mode.boat': 'เรือ',
|
||||
'journey.recording.mode.stationary': 'อยู่กับที่',
|
||||
'journey.recording.mode.unknown': 'ไม่ทราบวิธี',
|
||||
};
|
||||
export default journey;
|
||||
|
||||
Reference in New Issue
Block a user