Commit Graph

5659 Commits

Author SHA1 Message Date
Maurice 4cd3f3d650 fix(files): serve a plugin the files a trip keeps while Documents is off
The plugin file surface follows the REST rule: the list and reads keep booking, place, expense, note and message files, a write on a loose file goes through when it attaches it, and uploads and deletes stay open.
2026-11-23 15:45:25 +01:00
Maurice a0d66eb898 fix(files): attach a loose file while the trip has Documents off
update and link go through when the request itself attaches the file to a booking, place, stop or expense, on REST and MCP alike, and upload_trip_file takes budget_item_id like the REST upload.
2026-11-23 15:45:24 +01:00
Maurice 8a2045c619 fix(mail-ingest): attach a booking's documents while the trip has Documents off
A booking's files belong to the booking, so the mail's documents now reach it whatever the Documents switch says; a mail filed without a booking still needs Documents.
2026-11-23 15:17:02 +01:00
Maurice 34d5fba437 fix(plugins): deliver a trip's core events to plugins in emission order
The addon check in front of the event sink made each family event wait for
its own read, so on Postgres a later snapshot could overtake an earlier one,
and a trip event could arrive before the budget event emitted ahead of it.
The reads still run side by side, but a trip's events now leave in order.
2026-11-23 15:15:37 +01:00
Maurice 8b9de04960 fix(wanderer): offer the connection and run the watch where a trip switched Tours on
With Tours off for the instance, a trip that switched it on opened the wanderer
import, but Settings hid the connection and the watch cron never ran. The addon
feed now tells each user whether wanderer applies to them, and the watch looks
for every user who has Tours on somewhere; the others only take their turn.
2026-11-23 15:15:36 +01:00
Maurice c289541c43 fix(notifications): list the paddle region request for admins while any trip has Tours on
The admin matrix decided a trip addon by the admin's own trips, so with Tours
off for the instance and on for a member's trip the paddle region request still
reached admins but had no row to switch it. Admin-scoped rows now follow the
addon being on for the instance or any trip.
2026-11-23 15:15:36 +01:00
Maurice 146f46c5e3 fix(addons): give a member who joins a trip with an opened addon a new MCP session
A trip that switched on an addon the instance has off ended the MCP sessions
of the members it had then, but somebody added later, or joining through the
invite link, kept a session without that addon's tools. Joining now ends it too.
2026-11-23 15:15:36 +01:00
Maurice 8709f67ff4 fix(trip-members): leave expenses out of a guest deletion while Costs is off
Deleting a guest re-sent every expense that named them as budget:updated,
even on a trip with Costs switched off, so each member's offline cache took
rows the bundle keeps out. The re-split expenses now go out only while the
trip has Costs on.
2026-11-23 15:15:36 +01:00
Maurice 363889b97a docs(plugin-sdk): state the transaction-control and NUL rules of ctx.db
A plugin's own database refuses BEGIN/COMMIT in every call and NUL in SQL,
bound values and migration ids on every engine; the guide and the ctx.db types
now say so and point at ctx.db.tx() and Buffer binding instead.
2026-11-23 15:15:36 +01:00
Maurice 48e54d5a62 fix(files): keep booking, place and expense files reachable with Documents off
The Documents addon now gates only the file manager: the list leaves out loose
files, and the trash, starring and loose files answer 404, while uploads, deletes
and every file a booking, place, expense, note or message carries stay reachable
over REST, the download route, MCP and the offline bundle.
2026-11-23 15:15:36 +01:00
Maurice d83841f53b ci(postgres): restore with the 18 client tools the image ships
The backup round trip now runs with pg_restore 18 against both lane servers, so a setting an older server does not know fails the lane.
2026-11-23 15:12:16 +01:00
Maurice 485fb93f78 fix(helm): render when an upgrade reuses values from before the database block
The templates read the database settings through a default dict, so helm upgrade --reuse-values from a release without them no longer stops on a nil pointer; CI renders the chart with the block removed.
2026-11-23 15:11:40 +01:00
Maurice ca367d9cfc docs(postgres): name the Docker Compose version the Postgres compose file needs
The file creates TREK's role from an inline config, which Compose reads only from 2.23.1 on; the file header and the wiki now say so, with the error an older Compose prints.
2026-11-23 15:11:40 +01:00
Maurice 9ae99b42ec fix(ci): give the release mirror a recovery hint that works
With no push run for the dev head, the mirror now says to push a new commit to dev; a run started by hand is not a push run and never satisfied it.
2026-11-23 15:11:40 +01:00
Maurice 8fb720ea49 fix(mcp): validate a tool or prompt field again once NUL stripping changed it
The SDK validates the arguments before the input mapper drops NUL characters, so a field the mapper changes is now checked against its own schema again and a name of nothing but NUL is refused over MCP as it is over REST.
2026-11-23 15:11:39 +01:00
Maurice 1fb1b102e8 fix(dawarich): name an unnamed stay once Dawarich has geocoded its points
A stay stored as 'Unnamed stay' because none of its points was geocoded yet is now read again on the next sync, so a slow background geocoder or a stay from before the upgrade gets its town once Dawarich knows it.
2026-11-23 15:11:39 +01:00
Maurice a604f84899 fix(memories): send share link viewers the Immich preview instead of the original file
A public view of an Immich image now asks for the preview rendition, which Immich re-encodes without the stored metadata, so photo locations no longer go out with share links; owners still get the fullsize original.
2026-11-23 15:11:39 +01:00
Maurice e7e3592d97 fix(flight-live): tell a delay only to the bookings it is late for
Bookings that share one flight state can hold different scheduled times, so the delay notice now goes only to the legs whose own departure is at least fifteen minutes late instead of telling the others it is delayed by 0 minutes.
2026-11-23 15:11:39 +01:00
Maurice 8e51410251 fix(flight-live): do not read an earlier sector's aircraft as this flight having departed
Before the scheduled departure, an aircraft in the air that is no nearer the destination than the origin is now stays unpicked, so booking only the later sector of a through flight no longer sends the departure notice hours early.
2026-11-23 15:11:39 +01:00
Maurice 22c3381044 fix(tags): keep a trip's tags when the member who created them deletes their account
The trip tags a deleted user created now pass to each trip's owner before the user row goes, so the tag and its place assignments no longer cascade away for everyone else on the trip.
2026-11-23 15:11:38 +01:00
Maurice 25ded7319a fix(ios): hand a widget launch link to the UI only once
A tap that launched the app went to the UI as a held quick action and to
Capacitor as the launch URL, which a server UI before appLinks followed
as well, pushing the page twice. Capacitor now gets the launch without it.
2026-11-23 15:11:38 +01:00
Maurice b6006c8265 fix(ios): hide the status bar beside a corner element only on an iPhone
The status bar goes for the iPhone Duo's status capsule; an iPad's window
controls give the same corner signal and no longer hide its bar. The corner
insets still reach the page on every device.
2026-11-23 15:11:38 +01:00
Maurice bd215b7ec7 fix(ios): open the offline copy when an update rechecks an unreachable server
The recheck after an update ran on every bridge, also on the one the
offline start restarts, and moved the server it had just put back out
again, so the app looped between the address screen and a restart.
2026-11-23 15:11:38 +01:00
Maurice 98a05fa1fd fix(ios): read widget and watch dates in the Gregorian calendar
The app writes its days as Gregorian yyyy-MM-dd, but the widgets and the
watch built their keys in the device's calendar, so a Buddhist or Japanese
calendar matched no trip day and dropped every dated booking.
2026-11-23 15:11:38 +01:00
Maurice 0e918820c3 fix(widgets): keep every stop of the day the snapshot was written on
The days ahead keep only their first 16 stops, and the widget read today
from that list too, so on a busy day it showed the wrong next stop. The
full day the app wrote now stays in place on its own date.
2026-11-23 15:11:38 +01:00
Maurice a701d89fb9 fix(android): keep the start page's boot scripts in the offline copy
theme-boot.js and shell-guard.js come from the public folder, which the
build manifest does not list, so an offline start waited on the unreachable
server for them before the first paint. They are now stored and refreshed
on every launch.
2026-11-23 15:11:37 +01:00
Maurice 4fead3259d fix(android): keep a sign-in proxy's page out of the offline copy
The copy now only stores answers that come from the server itself and no
HTML in place of a script or stylesheet, so a proxy's login page no longer
replaces the stored UI.
2026-11-23 15:11:37 +01:00
Maurice 4fd8f3987f fix(planner): treat the trip opened before as still loading when another one opens
The store kept the previous trip until loadTrip ran after the first render, so the desktop planner mounted with that trip under the new id for a frame.
2026-11-23 15:11:37 +01:00
Maurice 855ec37935 fix(mail-ingest): read the inbox again when it changes while a read is on its way
A reload asked for during a read was dropped and the older answer overwrote the newer count, and an entry decided meanwhile came back with it.
2026-11-23 15:11:37 +01:00
Maurice 310e5fba8f fix(mail-ingest): forget the mail import of an account on sign-out
The store kept the forwarding address, the inbox and the badge count across a logout, so the next account on the same tab saw them until its own read landed, or for good when that read failed.
2026-11-23 15:11:37 +01:00
Maurice 8f5324c901 fix(pdf): draw the cover route of a long road trip without spreading every point into one call
The bounds came from Math.min and Math.max over all routed points, which throws past the engine's argument limit and failed the whole export on Safari and the iOS app.
2026-11-23 15:11:36 +01:00
Maurice 97c0d992c8 fix(pdf): order a day's bookings in the overview by the clock in 12h too
The booking list sorted on the printed time, so for a 12h reader 1:00 PM and 10:00 AM came before 9:30 AM.
2026-11-23 15:11:36 +01:00
Maurice cd32f07bf5 fix(roadtrip): offer and save a visit's stay under the day plan right on the desktop
The rail and the inspector offered the stay to anyone who may edit places, while a saved visit's stay needs day_edit, so the dialog closed without saving and the stop popup wrote half its change before a 403. Refusals now say so before anything is written.
2026-11-23 15:11:36 +01:00
Maurice 3c00544e93 fix(native): keep the keyboard open for controls that hold the focus in their field
A tap away blurred the field on touchend, before the sign toggle or the note format bar could cancel their mousedown, so the keypad closed mid entry. The field now lets go only once the tap's pointerdown and mousedown pass uncancelled.
2026-11-23 15:11:36 +01:00
Maurice dec3058777 fix(help): show the settings help on the admin Security and Services tabs
Both tabs fell back to the admin overview without guides, and the guides for API keys, providers and file types opened the Security tab instead of Services.
2026-11-23 15:11:36 +01:00
Maurice e459ec6e60 fix(mail-ingest): ask before closing the booking mail setup with changes not saved
The setup only keeps its fields through its own Save, yet Close, the close mark, the backdrop and the phone sheet dropped them without a word. Now each way out asks, and discarding puts the saved values back.
2026-11-23 15:11:36 +01:00
Maurice ba45dbc874 fix(admin): draw no divider under an addon whose sub-rows render nothing
A switched-off booking mail import passed false as its only child, which Children.count counts, so an empty list with a top border showed under the row.
2026-11-23 15:11:35 +01:00
Maurice fa8e1b68bd fix(mail-ingest): set an inbox entry aside once its booking is saved through Fill in yourself
The entry stayed pending after the prefilled booking was saved, kept its Add action and counted in the badge, so it could be added a second time.
2026-11-23 15:11:35 +01:00
Maurice 755ca865a4 fix(mail-ingest): open the prefilled form again for an entry asked for twice in the same trip
The guard kept the last handled entry after the link left the address, so a second Fill in yourself for it in the open trip did nothing.
2026-11-23 15:11:35 +01:00
Maurice a3caa9ca1a fix(costs): count only balances read in the shown currency in the owe and owed cards
After a currency switch the cards kept summing the flows of the previous currency, offline or while the new read ran, and printed them in the new one.
2026-11-23 15:11:35 +01:00
Maurice 344580d343 fix(share): decide what a shared link is for once the trips' Collab is read
The share sheet waits for the trip list and each trip's own Collaboration before
it acts on the share sheet's trip, and reads only the addon lists it does not hold.
2026-11-23 15:11:35 +01:00
Maurice 36ea9bdb3e fix(trip-addons): keep a pushed addon list over an older sync read
The sync reads a trip's addons through the store's load, so a tripAddons:changed
push that lands during the read stays on screen and in the offline copy.
2026-11-23 15:11:34 +01:00
Maurice c3d60e1c43 fix(sync): read the open trip's addons again after the socket reconnects
A tripAddons:changed push is not replayed, so a switch made while the socket was
down now reaches the member on the reconnect refetch.
2026-11-23 15:11:34 +01:00
Maurice 769293a554 fix(trip-addons): read the trip's lists again when their addon is switched back on
The sections of an addon that was off were read as empty, so switching Lists,
Costs or Documents back on while the trip is open now reads the trip again.
2026-11-23 15:11:34 +01:00
Maurice 56ce66f666 fix(offline): park a queued delete that a switched-off addon refuses
The 404 a route answers while its addon is off keeps the entity on the server, so
the queued delete is parked as failed and offered for retry instead of dropped.
2026-11-23 15:11:34 +01:00
Maurice fd10ce2876 fix(plugins): show a trip page that replaces a core tab while that tab's addon is off
A trip-page plugin that replaces Lists, Costs, Documents or Collab is a stand-in
for the core tab, so its own tab stays on the trip whatever that addon is set to.
2026-11-23 15:11:34 +01:00
Maurice 9d4e52ddfc perf(db): let Postgres serve ORDER BY id from the primary key
A Kysely ORDER BY on the id of a table the statement reads in its FROM no longer gets SQLite's NULL position, which no primary key row needs and which kept Postgres from reading paged latest-first lists such as the audit log off the index.
2026-11-23 15:11:34 +01:00
Maurice 52a6fbbc92 fix(scripts): read the server's .env in the admin reset and the key rotation
Both scripts now load server/.env as the server does, so an install whose TREK_DB_URL lives there resets the admin and rotates the key in its Postgres database instead of in a SQLite file left behind by the move.
2026-11-23 15:11:33 +01:00
Maurice de1c3b8ea6 fix(scripts): rotate the SQLite file TREK_DB_FILE names
The key rotation now opens the database the server runs on when TREK_DB_FILE is set, writes the new key to the key file the server reads, and refuses DB_PATH and TREK_DB_FILE naming different files.
2026-11-23 15:11:33 +01:00
Maurice 60885627b1 fix(scripts): rotate the wanderer token with the encryption key
The key rotation now re-encrypts wanderer_connections.token, so a wanderer connection keeps working after the key changes instead of calling out without its token.
2026-11-23 15:11:33 +01:00