mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-10-18 21:16:47 +00:00
2d7cb124b3
A trip can be bound to a folder, tag or space in a self-hosted document store, and documents then move in both directions: what someone uploads in TREK appears there, and what someone files there appears in TREK. Three decisions shape the rest. The connection belongs to the TRIP, not to a person. Every other integration here is per user, and photos are shared only through an opt-in flag; neither can deliver "everyone on the trip sees the same documents", because visibility would depend on whose credentials fetched a file, and a member without their own Paperless account would see nothing. So the trip owner binds the trip once, the server talks to the provider under that one identity, and TREK's own membership decides who sees what. The provider never learns that TREK has members. When the credential holder leaves the trip the binding goes to `orphaned` rather than quietly carrying on with an ex-member's token. TREK keeps the bytes. A synced document is an ordinary trip_files row, so download, trash, offline cache, PDF export and backup keep working untouched, and a provider outage does not blank out a trip that starts tomorrow. Deletion never crosses the boundary on its own. A document that disappears upstream is recorded as missing and waits for a human, and a run that sees more than 40 percent of its known documents vanish at once refuses the whole listing rather than acting on it: an unmounted share answers exactly like a mass delete. The core reconciles by enumerating both sides, because the weakest provider sets the model. A changed-since query cannot see a deletion, Papra does not move updatedAt when a tag changes, a Paperless bulk edit leaves `modified` alone, and Synology FileStation has no change feed at all. A webhook is therefore only ever "look now", never a source of truth. Echo is caught by comparing content, not timestamps: pushed_sha256 records what TREK itself wrote, so a provider reporting TREK's own upload is not mistaken for a stranger's edit. Provider differences are answered by capability data rather than by branching on an id: stable ids where they exist (Paperless document id, oc:fileid, driveId) and a normalised path where they do not, replace-in-place where the API offers it, and a content hash from the listing only where the provider really supplies one. Admins switch providers on under Admin, Addons, Documents, mirroring how photo providers hang off Journey, including the cascade and the 409 when the parent addon is off. The per-trip setup lives in the file manager, where the person has the context that makes the folder choice obvious.
115 lines
2.6 KiB
TypeScript
115 lines
2.6 KiB
TypeScript
import admin from './admin';
|
|
import dawarich from './dawarich';
|
|
import docsync from './docsync';
|
|
import airport from './airport';
|
|
import atlas from './atlas';
|
|
import backup from './backup';
|
|
import budget from './budget';
|
|
import categories from './categories';
|
|
import collab from './collab';
|
|
import collection from './collection';
|
|
import common from './common';
|
|
import dashboard from './dashboard';
|
|
import day from './day';
|
|
import dayplan from './dayplan';
|
|
import files from './files';
|
|
import help from './help';
|
|
import inspector from './inspector';
|
|
import journey from './journey';
|
|
import login from './login';
|
|
import map from './map';
|
|
import members from './members';
|
|
import memories from './memories';
|
|
import mobileAdmin from './mobileAdmin';
|
|
import mobileAtlas from './mobileAtlas';
|
|
import mobileCollections from './mobileCollections';
|
|
import mobileJourney from './mobileJourney';
|
|
import mobileNav from './mobileNav';
|
|
import mobileSettings from './mobileSettings';
|
|
import mobileTrip from './mobileTrip';
|
|
import mobileVacay from './mobileVacay';
|
|
import nav from './nav';
|
|
import notif from './notif';
|
|
import notifications from './notifications';
|
|
import oauth from './oauth';
|
|
import packing from './packing';
|
|
import pdf from './pdf';
|
|
import perm from './perm';
|
|
import photos from './photos';
|
|
import places from './places';
|
|
import planner from './planner';
|
|
import register from './register';
|
|
import roadtrip from './roadtrip';
|
|
import reservations from './reservations';
|
|
import settings from './settings';
|
|
import share from './share';
|
|
import shared from './shared';
|
|
import stats from './stats';
|
|
import storage from './storage';
|
|
import system_notice from './system_notice';
|
|
import todo from './todo';
|
|
import transport from './transport';
|
|
import trip from './trip';
|
|
import trips from './trips';
|
|
import undo from './undo';
|
|
import vacay from './vacay';
|
|
|
|
const locale = {
|
|
...common,
|
|
...trips,
|
|
...nav,
|
|
...dashboard,
|
|
...roadtrip,
|
|
...settings,
|
|
...admin,
|
|
...dayplan,
|
|
...share,
|
|
...shared,
|
|
...login,
|
|
...register,
|
|
...vacay,
|
|
...collection,
|
|
...atlas,
|
|
...trip,
|
|
...places,
|
|
...inspector,
|
|
...reservations,
|
|
...airport,
|
|
...map,
|
|
...budget,
|
|
...files,
|
|
...packing,
|
|
...members,
|
|
...categories,
|
|
...backup,
|
|
...photos,
|
|
...pdf,
|
|
...planner,
|
|
...stats,
|
|
...day,
|
|
...memories,
|
|
...collab,
|
|
...perm,
|
|
...undo,
|
|
...notifications,
|
|
...todo,
|
|
...notif,
|
|
...journey,
|
|
...oauth,
|
|
...system_notice,
|
|
...transport,
|
|
...help,
|
|
...mobileTrip,
|
|
...mobileJourney,
|
|
...mobileVacay,
|
|
...mobileAtlas,
|
|
...mobileNav,
|
|
...mobileAdmin,
|
|
...mobileSettings,
|
|
...mobileCollections,
|
|
...storage,
|
|
...dawarich,
|
|
...docsync,
|
|
};
|
|
export default locale;
|