From ee9e7b61f59a427208386738057c8eff48fba599 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Fri, 16 Jun 2017 10:36:18 +0200 Subject: Create types for model enums --- server/lib/request/request-scheduler.ts | 3 ++- server/lib/request/request-video-event-scheduler.ts | 3 ++- server/lib/request/request-video-qadu-scheduler.ts | 3 ++- 3 files changed, 6 insertions(+), 3 deletions(-) (limited to 'server/lib/request') diff --git a/server/lib/request/request-scheduler.ts b/server/lib/request/request-scheduler.ts index 38c0cca3d..575e0227c 100644 --- a/server/lib/request/request-scheduler.ts +++ b/server/lib/request/request-scheduler.ts @@ -7,10 +7,11 @@ import { REQUESTS_LIMIT_PODS, REQUESTS_LIMIT_PER_POD } from '../../initializers' +import { RequestEndpoint } from '../../../shared' export type RequestSchedulerOptions = { type: string - endpoint: string + endpoint: RequestEndpoint data: Object toIds: number[] transaction: Sequelize.Transaction diff --git a/server/lib/request/request-video-event-scheduler.ts b/server/lib/request/request-video-event-scheduler.ts index c9d165117..4bb76f4c9 100644 --- a/server/lib/request/request-video-event-scheduler.ts +++ b/server/lib/request/request-video-event-scheduler.ts @@ -7,9 +7,10 @@ import { REQUESTS_VIDEO_EVENT_LIMIT_PER_POD, REQUEST_VIDEO_EVENT_ENDPOINT } from '../../initializers' +import { RequestVideoEventType } from '../../../shared' export type RequestVideoEventSchedulerOptions = { - type: string + type: RequestVideoEventType videoId: string count?: number transaction?: Sequelize.Transaction diff --git a/server/lib/request/request-video-qadu-scheduler.ts b/server/lib/request/request-video-qadu-scheduler.ts index 49970a2e6..d7169cc81 100644 --- a/server/lib/request/request-video-qadu-scheduler.ts +++ b/server/lib/request/request-video-qadu-scheduler.ts @@ -9,9 +9,10 @@ import { REQUEST_VIDEO_QADU_ENDPOINT, REQUEST_VIDEO_QADU_TYPES } from '../../initializers' +import { RequestVideoQaduType } from '../../../shared' export type RequestVideoQaduSchedulerOptions = { - type: string + type: RequestVideoQaduType videoId: string transaction?: Sequelize.Transaction } -- cgit v1.2.3