node-event-bot/server/types/scheduledEventTypes.ts
2022-04-23 21:31:09 +02:00

11 lines
411 B
TypeScript

export interface RepetitonInfo {
startDate?: Date, // If defined will take precedence over repetitonAmount
endDate?: Date,// If defined will take precedence over repetitonAmount
totalAmount: number,
alreadyOccured: number,
schedule: supportedSchedule
}
export const scheduleNames = ['daily', 'weekly', 'monthly', 'everyTwoWeeks', 'everyNDays']
export type supportedSchedule = typeof scheduleNames[number]