aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/models/video/video-abuse-interface.ts
diff options
context:
space:
mode:
Diffstat (limited to 'server/models/video/video-abuse-interface.ts')
-rw-r--r--server/models/video/video-abuse-interface.ts28
1 files changed, 28 insertions, 0 deletions
diff --git a/server/models/video/video-abuse-interface.ts b/server/models/video/video-abuse-interface.ts
new file mode 100644
index 000000000..4b7f2a2ec
--- /dev/null
+++ b/server/models/video/video-abuse-interface.ts
@@ -0,0 +1,28 @@
1import * as Sequelize from 'sequelize'
2
3// Don't use barrel, import just what we need
4import { VideoAbuse as FormatedVideoAbuse } from '../../../shared/models/video-abuse.model'
5
6export namespace VideoAbuseMethods {
7 export type toFormatedJSON = () => FormatedVideoAbuse
8
9 export type ListForApiCallback = (err: Error, videoAbuseInstances?: VideoAbuseInstance[], total?: number) => void
10 export type ListForApi = (start: number, count: number, sort: string, callback: ListForApiCallback) => void
11}
12
13export interface VideoAbuseClass {
14 listForApi: VideoAbuseMethods.ListForApi
15}
16
17export interface VideoAbuseAttributes {
18 reporterUsername: string
19 reason: string
20}
21
22export interface VideoAbuseInstance extends VideoAbuseClass, VideoAbuseAttributes, Sequelize.Instance<VideoAbuseAttributes> {
23 id: number
24 createdAt: Date
25 updatedAt: Date
26}
27
28export interface VideoAbuseModel extends VideoAbuseClass, Sequelize.Model<VideoAbuseInstance, VideoAbuseAttributes> {}