mirror of
https://github.com/tomru/pfadi-bussle.git
synced 2026-03-04 23:17:12 +01:00
fix ts-ignore necessity
This commit is contained in:
@@ -39,7 +39,7 @@ Buchungs-Link: ${getBaseURL()}/booking/${booking.uuid}
|
|||||||
}
|
}
|
||||||
|
|
||||||
export function generateBookedCalendar(bookings: Booking[]): string {
|
export function generateBookedCalendar(bookings: Booking[]): string {
|
||||||
const events = bookings.map((booking) => ({
|
const events = bookings.map((booking): { productId: string; calName: string; start: [number, number, number]; startOutputType: 'local' | 'utc'; duration: { days: number }; title: string; description: string; status: EventStatus } => ({
|
||||||
productId: 'app.vercel.pfadi-bussle/ics',
|
productId: 'app.vercel.pfadi-bussle/ics',
|
||||||
calName: 'Pfadi-Bussle Buchungen',
|
calName: 'Pfadi-Bussle Buchungen',
|
||||||
start: convertDay(booking.days[0]),
|
start: convertDay(booking.days[0]),
|
||||||
@@ -60,8 +60,6 @@ Link: ${getBaseURL()}/admin/booking/${booking.uuid}
|
|||||||
: ('TENTATIVE' as EventStatus),
|
: ('TENTATIVE' as EventStatus),
|
||||||
}))
|
}))
|
||||||
|
|
||||||
// FIXME: startOutputType does not like 'local'
|
|
||||||
// @ts-ignore
|
|
||||||
const { error, value } = createEvents(events)
|
const { error, value } = createEvents(events)
|
||||||
|
|
||||||
if (error) {
|
if (error) {
|
||||||
|
|||||||
Reference in New Issue
Block a user