Skip to content

armgit / TREK

Public Imported from GitHub
0

The most complete open-source travel planner: real-time collaboration, bookings, budgets, packing lists, journals, offline PWA, SSO and an AI-ready MCP server, with planet-wide place search and routing built in.

feat(notifications): events for bookings added from mail, and actions a domain registers

Maurice340454cfc7c1
diff --git a/server/src/nest/notifications/notification-events.ts b/server/src/nest/notifications/notification-events.ts
index 2116eb380..7a79b1fca 100644
--- a/server/src/nest/notifications/notification-events.ts
+++ b/server/src/nest/notifications/notification-events.ts
@@ -46,6 +46,8 @@ export type NotifEventType =
| 'paddle_region_requested'
| 'synology_session_cleared'
| 'wanderer_source_hint'
+ | 'mail_booking_added'
+ | 'mail_booking_pending'
| 'plugin_notification';
/** Every event, in the order the preferences UI lists them. */
@@ -68,6 +70,8 @@ export const ALL_EVENT_TYPES: NotifEventType[] = [
'paddle_region_requested',
'synology_session_cleared',
'wanderer_source_hint',
+ 'mail_booking_added',
+ 'mail_booking_pending',
'plugin_notification',
];
diff --git a/server/src/nest/notifications/notification-preferences.service.ts b/server/src/nest/notifications/notification-preferences.service.ts
index 59074261b..8451c1abd 100644
--- a/server/src/nest/notifications/notification-preferences.service.ts
+++ b/server/src/nest/notifications/notification-preferences.service.ts
@@ -135,6 +135,9 @@ export class NotificationPreferencesService {
case 'flight_delayed':
case 'flight_landed':
return (await resolveAppSetting(this.appSettings, 'flight_live_enabled')) !== 'false';
+ case 'mail_booking_added':
+ case 'mail_booking_pending':
+ return (await resolveAppSetting(this.appSettings, 'mail_ingest_enabled')) === 'true';
default:
return true;
}
diff --git a/server/src/nest/notifications/notifications.service.ts b/server/src/nest/notifications/notifications.service.ts
index e4260cf7a..1517f9c70 100644
--- a/server/src/nest/notifications/notifications.service.ts
+++ b/server/src/nest/notifications/notifications.service.ts
@@ -7,7 +7,7 @@ import { UnitOfWork } from '../database/unit-of-work';
import { RealtimeService } from '../realtime/realtime.service';
import { getChannel, listChannels } from './channel-registry';
import { registerBuiltinChannels } from './channels/builtins';
-import { getAction } from './in-app-actions';
+import { getAction, registerAction } from './in-app-actions';
import { getEventText } from './mailer/email-html';
import { MailerService } from './mailer/mailer.service';
import {
@@ -127,6 +127,13 @@ const WANDERER_HINT_TEXT: Record<string, { textKey: string }> = {
possible_change: { textKey: 'notif.wanderer_source_hint.possible_change' },
};
+// The two texts of a booking added from a mail: the forwarder's and a co-traveller's,
+// each in a textKey of its own for the client's key check, as above.
+const MAIL_BOOKING_TEXT: Record<'forwarder' | 'traveller', { textKey: string }> = {
+ forwarder: { textKey: 'notif.mail_booking_added.text' },
+ traveller: { textKey: 'notif.mail_booking_added.shared' },
+};
+
const EVENT_NOTIFICATION_CONFIG: Record<string, EventNotifConfig> = {
// ── Dev-only test events ──────────────────────────────────────────────────
test_simple: {
@@ -282,6 +289,23 @@ const EVENT_NOTIFICATION_CONFIG: Record<string, EventNotifConfig> = {
navigateTextKey: 'notif.action.view_tour',
navigateTarget: (p) => (p.tripId && p.placeId ? `/trips/${p.tripId}?tab=plan&place=${p.placeId}` : null),
},
+ // A booking from a forwarded mail went into a trip. The forwarder's copy is a
+ // keep/undo question (the call site makes it boolean); a co-traveller's opens the trip.
+ mail_booking_added: {
+ inAppType: 'navigate',
+ titleKey: 'notif.mail_booking_added.title',
+ textKey: (p) => (p.role === 'traveller' ? MAIL_BOOKING_TEXT.traveller : MAIL_BOOKING_TEXT.forwarder).textKey,
+ navigateTextKey: 'notif.action.view_trip',
+ navigateTarget: (p) => (p.tripId ? `/trips/${p.tripId}?tab=bookings` : null),
+ },
+ // Bookings from forwarded mails wait in the person's inbox for a decision.
+ mail_booking_pending: {
+ inAppType: 'navigate',
+ titleKey: 'notif.mail_booking_pending.title',
+ textKey: 'notif.mail_booking_pending.text',
+ navigateTextKey: 'notif.action.review',
+ navigateTarget: () => '/dashboard?inbox=mail',
+ },
synology_session_cleared: {
inAppType: 'simple',
titleKey: 'notifications.synologySessionCleared.title',
@@ -702,6 +726,20 @@ export class NotificationsService {
* @txIndependent the claim commits on its own before the action runs, so a second
* submit sees it; a failing action releases it again.
*/
+ /**
+ * Names what a tap on a yes/no notification does: a domain that sends one
+ * registers its action here from its module's init, so this module never
+ * imports the domain. The handler gets the payload the notification
+ * carried and the person who answered; a handler that throws leaves the
+ * notification unanswered, with its message as the error.
+ */
+ registerResponseAction(
+ action: string,
+ handler: (payload: Record<string, unknown>, respondingUserId: number) => Promise<void>,
+ ): void {
+ registerAction(action, handler);
+ }
+
async respond(notificationId: number, userId: number, response: NotificationResponse): Promise<RespondResult> {
const notification = await this.notificationsRepo.findByIdForRecipient(notificationId, userId);
diff --git a/server/src/nest/notifications/transports/ntfy.service.ts b/server/src/nest/notifications/transports/ntfy.service.ts
index 7eb1c41bd..41c3d4116 100644
--- a/server/src/nest/notifications/transports/ntfy.service.ts
+++ b/server/src/nest/notifications/transports/ntfy.service.ts
@@ -39,6 +39,8 @@ const NTFY_EVENT_META: Partial<Record<NotifEventType, { priority: 1 | 2 | 3 | 4
paddle_region_requested: { priority: 3, tags: ['canoe'] },
synology_session_cleared: { priority: 3, tags: ['warning'] },
wanderer_source_hint: { priority: 2, tags: ['hiking_boot'] },
+ mail_booking_added: { priority: 3, tags: ['envelope'] },
+ mail_booking_pending: { priority: 2, tags: ['envelope'] },
};
const NTFY_DEFAULT_META = { priority: 3 as const, tags: [] as string[] };
diff --git a/server/tests/unit/nest/notification-preferences.service.test.ts b/server/tests/unit/nest/notification-preferences.service.test.ts
index c10ce7e95..b0e24d13a 100644
--- a/server/tests/unit/nest/notification-preferences.service.test.ts
+++ b/server/tests/unit/nest/notification-preferences.service.test.ts
@@ -492,3 +492,14 @@ describe('listed events follow the features that are on', () => {
for (const hidden of flights) expect(event_types).not.toContain(hidden);
});
});
+
+describe('the mail import’s events follow its switch', () => {
+ it('NPREF-LIST-002: lists the mail booking events only while the import is on', async () => {
+ const { user } = createUser(testDb);
+ expect((await svc.getPreferencesMatrix(user.id, 'user')).event_types).not.toContain('mail_booking_added');
+ setAppSetting(testDb, 'mail_ingest_enabled', 'true');
+ const { event_types } = await svc.getPreferencesMatrix(user.id, 'user');
+ expect(event_types).toContain('mail_booking_added');
+ expect(event_types).toContain('mail_booking_pending');
+ });
+});
diff --git a/server/tests/unit/nest/notifications.inapp-prefs.test.ts b/server/tests/unit/nest/notifications.inapp-prefs.test.ts
index dc4efed02..75f4a114a 100644
--- a/server/tests/unit/nest/notifications.inapp-prefs.test.ts
+++ b/server/tests/unit/nest/notifications.inapp-prefs.test.ts
@@ -304,6 +304,20 @@ describe('respondToBoolean', () => {
expect(result.error).toMatch(/not a boolean/i);
});
+ it('INOTIF-008b — runs an action a domain registered, with the payload and the person who answered', async () => {
+ const { user } = createUser(testDb);
+ const seen: Array<[Record<string, unknown>, number]> = [];
+ notifications.registerResponseAction('test_registered', async (payload, userId) => {
+ seen.push([payload, userId]);
+ });
+ const id = await insertBoolean(user.id, null, 'test_registered');
+
+ const result = await respondToBoolean(id, user.id, 'positive');
+
+ expect(result.success).toBe(true);
+ expect(seen).toEqual([[{}, user.id]]);
+ });
+
it('INOTIF-009 — response on a non-existent notification returns error', async () => {
const { user } = createUser(testDb);
const result = await respondToBoolean(99999, user.id, 'positive');
diff --git a/server/tests/unit/nest/notifications.service.test.ts b/server/tests/unit/nest/notifications.service.test.ts
index 8ac812d03..37ccb75b8 100644
--- a/server/tests/unit/nest/notifications.service.test.ts
+++ b/server/tests/unit/nest/notifications.service.test.ts
@@ -632,6 +632,36 @@ describe('send() — in-app notification content', () => {
]),
);
});
+
+ it('NOTIF-MAIL-001 a mail booking tells the forwarder from a co-traveller; pending ones lead to the inbox', async () => {
+ const { user } = createUser(testDb);
+ setNotificationChannels(testDb, 'none');
+ const params = { booking: 'LH 716', trip: 'Japan', tripId: '7', actor: 'mia', type: 'flight' };
+ await send({ event: 'mail_booking_added', actorId: null, scope: 'user', targetId: user.id, params });
+ await send({
+ event: 'mail_booking_added',
+ actorId: null,
+ scope: 'user',
+ targetId: user.id,
+ params: { ...params, role: 'traveller' },
+ });
+ await send({
+ event: 'mail_booking_pending',
+ actorId: null,
+ scope: 'user',
+ targetId: user.id,
+ params: { count: '2' },
+ });
+
+ const notifs = await getInAppNotifications(user.id);
+ expect(notifs.map((n) => [n.text_key, n.navigate_target])).toEqual(
+ expect.arrayContaining([
+ ['notif.mail_booking_added.text', '/trips/7?tab=bookings'],
+ ['notif.mail_booking_added.shared', '/trips/7?tab=bookings'],
+ ['notif.mail_booking_pending.text', '/dashboard?inbox=mail'],
+ ]),
+ );
+ });
});
// ─────────────────────────────────────────────────────────────────────────────
diff --git a/shared/src/i18n/ar/externalNotifications.ts b/shared/src/i18n/ar/externalNotifications.ts
index d46a1a164..eb11f4c3c 100644
--- a/shared/src/i18n/ar/externalNotifications.ts
+++ b/shared/src/i18n/ar/externalNotifications.ts
@@ -111,6 +111,17 @@ const ar: NotificationLocale = {
? `لم يعد بالإمكان التحقق من «${p.tour}» في «${p.trip}» على wanderer. تبقى الجولة في رحلتك كما هي.`
: `ربما تغيّر «${p.tour}» في «${p.trip}» على wanderer. افتح الجولة وتحقق من مصدرها. لا يتغير شيء في الرحلة من تلقاء نفسه.`,
}),
+ mail_booking_added: (p) => ({
+ title: `أُضيف من بريد: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `أضاف ${p.actor} الحجز "${p.booking}" إلى "${p.trip}" من بريد مُعاد توجيهه.`
+ : `تمت إضافة "${p.booking}" من بريدك المُعاد توجيهه إلى "${p.trip}". يمكنك التراجع عن ذلك في TREK لمدة 7 أيام.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'حجوزات مُعاد توجيهها للمراجعة',
+ body: `حجوزات مُعاد توجيهها بانتظارك في TREK: ${p.count}. يذكر كل منها سبب عدم إضافته تلقائيًا.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/ar/notif.ts b/shared/src/i18n/ar/notif.ts
index 2bf8a97a3..8c5f73c02 100644
--- a/shared/src/i18n/ar/notif.ts
+++ b/shared/src/i18n/ar/notif.ts
@@ -59,6 +59,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'عرض',
'notif.action.accept': 'قبول',
'notif.action.decline': 'رفض',
+ 'notif.mail_booking_added.title': 'تمت إضافة حجز من بريد',
+ 'notif.mail_booking_added.text': 'تمت إضافة {booking} إلى {trip}',
+ 'notif.mail_booking_added.shared': 'أضاف {actor} الحجز {booking} إلى {trip} من بريد مُعاد توجيهه',
+ 'notif.mail_booking_pending.title': 'حجوزات مُعاد توجيهها للمراجعة',
+ 'notif.mail_booking_pending.text': 'حجوزات مُعاد توجيهها بانتظارك: {count}',
+ 'notif.action.undo': 'تراجع',
+ 'notif.action.keep': 'إبقاء',
+ 'notif.action.review': 'مراجعة',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'إشعار',
diff --git a/shared/src/i18n/az/externalNotifications.ts b/shared/src/i18n/az/externalNotifications.ts
index 0f4fb001c..e3359c166 100644
--- a/shared/src/i18n/az/externalNotifications.ts
+++ b/shared/src/i18n/az/externalNotifications.ts
@@ -96,6 +96,17 @@ const az: NotificationLocale = {
? `"${p.trip}" içində "${p.tour}" artıq wanderer-də yoxlanıla bilmir. Səfərindəki tur olduğu kimi qalır.`
: `"${p.trip}" içində "${p.tour}" wanderer-də dəyişmiş ola bilər. Turu aç və mənbəyini yoxla. Səfərdə heç nə özbaşına dəyişmir.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Məktubdan əlavə edildi: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} yönləndirilmiş məktubdakı "${p.booking}" rezervasiyasını "${p.trip}" səyahətinə əlavə etdi.`
+ : `Yönləndirdiyiniz məktubdakı "${p.booking}" rezervasiyası "${p.trip}" səyahətinə əlavə edildi. Bunu TREK-də 7 gün ərzində geri ala bilərsiniz.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Yoxlanılacaq yönləndirilmiş rezervasiyalar',
+ body: `TREK-də sizi gözləyən yönləndirilmiş rezervasiyalar: ${p.count}. Hər birində niyə avtomatik əlavə edilmədiyi yazılıb.`,
+ }),
plugin_notification: (p) => ({
title: p.title ?? '',
body: p.body ?? '',
diff --git a/shared/src/i18n/az/notif.ts b/shared/src/i18n/az/notif.ts
index 20130e006..523c87c78 100644
--- a/shared/src/i18n/az/notif.ts
+++ b/shared/src/i18n/az/notif.ts
@@ -55,6 +55,15 @@ const notif: TranslationStrings = {
'notif.action.view': 'Bax',
'notif.action.accept': 'Qəbul et',
'notif.action.decline': 'İmtina et',
+ 'notif.mail_booking_added.title': 'Rezervasiya məktubdan əlavə edildi',
+ 'notif.mail_booking_added.text': '{booking} {trip} səyahətinə əlavə edildi',
+ 'notif.mail_booking_added.shared':
+ '{actor} yönləndirilmiş məktubdan {booking} rezervasiyasını {trip} səyahətinə əlavə etdi',
+ 'notif.mail_booking_pending.title': 'Yoxlanılacaq yönləndirilmiş rezervasiyalar',
+ 'notif.mail_booking_pending.text': 'Sizi gözləyən yönləndirilmiş rezervasiyalar: {count}',
+ 'notif.action.undo': 'Geri al',
+ 'notif.action.keep': 'Saxla',
+ 'notif.action.review': 'Yoxla',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Bildiriş',
diff --git a/shared/src/i18n/br/externalNotifications.ts b/shared/src/i18n/br/externalNotifications.ts
index 819ee8c9e..2f52b078a 100644
--- a/shared/src/i18n/br/externalNotifications.ts
+++ b/shared/src/i18n/br/externalNotifications.ts
@@ -99,6 +99,17 @@ const br: NotificationLocale = {
? `“${p.tour}” em “${p.trip}” não pode mais ser verificada no wanderer. O passeio da sua viagem continua como está.`
: `“${p.tour}” em “${p.trip}” pode ter mudado no wanderer. Abra o passeio e verifique a fonte para saber. Nada na viagem muda sozinho.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Adicionada de um e-mail: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} adicionou "${p.booking}" a "${p.trip}" a partir de um e-mail encaminhado.`
+ : `"${p.booking}" do seu e-mail encaminhado foi adicionada a "${p.trip}". Você pode desfazer isso no TREK por 7 dias.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Reservas encaminhadas para revisar',
+ body: `Reservas encaminhadas aguardando você no TREK: ${p.count}. Cada uma diz por que não foi adicionada sozinha.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/br/notif.ts b/shared/src/i18n/br/notif.ts
index b4b067077..81c3527f9 100644
--- a/shared/src/i18n/br/notif.ts
+++ b/shared/src/i18n/br/notif.ts
@@ -55,6 +55,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'Ver',
'notif.action.accept': 'Aceitar',
'notif.action.decline': 'Recusar',
+ 'notif.mail_booking_added.title': 'Reserva adicionada de um e-mail',
+ 'notif.mail_booking_added.text': '{booking} foi adicionada a {trip}',
+ 'notif.mail_booking_added.shared': '{actor} adicionou {booking} a {trip} a partir de um e-mail encaminhado',
+ 'notif.mail_booking_pending.title': 'Reservas encaminhadas para revisar',
+ 'notif.mail_booking_pending.text': 'Reservas encaminhadas aguardando você: {count}',
+ 'notif.action.undo': 'Desfazer',
+ 'notif.action.keep': 'Manter',
+ 'notif.action.review': 'Revisar',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Notificação',
diff --git a/shared/src/i18n/ca/externalNotifications.ts b/shared/src/i18n/ca/externalNotifications.ts
index dc55272b5..68412ebf8 100644
--- a/shared/src/i18n/ca/externalNotifications.ts
+++ b/shared/src/i18n/ca/externalNotifications.ts
@@ -96,6 +96,17 @@ const ca: NotificationLocale = {
? `«${p.tour}» a «${p.trip}» ja no es pot comprovar a wanderer. El recorregut del teu viatge es queda com està.`
: `«${p.tour}» a «${p.trip}» pot haver canviat a wanderer. Obre el recorregut i comprova'n la font per saber-ho. Res del viatge canvia sol.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Afegit des d’un correu: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} ha afegit «${p.booking}» a «${p.trip}» des d’un correu reenviat.`
+ : `«${p.booking}» del teu correu reenviat s’ha afegit a «${p.trip}». Pots desfer-ho a TREK durant 7 dies.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Reserves reenviades per revisar',
+ body: `Reserves reenviades pendents a TREK: ${p.count}. Cadascuna diu per què no s’ha afegit sola.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/ca/notif.ts b/shared/src/i18n/ca/notif.ts
index 6312d858b..fc96bde4b 100644
--- a/shared/src/i18n/ca/notif.ts
+++ b/shared/src/i18n/ca/notif.ts
@@ -60,6 +60,14 @@ const notif: TranslationStrings = {
'notif.collection_invite.title': 'Invitació a una col·lecció',
'notif.collection_invite.text': "{actor} t'ha enviat una invitació per compartir una col·lecció",
'notif.action.view_collection': 'Veure col·lecció',
+ 'notif.mail_booking_added.title': 'Reserva afegida des d’un correu',
+ 'notif.mail_booking_added.text': '{booking} s’ha afegit a {trip}',
+ 'notif.mail_booking_added.shared': '{actor} ha afegit {booking} a {trip} des d’un correu reenviat',
+ 'notif.mail_booking_pending.title': 'Reserves reenviades per revisar',
+ 'notif.mail_booking_pending.text': 'Reserves reenviades pendents: {count}',
+ 'notif.action.undo': 'Desfés',
+ 'notif.action.keep': 'Conserva',
+ 'notif.action.review': 'Revisa',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
};
diff --git a/shared/src/i18n/cs/externalNotifications.ts b/shared/src/i18n/cs/externalNotifications.ts
index b00df273c..a57cbcf12 100644
--- a/shared/src/i18n/cs/externalNotifications.ts
+++ b/shared/src/i18n/cs/externalNotifications.ts
@@ -102,6 +102,17 @@ const cs: NotificationLocale = {
? `„${p.tour}“ v „${p.trip}“ už nelze ve wanderer ověřit. Túra ve vaší cestě zůstává, jak je.`
: `„${p.tour}“ v „${p.trip}“ se ve wanderer možná změnila. Otevřete túru a zkontrolujte její zdroj. V cestě se nic nezmění samo.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Přidáno z e-mailu: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} přidal(a) „${p.booking}“ do „${p.trip}“ z přeposlaného e-mailu.`
+ : `„${p.booking}“ z vašeho přeposlaného e-mailu byla přidána do „${p.trip}“. V TREK to můžete 7 dní vrátit zpět.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Přeposlané rezervace ke kontrole',
+ body: `Přeposlané rezervace čekající na vás v TREK: ${p.count}. U každé je uvedeno, proč nebyla přidána sama.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/cs/notif.ts b/shared/src/i18n/cs/notif.ts
index 3e2525d11..18456d0fc 100644
--- a/shared/src/i18n/cs/notif.ts
+++ b/shared/src/i18n/cs/notif.ts
@@ -56,6 +56,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'Zobrazit',
'notif.action.accept': 'Přijmout',
'notif.action.decline': 'Odmítnout',
+ 'notif.mail_booking_added.title': 'Rezervace přidána z e-mailu',
+ 'notif.mail_booking_added.text': '{booking} byla přidána do {trip}',
+ 'notif.mail_booking_added.shared': '{actor} přidal(a) {booking} do {trip} z přeposlaného e-mailu',
+ 'notif.mail_booking_pending.title': 'Přeposlané rezervace ke kontrole',
+ 'notif.mail_booking_pending.text': 'Přeposlané rezervace čekající na vás: {count}',
+ 'notif.action.undo': 'Vrátit zpět',
+ 'notif.action.keep': 'Ponechat',
+ 'notif.action.review': 'Zkontrolovat',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Oznámení',
diff --git a/shared/src/i18n/de/externalNotifications.ts b/shared/src/i18n/de/externalNotifications.ts
index 6005d992b..c4faafea8 100644
--- a/shared/src/i18n/de/externalNotifications.ts
+++ b/shared/src/i18n/de/externalNotifications.ts
@@ -96,6 +96,17 @@ const de: NotificationLocale = {
? `„${p.tour}“ in „${p.trip}“ lässt sich in wanderer nicht mehr prüfen. Die Tour in deiner Reise bleibt, wie sie ist.`
: `„${p.tour}“ in „${p.trip}“ hat sich in wanderer möglicherweise geändert. Öffne die Tour und prüfe ihre Quelle, um es zu sehen. In der Reise ändert sich nichts von selbst.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Aus einer Mail eingetragen: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} hat „${p.booking}“ aus einer weitergeleiteten Mail in „${p.trip}“ eingetragen.`
+ : `„${p.booking}“ aus deiner weitergeleiteten Mail wurde in „${p.trip}“ eingetragen. Du kannst das 7 Tage lang in TREK rückgängig machen.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Weitergeleitete Buchungen prüfen',
+ body: `In TREK warten weitergeleitete Buchungen auf dich: ${p.count}. Bei jeder steht, warum sie nicht von selbst eingetragen wurde.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/de/notif.ts b/shared/src/i18n/de/notif.ts
index 0861716fb..4c8829a24 100644
--- a/shared/src/i18n/de/notif.ts
+++ b/shared/src/i18n/de/notif.ts
@@ -55,6 +55,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'Ansehen',
'notif.action.accept': 'Annehmen',
'notif.action.decline': 'Ablehnen',
+ 'notif.mail_booking_added.title': 'Buchung aus einer Mail eingetragen',
+ 'notif.mail_booking_added.text': '{booking} wurde in {trip} eingetragen',
+ 'notif.mail_booking_added.shared': '{actor} hat {booking} aus einer weitergeleiteten Mail in {trip} eingetragen',
+ 'notif.mail_booking_pending.title': 'Weitergeleitete Buchungen prüfen',
+ 'notif.mail_booking_pending.text': 'Weitergeleitete Buchungen warten auf dich: {count}',
+ 'notif.action.undo': 'Rückgängig',
+ 'notif.action.keep': 'Behalten',
+ 'notif.action.review': 'Prüfen',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Benachrichtigung',
diff --git a/shared/src/i18n/en/externalNotifications.ts b/shared/src/i18n/en/externalNotifications.ts
index a1f42608e..5a633722f 100644
--- a/shared/src/i18n/en/externalNotifications.ts
+++ b/shared/src/i18n/en/externalNotifications.ts
@@ -96,6 +96,17 @@ const en: NotificationLocale = {
? `"${p.tour}" in "${p.trip}" can no longer be checked in wanderer. The tour in your trip stays as it is.`
: `"${p.tour}" in "${p.trip}" may have changed in wanderer. Open the tour and check its source to see whether it did. Nothing in the trip changes by itself.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Added from a mail: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} added "${p.booking}" to "${p.trip}" from a forwarded mail.`
+ : `"${p.booking}" from your forwarded mail was added to "${p.trip}". You can undo it in TREK for 7 days.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Forwarded bookings to review',
+ body: `Forwarded bookings waiting for you in TREK: ${p.count}. Each one says why it was not added on its own.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/en/notif.ts b/shared/src/i18n/en/notif.ts
index 2395ae0c1..c214d4a32 100644
--- a/shared/src/i18n/en/notif.ts
+++ b/shared/src/i18n/en/notif.ts
@@ -55,6 +55,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'View',
'notif.action.accept': 'Accept',
'notif.action.decline': 'Decline',
+ 'notif.mail_booking_added.title': 'Booking added from a mail',
+ 'notif.mail_booking_added.text': '{booking} was added to {trip}',
+ 'notif.mail_booking_added.shared': '{actor} added {booking} to {trip} from a forwarded mail',
+ 'notif.mail_booking_pending.title': 'Forwarded bookings to review',
+ 'notif.mail_booking_pending.text': 'Forwarded bookings waiting for you: {count}',
+ 'notif.action.undo': 'Undo',
+ 'notif.action.keep': 'Keep',
+ 'notif.action.review': 'Review',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Notification',
diff --git a/shared/src/i18n/es/externalNotifications.ts b/shared/src/i18n/es/externalNotifications.ts
index 7cd999637..6cc347e2e 100644
--- a/shared/src/i18n/es/externalNotifications.ts
+++ b/shared/src/i18n/es/externalNotifications.ts
@@ -96,6 +96,17 @@ const es: NotificationLocale = {
? `«${p.tour}» en «${p.trip}» ya no se puede comprobar en wanderer. El recorrido de tu viaje se queda como está.`
: `«${p.tour}» en «${p.trip}» puede haber cambiado en wanderer. Abre el recorrido y comprueba su fuente para saberlo. Nada del viaje cambia por sí solo.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Añadido desde un correo: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} añadió «${p.booking}» a «${p.trip}» desde un correo reenviado.`
+ : `«${p.booking}» de tu correo reenviado se añadió a «${p.trip}». Puedes deshacerlo en TREK durante 7 días.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Reservas reenviadas por revisar',
+ body: `Reservas reenviadas pendientes en TREK: ${p.count}. Cada una indica por qué no se añadió sola.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/es/notif.ts b/shared/src/i18n/es/notif.ts
index e3358e41e..13c702828 100644
--- a/shared/src/i18n/es/notif.ts
+++ b/shared/src/i18n/es/notif.ts
@@ -55,6 +55,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'Ver',
'notif.action.accept': 'Aceptar',
'notif.action.decline': 'Rechazar',
+ 'notif.mail_booking_added.title': 'Reserva añadida desde un correo',
+ 'notif.mail_booking_added.text': '{booking} se añadió a {trip}',
+ 'notif.mail_booking_added.shared': '{actor} añadió {booking} a {trip} desde un correo reenviado',
+ 'notif.mail_booking_pending.title': 'Reservas reenviadas por revisar',
+ 'notif.mail_booking_pending.text': 'Reservas reenviadas pendientes: {count}',
+ 'notif.action.undo': 'Deshacer',
+ 'notif.action.keep': 'Mantener',
+ 'notif.action.review': 'Revisar',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Notificación',
diff --git a/shared/src/i18n/et/externalNotifications.ts b/shared/src/i18n/et/externalNotifications.ts
index 1e5a904b4..18b8fa9b9 100644
--- a/shared/src/i18n/et/externalNotifications.ts
+++ b/shared/src/i18n/et/externalNotifications.ts
@@ -97,6 +97,17 @@ const et: NotificationLocale = {
? `„${p.tour}“ reisil „${p.trip}“ ei saa wandereris enam kontrollida. Matk sinu reisis jääb samaks.`
: `„${p.tour}“ reisil „${p.trip}“ võib olla wandereris muutunud. Ava matk ja kontrolli selle allikat. Reisis ei muutu midagi iseenesest.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Lisatud kirjast: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} lisas edastatud kirjast „${p.booking}“ reisile „${p.trip}“.`
+ : `„${p.booking}“ sinu edastatud kirjast lisati reisile „${p.trip}“. Saad selle TREKis 7 päeva jooksul tagasi võtta.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Ülevaatamist ootavad edastatud broneeringud',
+ body: `TREKis ootavad sind edastatud broneeringud: ${p.count}. Igaühe juures on kirjas, miks seda ise ei lisatud.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/et/notif.ts b/shared/src/i18n/et/notif.ts
index 2703d55df..54fed424f 100644
--- a/shared/src/i18n/et/notif.ts
+++ b/shared/src/i18n/et/notif.ts
@@ -55,6 +55,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'Vaata',
'notif.action.accept': 'Nõustu',
'notif.action.decline': 'Keeldu',
+ 'notif.mail_booking_added.title': 'Broneering lisati kirjast',
+ 'notif.mail_booking_added.text': '{booking} lisati reisile {trip}',
+ 'notif.mail_booking_added.shared': '{actor} lisas edastatud kirjast {booking} reisile {trip}',
+ 'notif.mail_booking_pending.title': 'Ülevaatamist ootavad edastatud broneeringud',
+ 'notif.mail_booking_pending.text': 'Sind ootavad edastatud broneeringud: {count}',
+ 'notif.action.undo': 'Võta tagasi',
+ 'notif.action.keep': 'Jäta alles',
+ 'notif.action.review': 'Vaata üle',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Teavitus',
diff --git a/shared/src/i18n/externalNotifications/types.ts b/shared/src/i18n/externalNotifications/types.ts
index 6225df747..e0a6fb4a9 100644
--- a/shared/src/i18n/externalNotifications/types.ts
+++ b/shared/src/i18n/externalNotifications/types.ts
@@ -40,6 +40,8 @@ export type NotificationEventKey =
| 'paddle_region_requested'
| 'synology_session_cleared'
| 'wanderer_source_hint'
+ | 'mail_booking_added'
+ | 'mail_booking_pending'
| 'plugin_notification';
export interface NotificationLocale {
diff --git a/shared/src/i18n/fr/externalNotifications.ts b/shared/src/i18n/fr/externalNotifications.ts
index e0c5200af..36b2391e7 100644
--- a/shared/src/i18n/fr/externalNotifications.ts
+++ b/shared/src/i18n/fr/externalNotifications.ts
@@ -96,6 +96,17 @@ const fr: NotificationLocale = {
? `« ${p.tour} » dans « ${p.trip} » ne peut plus être vérifié dans wanderer. Le parcours de votre voyage reste tel quel.`
: `« ${p.tour} » dans « ${p.trip} » a peut-être changé dans wanderer. Ouvrez le parcours et vérifiez sa source pour le savoir. Rien ne change de lui-même dans le voyage.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Ajouté depuis un e-mail : ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} a ajouté « ${p.booking} » à « ${p.trip} » depuis un e-mail transféré.`
+ : `« ${p.booking} » de votre e-mail transféré a été ajouté à « ${p.trip} ». Vous pouvez l’annuler dans TREK pendant 7 jours.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Réservations transférées à vérifier',
+ body: `Réservations transférées en attente dans TREK : ${p.count}. Chacune indique pourquoi elle n’a pas été ajoutée automatiquement.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/fr/notif.ts b/shared/src/i18n/fr/notif.ts
index 1a60b9079..593e32d3e 100644
--- a/shared/src/i18n/fr/notif.ts
+++ b/shared/src/i18n/fr/notif.ts
@@ -55,6 +55,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'Voir',
'notif.action.accept': 'Accepter',
'notif.action.decline': 'Refuser',
+ 'notif.mail_booking_added.title': 'Réservation ajoutée depuis un e-mail',
+ 'notif.mail_booking_added.text': '{booking} a été ajouté à {trip}',
+ 'notif.mail_booking_added.shared': '{actor} a ajouté {booking} à {trip} depuis un e-mail transféré',
+ 'notif.mail_booking_pending.title': 'Réservations transférées à vérifier',
+ 'notif.mail_booking_pending.text': 'Réservations transférées en attente : {count}',
+ 'notif.action.undo': 'Annuler',
+ 'notif.action.keep': 'Garder',
+ 'notif.action.review': 'Vérifier',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Notification', // same-as-en
diff --git a/shared/src/i18n/gr/externalNotifications.ts b/shared/src/i18n/gr/externalNotifications.ts
index 108c0fff0..24dfe9fea 100644
--- a/shared/src/i18n/gr/externalNotifications.ts
+++ b/shared/src/i18n/gr/externalNotifications.ts
@@ -99,6 +99,17 @@ const gr: NotificationLocale = {
? `«${p.tour}» στο «${p.trip}» δεν ελέγχεται πια στο wanderer. Η διαδρομή στο ταξίδι σου μένει ως έχει.`
: `«${p.tour}» στο «${p.trip}» ίσως άλλαξε στο wanderer. Άνοιξε τη διαδρομή και έλεγξε την πηγή της. Στο ταξίδι τίποτα δεν αλλάζει από μόνο του.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Προστέθηκε από email: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `Ο/Η ${p.actor} πρόσθεσε την κράτηση «${p.booking}» στο «${p.trip}» από προωθημένο email.`
+ : `Η κράτηση «${p.booking}» από το προωθημένο email σας προστέθηκε στο «${p.trip}». Μπορείτε να την αναιρέσετε στο TREK για 7 ημέρες.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Προωθημένες κρατήσεις για έλεγχο',
+ body: `Προωθημένες κρατήσεις σε αναμονή στο TREK: ${p.count}. Σε καθεμία αναφέρεται γιατί δεν προστέθηκε αυτόματα.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/gr/notif.ts b/shared/src/i18n/gr/notif.ts
index 80f314cc4..f89ba4e45 100644
--- a/shared/src/i18n/gr/notif.ts
+++ b/shared/src/i18n/gr/notif.ts
@@ -55,6 +55,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'Προβολή',
'notif.action.accept': 'Αποδοχή',
'notif.action.decline': 'Απόρριψη',
+ 'notif.mail_booking_added.title': 'Κράτηση προστέθηκε από email',
+ 'notif.mail_booking_added.text': 'Η κράτηση {booking} προστέθηκε στο {trip}',
+ 'notif.mail_booking_added.shared': 'Ο/Η {actor} πρόσθεσε την κράτηση {booking} στο {trip} από προωθημένο email',
+ 'notif.mail_booking_pending.title': 'Προωθημένες κρατήσεις για έλεγχο',
+ 'notif.mail_booking_pending.text': 'Προωθημένες κρατήσεις σε αναμονή: {count}',
+ 'notif.action.undo': 'Αναίρεση',
+ 'notif.action.keep': 'Διατήρηση',
+ 'notif.action.review': 'Έλεγχος',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Ειδοποίηση',
diff --git a/shared/src/i18n/he/externalNotifications.ts b/shared/src/i18n/he/externalNotifications.ts
index b96109e16..036968aee 100644
--- a/shared/src/i18n/he/externalNotifications.ts
+++ b/shared/src/i18n/he/externalNotifications.ts
@@ -102,6 +102,17 @@ const he: NotificationLocale = {
? `כבר אי אפשר לבדוק את "${p.tour}" ב-"${p.trip}" ב-wanderer. המסלול בטיול שלכם נשאר כמו שהוא.`
: `ייתכן ש-"${p.tour}" ב-"${p.trip}" השתנה ב-wanderer. פתחו את המסלול ובדקו את המקור שלו כדי לראות אם כן. שום דבר בטיול לא משתנה מעצמו.`,
}),
+ mail_booking_added: (p) => ({
+ title: `נוספה מדוא״ל: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} הוסיף/ה את "${p.booking}" אל "${p.trip}" מדוא״ל שהועבר.`
+ : `"${p.booking}" מהדוא״ל שהעברתם נוספה אל "${p.trip}". אפשר לבטל זאת ב-TREK במשך 7 ימים.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'הזמנות שהועברו לבדיקה',
+ body: `הזמנות שהועברו וממתינות לכם ב-TREK: ${p.count}. ליד כל אחת כתוב מדוע לא נוספה אוטומטית.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/he/notif.ts b/shared/src/i18n/he/notif.ts
index 90ae30df3..3d0499235 100644
--- a/shared/src/i18n/he/notif.ts
+++ b/shared/src/i18n/he/notif.ts
@@ -56,6 +56,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'הצגה',
'notif.action.accept': 'אישור',
'notif.action.decline': 'דחייה',
+ 'notif.mail_booking_added.title': 'הזמנה נוספה מדוא״ל',
+ 'notif.mail_booking_added.text': '{booking} נוספה אל {trip}',
+ 'notif.mail_booking_added.shared': '{actor} הוסיף/ה את {booking} אל {trip} מדוא״ל שהועבר',
+ 'notif.mail_booking_pending.title': 'הזמנות שהועברו לבדיקה',
+ 'notif.mail_booking_pending.text': 'הזמנות שהועברו וממתינות לכם: {count}',
+ 'notif.action.undo': 'ביטול',
+ 'notif.action.keep': 'השארה',
+ 'notif.action.review': 'בדיקה',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'התראה',
diff --git a/shared/src/i18n/hu/externalNotifications.ts b/shared/src/i18n/hu/externalNotifications.ts
index 241293628..e50ea0d1b 100644
--- a/shared/src/i18n/hu/externalNotifications.ts
+++ b/shared/src/i18n/hu/externalNotifications.ts
@@ -96,6 +96,17 @@ const hu: NotificationLocale = {
? `„${p.tour}” („${p.trip}”) már nem ellenőrizhető a wandererben. A túra az utazásodban változatlan marad.`
: `„${p.tour}” („${p.trip}”) megváltozhatott a wandererben. Nyisd meg a túrát, és ellenőrizd a forrását. Az utazásban semmi sem változik magától.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Levélből hozzáadva: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} egy továbbított levélből hozzáadta a(z) „${p.booking}” foglalást ehhez: „${p.trip}”.`
+ : `A továbbított leveledből származó „${p.booking}” foglalás bekerült ide: „${p.trip}”. A TREK-ben 7 napig visszavonhatod.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Ellenőrizendő továbbított foglalások',
+ body: `Rád váró továbbított foglalások a TREK-ben: ${p.count}. Mindegyiknél ott áll, miért nem került be magától.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/hu/notif.ts b/shared/src/i18n/hu/notif.ts
index b542fc2c5..794d709c6 100644
--- a/shared/src/i18n/hu/notif.ts
+++ b/shared/src/i18n/hu/notif.ts
@@ -55,6 +55,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'Megtekintés',
'notif.action.accept': 'Elfogadás',
'notif.action.decline': 'Elutasítás',
+ 'notif.mail_booking_added.title': 'Foglalás hozzáadva levélből',
+ 'notif.mail_booking_added.text': '{booking} hozzáadva ehhez: {trip}',
+ 'notif.mail_booking_added.shared': '{actor} hozzáadta: {booking}, ehhez: {trip}, egy továbbított levélből',
+ 'notif.mail_booking_pending.title': 'Ellenőrizendő továbbított foglalások',
+ 'notif.mail_booking_pending.text': 'Rád váró továbbított foglalások: {count}',
+ 'notif.action.undo': 'Visszavonás',
+ 'notif.action.keep': 'Megtartás',
+ 'notif.action.review': 'Ellenőrzés',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Értesítés',
diff --git a/shared/src/i18n/id/externalNotifications.ts b/shared/src/i18n/id/externalNotifications.ts
index 64493c014..d068839c1 100644
--- a/shared/src/i18n/id/externalNotifications.ts
+++ b/shared/src/i18n/id/externalNotifications.ts
@@ -87,6 +87,17 @@ const id: NotificationLocale = {
? `“${p.tour}” di “${p.trip}” tidak dapat diperiksa lagi di wanderer. Tur di perjalanan Anda tetap seperti semula.`
: `“${p.tour}” di “${p.trip}” mungkin berubah di wanderer. Buka tur dan periksa sumbernya. Tidak ada yang berubah sendiri di perjalanan.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Ditambahkan dari email: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} menambahkan "${p.booking}" ke "${p.trip}" dari email yang diteruskan.`
+ : `"${p.booking}" dari email yang kamu teruskan ditambahkan ke "${p.trip}". Kamu bisa mengurungkannya di TREK selama 7 hari.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Pemesanan terusan untuk ditinjau',
+ body: `Pemesanan terusan yang menunggumu di TREK: ${p.count}. Masing-masing menyebutkan mengapa tidak ditambahkan otomatis.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/id/notif.ts b/shared/src/i18n/id/notif.ts
index 1d6402425..10ff69642 100644
--- a/shared/src/i18n/id/notif.ts
+++ b/shared/src/i18n/id/notif.ts
@@ -54,6 +54,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'Lihat',
'notif.action.accept': 'Terima',
'notif.action.decline': 'Tolak',
+ 'notif.mail_booking_added.title': 'Pemesanan ditambahkan dari email',
+ 'notif.mail_booking_added.text': '{booking} ditambahkan ke {trip}',
+ 'notif.mail_booking_added.shared': '{actor} menambahkan {booking} ke {trip} dari email yang diteruskan',
+ 'notif.mail_booking_pending.title': 'Pemesanan terusan untuk ditinjau',
+ 'notif.mail_booking_pending.text': 'Pemesanan terusan yang menunggumu: {count}',
+ 'notif.action.undo': 'Urungkan',
+ 'notif.action.keep': 'Simpan',
+ 'notif.action.review': 'Tinjau',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Notifikasi',
diff --git a/shared/src/i18n/it/externalNotifications.ts b/shared/src/i18n/it/externalNotifications.ts
index cc2d70623..9495d0c1f 100644
--- a/shared/src/i18n/it/externalNotifications.ts
+++ b/shared/src/i18n/it/externalNotifications.ts
@@ -93,6 +93,17 @@ const it: NotificationLocale = {
? `«${p.tour}» in «${p.trip}» non si può più controllare in wanderer. Il percorso nel tuo viaggio resta com'è.`
: `«${p.tour}» in «${p.trip}» potrebbe essere cambiato in wanderer. Apri il percorso e controlla la sua fonte per saperlo. Nel viaggio non cambia nulla da solo.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Aggiunta da un’email: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} ha aggiunto «${p.booking}» a «${p.trip}» da un’email inoltrata.`
+ : `«${p.booking}» dalla tua email inoltrata è stata aggiunta a «${p.trip}». Puoi annullarla in TREK per 7 giorni.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Prenotazioni inoltrate da controllare',
+ body: `Prenotazioni inoltrate in attesa in TREK: ${p.count}. Ognuna indica perché non è stata aggiunta da sola.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/it/notif.ts b/shared/src/i18n/it/notif.ts
index 90b54fa7e..dd2a3c49f 100644
--- a/shared/src/i18n/it/notif.ts
+++ b/shared/src/i18n/it/notif.ts
@@ -55,6 +55,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'Vedi',
'notif.action.accept': 'Accetta',
'notif.action.decline': 'Rifiuta',
+ 'notif.mail_booking_added.title': 'Prenotazione aggiunta da un’email',
+ 'notif.mail_booking_added.text': '{booking} è stata aggiunta a {trip}',
+ 'notif.mail_booking_added.shared': '{actor} ha aggiunto {booking} a {trip} da un’email inoltrata',
+ 'notif.mail_booking_pending.title': 'Prenotazioni inoltrate da controllare',
+ 'notif.mail_booking_pending.text': 'Prenotazioni inoltrate in attesa: {count}',
+ 'notif.action.undo': 'Annulla',
+ 'notif.action.keep': 'Mantieni',
+ 'notif.action.review': 'Controlla',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Notifica',
diff --git a/shared/src/i18n/ja/externalNotifications.ts b/shared/src/i18n/ja/externalNotifications.ts
index 8b44b6492..2081601a0 100644
--- a/shared/src/i18n/ja/externalNotifications.ts
+++ b/shared/src/i18n/ja/externalNotifications.ts
@@ -87,6 +87,17 @@ const ja: NotificationLocale = {
? `「${p.trip}」の「${p.tour}」は wanderer で確認できなくなりました。旅行内のツアーはそのまま残ります。`
: `「${p.trip}」の「${p.tour}」が wanderer で変更された可能性があります。ツアーを開いてソースを確認してください。旅行の内容が勝手に変わることはありません。`,
}),
+ mail_booking_added: (p) => ({
+ title: `メールから追加: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} が転送メールから「${p.booking}」を「${p.trip}」に追加しました。`
+ : `転送したメールの「${p.booking}」を「${p.trip}」に追加しました。TREK で 7 日間は元に戻せます。`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: '確認待ちの転送予約',
+ body: `TREK に確認待ちの転送予約があります: ${p.count} 件。それぞれに自動で追加されなかった理由が表示されます。`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/ja/notif.ts b/shared/src/i18n/ja/notif.ts
index af2b83ede..b62aa2097 100644
--- a/shared/src/i18n/ja/notif.ts
+++ b/shared/src/i18n/ja/notif.ts
@@ -54,6 +54,14 @@ const notif: TranslationStrings = {
'notif.action.view': '表示',
'notif.action.accept': '承認',
'notif.action.decline': '拒否',
+ 'notif.mail_booking_added.title': 'メールから予約を追加しました',
+ 'notif.mail_booking_added.text': '{booking} を {trip} に追加しました',
+ 'notif.mail_booking_added.shared': '{actor} が転送メールから {booking} を {trip} に追加しました',
+ 'notif.mail_booking_pending.title': '確認待ちの転送予約',
+ 'notif.mail_booking_pending.text': '確認待ちの転送予約: {count} 件',
+ 'notif.action.undo': '元に戻す',
+ 'notif.action.keep': '残す',
+ 'notif.action.review': '確認',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': '通知',
diff --git a/shared/src/i18n/ko/externalNotifications.ts b/shared/src/i18n/ko/externalNotifications.ts
index 929745bb2..9ffe3db77 100644
--- a/shared/src/i18n/ko/externalNotifications.ts
+++ b/shared/src/i18n/ko/externalNotifications.ts
@@ -87,6 +87,17 @@ const ko: NotificationLocale = {
? `"${p.trip}"의 "${p.tour}"은(는) 더 이상 wanderer에서 확인할 수 없습니다. 여행의 투어는 그대로 유지됩니다.`
: `"${p.trip}"의 "${p.tour}"이(가) wanderer에서 바뀌었을 수 있습니다. 투어를 열고 소스를 확인하세요. 여행의 내용은 저절로 바뀌지 않습니다.`,
}),
+ mail_booking_added: (p) => ({
+ title: `메일에서 추가됨: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} 님이 전달된 메일에서 "${p.booking}"을(를) "${p.trip}"에 추가했습니다.`
+ : `전달한 메일의 "${p.booking}"이(가) "${p.trip}"에 추가되었습니다. TREK에서 7일 동안 실행 취소할 수 있습니다.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: '검토할 전달된 예약',
+ body: `TREK에서 검토를 기다리는 전달된 예약: ${p.count}개. 각 예약에 자동으로 추가되지 않은 이유가 표시됩니다.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/ko/notif.ts b/shared/src/i18n/ko/notif.ts
index cc4a4bdfb..e762235cf 100644
--- a/shared/src/i18n/ko/notif.ts
+++ b/shared/src/i18n/ko/notif.ts
@@ -54,6 +54,14 @@ const notif: TranslationStrings = {
'notif.action.view': '보기',
'notif.action.accept': '수락',
'notif.action.decline': '거절',
+ 'notif.mail_booking_added.title': '메일에서 예약을 추가했습니다',
+ 'notif.mail_booking_added.text': '{booking}이(가) {trip}에 추가되었습니다',
+ 'notif.mail_booking_added.shared': '{actor} 님이 전달된 메일에서 {booking}을(를) {trip}에 추가했습니다',
+ 'notif.mail_booking_pending.title': '검토할 전달된 예약',
+ 'notif.mail_booking_pending.text': '검토를 기다리는 전달된 예약: {count}개',
+ 'notif.action.undo': '실행 취소',
+ 'notif.action.keep': '유지',
+ 'notif.action.review': '검토',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': '알림',
diff --git a/shared/src/i18n/nl/externalNotifications.ts b/shared/src/i18n/nl/externalNotifications.ts
index 976b7b80e..ee0a1e512 100644
--- a/shared/src/i18n/nl/externalNotifications.ts
+++ b/shared/src/i18n/nl/externalNotifications.ts
@@ -96,6 +96,17 @@ const nl: NotificationLocale = {
? `‘${p.tour}’ in ‘${p.trip}’ kan niet meer worden gecontroleerd in wanderer. De tocht in je reis blijft zoals hij is.`
: `‘${p.tour}’ in ‘${p.trip}’ is mogelijk gewijzigd in wanderer. Open de tocht en controleer de bron om het te zien. In de reis verandert niets vanzelf.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Toegevoegd uit een mail: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} heeft "${p.booking}" uit een doorgestuurde mail aan "${p.trip}" toegevoegd.`
+ : `"${p.booking}" uit je doorgestuurde mail is toegevoegd aan "${p.trip}". Je kunt dit 7 dagen lang in TREK ongedaan maken.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Doorgestuurde boekingen om te controleren',
+ body: `In TREK wachten doorgestuurde boekingen op je: ${p.count}. Bij elke staat waarom hij niet vanzelf is toegevoegd.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/nl/notif.ts b/shared/src/i18n/nl/notif.ts
index 0e235b539..d33b01c11 100644
--- a/shared/src/i18n/nl/notif.ts
+++ b/shared/src/i18n/nl/notif.ts
@@ -55,6 +55,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'Bekijken',
'notif.action.accept': 'Accepteren',
'notif.action.decline': 'Weigeren',
+ 'notif.mail_booking_added.title': 'Boeking toegevoegd uit een mail',
+ 'notif.mail_booking_added.text': '{booking} is toegevoegd aan {trip}',
+ 'notif.mail_booking_added.shared': '{actor} heeft {booking} uit een doorgestuurde mail aan {trip} toegevoegd',
+ 'notif.mail_booking_pending.title': 'Doorgestuurde boekingen om te controleren',
+ 'notif.mail_booking_pending.text': 'Doorgestuurde boekingen wachten op je: {count}',
+ 'notif.action.undo': 'Ongedaan maken',
+ 'notif.action.keep': 'Behouden',
+ 'notif.action.review': 'Controleren',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Melding',
diff --git a/shared/src/i18n/pl/externalNotifications.ts b/shared/src/i18n/pl/externalNotifications.ts
index c36873fda..c53c25a7e 100644
--- a/shared/src/i18n/pl/externalNotifications.ts
+++ b/shared/src/i18n/pl/externalNotifications.ts
@@ -105,6 +105,17 @@ const pl: NotificationLocale = {
? `„${p.tour}” w „${p.trip}” nie da się już sprawdzić w wanderer. Trasa w twojej podróży pozostaje bez zmian.`
: `„${p.tour}” w „${p.trip}” mógł się zmienić w wanderer. Otwórz trasę i sprawdź jej źródło. W podróży nic nie zmienia się samo.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Dodano z wiadomości: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} dodał(a) „${p.booking}” do „${p.trip}” z przekazanej wiadomości.`
+ : `„${p.booking}” z Twojej przekazanej wiadomości dodano do „${p.trip}”. Możesz to cofnąć w TREK przez 7 dni.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Przekazane rezerwacje do sprawdzenia',
+ body: `Przekazane rezerwacje czekające na Ciebie w TREK: ${p.count}. Przy każdej podano, dlaczego nie została dodana automatycznie.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/pl/notif.ts b/shared/src/i18n/pl/notif.ts
index e354b9d51..5ee549671 100644
--- a/shared/src/i18n/pl/notif.ts
+++ b/shared/src/i18n/pl/notif.ts
@@ -57,6 +57,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'Zobacz',
'notif.action.accept': 'Akceptuj',
'notif.action.decline': 'Odrzuć',
+ 'notif.mail_booking_added.title': 'Rezerwacja dodana z wiadomości',
+ 'notif.mail_booking_added.text': '{booking} dodano do {trip}',
+ 'notif.mail_booking_added.shared': '{actor} dodał(a) {booking} do {trip} z przekazanej wiadomości',
+ 'notif.mail_booking_pending.title': 'Przekazane rezerwacje do sprawdzenia',
+ 'notif.mail_booking_pending.text': 'Przekazane rezerwacje czekające na Ciebie: {count}',
+ 'notif.action.undo': 'Cofnij',
+ 'notif.action.keep': 'Zachowaj',
+ 'notif.action.review': 'Sprawdź',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Powiadomienie',
diff --git a/shared/src/i18n/ru/externalNotifications.ts b/shared/src/i18n/ru/externalNotifications.ts
index 993e21530..188ce8878 100644
--- a/shared/src/i18n/ru/externalNotifications.ts
+++ b/shared/src/i18n/ru/externalNotifications.ts
@@ -100,6 +100,17 @@ const ru: NotificationLocale = {
? `«${p.tour}» в «${p.trip}» больше нельзя проверить в wanderer. Тур в вашей поездке остаётся как есть.`
: `«${p.tour}» в «${p.trip}», возможно, изменён в wanderer. Откройте тур и проверьте его источник. В поездке ничего не меняется само.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Добавлено из письма: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} добавил(а) «${p.booking}» в «${p.trip}» из пересланного письма.`
+ : `«${p.booking}» из вашего пересланного письма добавлено в «${p.trip}». В TREK это можно отменить в течение 7 дней.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Пересланные бронирования для проверки',
+ body: `Пересланных бронирований ждёт вас в TREK: ${p.count}. У каждого указано, почему оно не добавлено автоматически.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/ru/notif.ts b/shared/src/i18n/ru/notif.ts
index 9113e62a8..e1f430780 100644
--- a/shared/src/i18n/ru/notif.ts
+++ b/shared/src/i18n/ru/notif.ts
@@ -57,6 +57,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'Открыть',
'notif.action.accept': 'Принять',
'notif.action.decline': 'Отклонить',
+ 'notif.mail_booking_added.title': 'Бронирование добавлено из письма',
+ 'notif.mail_booking_added.text': '{booking} добавлено в {trip}',
+ 'notif.mail_booking_added.shared': '{actor} добавил(а) {booking} в {trip} из пересланного письма',
+ 'notif.mail_booking_pending.title': 'Пересланные бронирования для проверки',
+ 'notif.mail_booking_pending.text': 'Пересланных бронирований ждёт вас: {count}',
+ 'notif.action.undo': 'Отменить',
+ 'notif.action.keep': 'Оставить',
+ 'notif.action.review': 'Проверить',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Уведомление',
diff --git a/shared/src/i18n/sk/externalNotifications.ts b/shared/src/i18n/sk/externalNotifications.ts
index 826e5e51b..d6856fde9 100644
--- a/shared/src/i18n/sk/externalNotifications.ts
+++ b/shared/src/i18n/sk/externalNotifications.ts
@@ -102,6 +102,17 @@ const sk: NotificationLocale = {
? `„${p.tour}“ v „${p.trip}“ sa už vo wanderer nedá overiť. Túra vo vašej ceste zostáva, ako je.`
: `„${p.tour}“ v „${p.trip}“ sa vo wanderer možno zmenila. Otvorte túru a skontrolujte jej zdroj. V ceste sa nič nezmení samo.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Pridané z e-mailu: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} pridal(a) „${p.booking}“ do „${p.trip}“ z preposlaného e-mailu.`
+ : `„${p.booking}“ z vášho preposlaného e-mailu bola pridaná do „${p.trip}“. V TREK to môžete 7 dní vrátiť späť.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Preposlané rezervácie na kontrolu',
+ body: `Preposlané rezervácie čakajúce na vás v TREK: ${p.count}. Pri každej je uvedené, prečo nebola pridaná sama.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/sk/notif.ts b/shared/src/i18n/sk/notif.ts
index 2b3588c73..ea26723a9 100644
--- a/shared/src/i18n/sk/notif.ts
+++ b/shared/src/i18n/sk/notif.ts
@@ -56,6 +56,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'Zobraziť',
'notif.action.accept': 'Prijať',
'notif.action.decline': 'Odmietnuť',
+ 'notif.mail_booking_added.title': 'Rezervácia pridaná z e-mailu',
+ 'notif.mail_booking_added.text': '{booking} bola pridaná do {trip}',
+ 'notif.mail_booking_added.shared': '{actor} pridal(a) {booking} do {trip} z preposlaného e-mailu',
+ 'notif.mail_booking_pending.title': 'Preposlané rezervácie na kontrolu',
+ 'notif.mail_booking_pending.text': 'Preposlané rezervácie čakajúce na vás: {count}',
+ 'notif.action.undo': 'Vrátiť späť',
+ 'notif.action.keep': 'Ponechať',
+ 'notif.action.review': 'Skontrolovať',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Oznámenie',
diff --git a/shared/src/i18n/sv/externalNotifications.ts b/shared/src/i18n/sv/externalNotifications.ts
index 501aa4590..a54ff1858 100644
--- a/shared/src/i18n/sv/externalNotifications.ts
+++ b/shared/src/i18n/sv/externalNotifications.ts
@@ -96,6 +96,17 @@ const en: NotificationLocale = {
? `”${p.tour}” i ”${p.trip}” kan inte längre kontrolleras i wanderer. Turen i din resa förblir som den är.`
: `”${p.tour}” i ”${p.trip}” kan ha ändrats i wanderer. Öppna turen och kontrollera dess källa. Inget i resan ändras av sig självt.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Tillagd från ett mejl: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} lade till "${p.booking}" i "${p.trip}" från ett vidarebefordrat mejl.`
+ : `"${p.booking}" från ditt vidarebefordrade mejl lades till i "${p.trip}". Du kan ångra det i TREK i 7 dagar.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Vidarebefordrade bokningar att granska',
+ body: `Vidarebefordrade bokningar som väntar på dig i TREK: ${p.count}. Vid varje står varför den inte lades till av sig själv.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/sv/notif.ts b/shared/src/i18n/sv/notif.ts
index 385a1b6c4..acf51d6ce 100644
--- a/shared/src/i18n/sv/notif.ts
+++ b/shared/src/i18n/sv/notif.ts
@@ -55,6 +55,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'Visa',
'notif.action.accept': 'Godkänn',
'notif.action.decline': 'Neka',
+ 'notif.mail_booking_added.title': 'Bokning tillagd från ett mejl',
+ 'notif.mail_booking_added.text': '{booking} lades till i {trip}',
+ 'notif.mail_booking_added.shared': '{actor} lade till {booking} i {trip} från ett vidarebefordrat mejl',
+ 'notif.mail_booking_pending.title': 'Vidarebefordrade bokningar att granska',
+ 'notif.mail_booking_pending.text': 'Vidarebefordrade bokningar som väntar på dig: {count}',
+ 'notif.action.undo': 'Ångra',
+ 'notif.action.keep': 'Behåll',
+ 'notif.action.review': 'Granska',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Meddelande',
diff --git a/shared/src/i18n/th/externalNotifications.ts b/shared/src/i18n/th/externalNotifications.ts
index 175e94f9f..05b00eeeb 100644
--- a/shared/src/i18n/th/externalNotifications.ts
+++ b/shared/src/i18n/th/externalNotifications.ts
@@ -89,6 +89,17 @@ const th: NotificationLocale = {
? `"${p.tour}" ใน "${p.trip}" ตรวจใน wanderer ไม่ได้อีกต่อไป ทัวร์ในทริปของคุณยังคงเหมือนเดิม`
: `"${p.tour}" ใน "${p.trip}" อาจเปลี่ยนแปลงใน wanderer เปิดทัวร์และตรวจแหล่งที่มา ไม่มีสิ่งใดในทริปเปลี่ยนเอง`,
}),
+ mail_booking_added: (p) => ({
+ title: `เพิ่มจากอีเมล: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} เพิ่ม "${p.booking}" ลงใน "${p.trip}" จากอีเมลที่ส่งต่อ`
+ : `เพิ่ม "${p.booking}" จากอีเมลที่คุณส่งต่อลงใน "${p.trip}" แล้ว คุณเลิกทำได้ใน TREK ภายใน 7 วัน`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'การจองที่ส่งต่อซึ่งรอตรวจสอบ',
+ body: `การจองที่ส่งต่อซึ่งรอคุณอยู่ใน TREK: ${p.count} แต่ละรายการบอกเหตุผลที่ไม่ได้เพิ่มเองโดยอัตโนมัติ`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/th/notif.ts b/shared/src/i18n/th/notif.ts
index 1707e1def..79a676ad0 100644
--- a/shared/src/i18n/th/notif.ts
+++ b/shared/src/i18n/th/notif.ts
@@ -54,6 +54,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'ดู',
'notif.action.accept': 'ยอมรับ',
'notif.action.decline': 'ปฏิเสธ',
+ 'notif.mail_booking_added.title': 'เพิ่มการจองจากอีเมลแล้ว',
+ 'notif.mail_booking_added.text': 'เพิ่ม {booking} ลงใน {trip} แล้ว',
+ 'notif.mail_booking_added.shared': '{actor} เพิ่ม {booking} ลงใน {trip} จากอีเมลที่ส่งต่อ',
+ 'notif.mail_booking_pending.title': 'การจองที่ส่งต่อซึ่งรอตรวจสอบ',
+ 'notif.mail_booking_pending.text': 'การจองที่ส่งต่อซึ่งรอคุณอยู่: {count}',
+ 'notif.action.undo': 'เลิกทำ',
+ 'notif.action.keep': 'เก็บไว้',
+ 'notif.action.review': 'ตรวจสอบ',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'การแจ้งเตือน',
diff --git a/shared/src/i18n/tr/externalNotifications.ts b/shared/src/i18n/tr/externalNotifications.ts
index f389086c0..7baecd4d7 100644
--- a/shared/src/i18n/tr/externalNotifications.ts
+++ b/shared/src/i18n/tr/externalNotifications.ts
@@ -99,6 +99,17 @@ const tr: NotificationLocale = {
? `"${p.trip}" içindeki "${p.tour}" artık wanderer'da denetlenemiyor. Gezindeki tur olduğu gibi kalır.`
: `"${p.trip}" içindeki "${p.tour}" wanderer'da değişmiş olabilir. Turu aç ve kaynağını denetle. Gezide hiçbir şey kendiliğinden değişmez.`,
}),
+ mail_booking_added: (p) => ({
+ title: `E-postadan eklendi: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor}, iletilen bir e-postadaki "${p.booking}" rezervasyonunu "${p.trip}" seyahatine ekledi.`
+ : `İlettiğin e-postadaki "${p.booking}" rezervasyonu "${p.trip}" seyahatine eklendi. Bunu TREK içinde 7 gün boyunca geri alabilirsin.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'İncelenecek iletilen rezervasyonlar',
+ body: `TREK içinde seni bekleyen iletilen rezervasyonlar: ${p.count}. Her birinde neden kendiliğinden eklenmediği yazıyor.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/tr/notif.ts b/shared/src/i18n/tr/notif.ts
index 702da40ca..a7084cad4 100644
--- a/shared/src/i18n/tr/notif.ts
+++ b/shared/src/i18n/tr/notif.ts
@@ -55,6 +55,15 @@ const notif: TranslationStrings = {
'notif.action.view': 'Görüntüle',
'notif.action.accept': 'Kabul et',
'notif.action.decline': 'Reddet',
+ 'notif.mail_booking_added.title': 'E-postadan rezervasyon eklendi',
+ 'notif.mail_booking_added.text': '{booking}, {trip} seyahatine eklendi',
+ 'notif.mail_booking_added.shared':
+ '{actor}, iletilen bir e-postadan {booking} rezervasyonunu {trip} seyahatine ekledi',
+ 'notif.mail_booking_pending.title': 'İncelenecek iletilen rezervasyonlar',
+ 'notif.mail_booking_pending.text': 'Seni bekleyen iletilen rezervasyonlar: {count}',
+ 'notif.action.undo': 'Geri al',
+ 'notif.action.keep': 'Tut',
+ 'notif.action.review': 'İncele',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Bildirim',
diff --git a/shared/src/i18n/uk/externalNotifications.ts b/shared/src/i18n/uk/externalNotifications.ts
index a0923c280..0e03452dd 100644
--- a/shared/src/i18n/uk/externalNotifications.ts
+++ b/shared/src/i18n/uk/externalNotifications.ts
@@ -100,6 +100,17 @@ const uk: NotificationLocale = {
? `«${p.tour}» у «${p.trip}» більше не можна перевірити в wanderer. Тур у вашій подорожі залишається як є.`
: `«${p.tour}» у «${p.trip}», можливо, змінено в wanderer. Відкрийте тур і перевірте його джерело. У подорожі нічого не змінюється само.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Додано з листа: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} додав(ла) «${p.booking}» до «${p.trip}» з пересланого листа.`
+ : `«${p.booking}» з вашого пересланого листа додано до «${p.trip}». У TREK це можна скасувати протягом 7 днів.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Переслані бронювання для перевірки',
+ body: `Пересланих бронювань чекає на вас у TREK: ${p.count}. Біля кожного вказано, чому його не додано автоматично.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/uk/notif.ts b/shared/src/i18n/uk/notif.ts
index 05ef8175a..3500a0d68 100644
--- a/shared/src/i18n/uk/notif.ts
+++ b/shared/src/i18n/uk/notif.ts
@@ -57,6 +57,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'Відкрити',
'notif.action.accept': 'Прийняти',
'notif.action.decline': 'Відхилити',
+ 'notif.mail_booking_added.title': 'Бронювання додано з листа',
+ 'notif.mail_booking_added.text': '{booking} додано до {trip}',
+ 'notif.mail_booking_added.shared': '{actor} додав(ла) {booking} до {trip} з пересланого листа',
+ 'notif.mail_booking_pending.title': 'Переслані бронювання для перевірки',
+ 'notif.mail_booking_pending.text': 'Пересланих бронювань чекає на вас: {count}',
+ 'notif.action.undo': 'Скасувати',
+ 'notif.action.keep': 'Залишити',
+ 'notif.action.review': 'Перевірити',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Сповіщення',
diff --git a/shared/src/i18n/vi/externalNotifications.ts b/shared/src/i18n/vi/externalNotifications.ts
index 4ea51f358..98dafb6ba 100644
--- a/shared/src/i18n/vi/externalNotifications.ts
+++ b/shared/src/i18n/vi/externalNotifications.ts
@@ -89,6 +89,17 @@ const en: NotificationLocale = {
? `“${p.tour}” trong “${p.trip}” không còn kiểm tra được trên wanderer. Chuyến đi trong chuyến du lịch của bạn vẫn giữ nguyên.`
: `“${p.tour}” trong “${p.trip}” có thể đã thay đổi trên wanderer. Hãy mở chuyến đi và kiểm tra nguồn của nó. Không có gì trong chuyến du lịch tự thay đổi.`,
}),
+ mail_booking_added: (p) => ({
+ title: `Đã thêm từ email: ${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} đã thêm "${p.booking}" vào "${p.trip}" từ một email được chuyển tiếp.`
+ : `"${p.booking}" từ email bạn chuyển tiếp đã được thêm vào "${p.trip}". Bạn có thể hoàn tác trong TREK trong 7 ngày.`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: 'Đặt chỗ chuyển tiếp cần xem lại',
+ body: `Đặt chỗ chuyển tiếp đang chờ bạn trong TREK: ${p.count}. Mỗi mục cho biết vì sao nó không được tự động thêm.`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/vi/notif.ts b/shared/src/i18n/vi/notif.ts
index f5a2f7494..eba51a127 100644
--- a/shared/src/i18n/vi/notif.ts
+++ b/shared/src/i18n/vi/notif.ts
@@ -54,6 +54,14 @@ const notif: TranslationStrings = {
'notif.action.view': 'Xem',
'notif.action.accept': 'Chấp nhận',
'notif.action.decline': 'Sự suy sụp',
+ 'notif.mail_booking_added.title': 'Đã thêm đặt chỗ từ email',
+ 'notif.mail_booking_added.text': 'Đã thêm {booking} vào {trip}',
+ 'notif.mail_booking_added.shared': '{actor} đã thêm {booking} vào {trip} từ một email được chuyển tiếp',
+ 'notif.mail_booking_pending.title': 'Đặt chỗ chuyển tiếp cần xem lại',
+ 'notif.mail_booking_pending.text': 'Đặt chỗ chuyển tiếp đang chờ bạn: {count}',
+ 'notif.action.undo': 'Hoàn tác',
+ 'notif.action.keep': 'Giữ lại',
+ 'notif.action.review': 'Xem lại',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': 'Thông báo',
diff --git a/shared/src/i18n/zh-TW/externalNotifications.ts b/shared/src/i18n/zh-TW/externalNotifications.ts
index 9f917bd1c..6ec2850f9 100644
--- a/shared/src/i18n/zh-TW/externalNotifications.ts
+++ b/shared/src/i18n/zh-TW/externalNotifications.ts
@@ -90,6 +90,17 @@ const zhTW: NotificationLocale = {
? `「${p.trip}」中的「${p.tour}」已無法在 wanderer 中檢查。你旅行中的行程保持不變。`
: `「${p.trip}」中的「${p.tour}」可能已在 wanderer 中變更。請開啟行程並檢查其來源。旅行中的內容不會自行改變。`,
}),
+ mail_booking_added: (p) => ({
+ title: `從郵件新增:${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} 從轉寄的郵件將「${p.booking}」新增到「${p.trip}」。`
+ : `你轉寄的郵件中的「${p.booking}」已新增到「${p.trip}」。7 天內可以在 TREK 中復原。`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: '待檢查的轉寄預訂',
+ body: `TREK 中等待你處理的轉寄預訂:${p.count}。每一筆都說明了為什麼沒有自動新增。`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/zh-TW/notif.ts b/shared/src/i18n/zh-TW/notif.ts
index 9cbda8727..7cac12461 100644
--- a/shared/src/i18n/zh-TW/notif.ts
+++ b/shared/src/i18n/zh-TW/notif.ts
@@ -54,6 +54,14 @@ const notif: TranslationStrings = {
'notif.action.view': '查看',
'notif.action.accept': '接受',
'notif.action.decline': '拒絕',
+ 'notif.mail_booking_added.title': '已從郵件新增預訂',
+ 'notif.mail_booking_added.text': '{booking} 已新增到 {trip}',
+ 'notif.mail_booking_added.shared': '{actor} 從轉寄的郵件將 {booking} 新增到 {trip}',
+ 'notif.mail_booking_pending.title': '待檢查的轉寄預訂',
+ 'notif.mail_booking_pending.text': '等待你處理的轉寄預訂:{count}',
+ 'notif.action.undo': '復原',
+ 'notif.action.keep': '保留',
+ 'notif.action.review': '檢查',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': '通知',
diff --git a/shared/src/i18n/zh/externalNotifications.ts b/shared/src/i18n/zh/externalNotifications.ts
index 41262a4b0..d20e7e217 100644
--- a/shared/src/i18n/zh/externalNotifications.ts
+++ b/shared/src/i18n/zh/externalNotifications.ts
@@ -90,6 +90,17 @@ const zh: NotificationLocale = {
? `“${p.trip}”中的“${p.tour}”已无法在 wanderer 中检查。你旅行中的行程保持不变。`
: `“${p.trip}”中的“${p.tour}”可能已在 wanderer 中变化。请打开行程并检查其来源。旅行中的内容不会自行改变。`,
}),
+ mail_booking_added: (p) => ({
+ title: `从邮件添加:${p.booking}`,
+ body:
+ p.role === 'traveller'
+ ? `${p.actor} 从转发的邮件中将“${p.booking}”添加到“${p.trip}”。`
+ : `你转发的邮件中的“${p.booking}”已添加到“${p.trip}”。7 天内可以在 TREK 中撤销。`,
+ }),
+ mail_booking_pending: (p) => ({
+ title: '待查看的转发预订',
+ body: `TREK 中等待你处理的转发预订:${p.count}。每一条都说明了为什么没有自动添加。`,
+ }),
plugin_notification: (p) => ({ title: p.title ?? '', body: p.body ?? '' }),
},
passwordReset: {
diff --git a/shared/src/i18n/zh/notif.ts b/shared/src/i18n/zh/notif.ts
index 8f51f7e29..670fe1461 100644
--- a/shared/src/i18n/zh/notif.ts
+++ b/shared/src/i18n/zh/notif.ts
@@ -54,6 +54,14 @@ const notif: TranslationStrings = {
'notif.action.view': '查看',
'notif.action.accept': '接受',
'notif.action.decline': '拒绝',
+ 'notif.mail_booking_added.title': '已从邮件添加预订',
+ 'notif.mail_booking_added.text': '{booking} 已添加到 {trip}',
+ 'notif.mail_booking_added.shared': '{actor} 从转发的邮件中将 {booking} 添加到 {trip}',
+ 'notif.mail_booking_pending.title': '待查看的转发预订',
+ 'notif.mail_booking_pending.text': '等待你处理的转发预订:{count}',
+ 'notif.action.undo': '撤销',
+ 'notif.action.keep': '保留',
+ 'notif.action.review': '查看',
'notif.plugin.title': '{title}',
'notif.plugin.text': '{body}',
'notif.generic.title': '通知',