diff options
Diffstat (limited to 'shared/models/videos')
-rw-r--r-- | shared/models/videos/index.ts | 1 | ||||
-rw-r--r-- | shared/models/videos/video-abuse-state.model.ts | 5 | ||||
-rw-r--r-- | shared/models/videos/video-abuse-update.model.ts | 6 | ||||
-rw-r--r-- | shared/models/videos/video-abuse.model.ts | 7 |
4 files changed, 19 insertions, 0 deletions
diff --git a/shared/models/videos/index.ts b/shared/models/videos/index.ts index 17cf8be24..2d7de2a0d 100644 --- a/shared/models/videos/index.ts +++ b/shared/models/videos/index.ts | |||
@@ -1,6 +1,7 @@ | |||
1 | export * from './user-video-rate-update.model' | 1 | export * from './user-video-rate-update.model' |
2 | export * from './user-video-rate.model' | 2 | export * from './user-video-rate.model' |
3 | export * from './user-video-rate.type' | 3 | export * from './user-video-rate.type' |
4 | export * from './video-abuse-state.model' | ||
4 | export * from './video-abuse-create.model' | 5 | export * from './video-abuse-create.model' |
5 | export * from './video-abuse.model' | 6 | export * from './video-abuse.model' |
6 | export * from './video-blacklist.model' | 7 | export * from './video-blacklist.model' |
diff --git a/shared/models/videos/video-abuse-state.model.ts b/shared/models/videos/video-abuse-state.model.ts new file mode 100644 index 000000000..529f034bd --- /dev/null +++ b/shared/models/videos/video-abuse-state.model.ts | |||
@@ -0,0 +1,5 @@ | |||
1 | export enum VideoAbuseState { | ||
2 | PENDING = 1, | ||
3 | REJECTED = 2, | ||
4 | ACCEPTED = 3 | ||
5 | } | ||
diff --git a/shared/models/videos/video-abuse-update.model.ts b/shared/models/videos/video-abuse-update.model.ts new file mode 100644 index 000000000..9b32aae48 --- /dev/null +++ b/shared/models/videos/video-abuse-update.model.ts | |||
@@ -0,0 +1,6 @@ | |||
1 | import { VideoAbuseState } from './video-abuse-state.model' | ||
2 | |||
3 | export interface VideoAbuseUpdate { | ||
4 | moderationComment?: string | ||
5 | state?: VideoAbuseState | ||
6 | } | ||
diff --git a/shared/models/videos/video-abuse.model.ts b/shared/models/videos/video-abuse.model.ts index 51070a7a3..1fecce037 100644 --- a/shared/models/videos/video-abuse.model.ts +++ b/shared/models/videos/video-abuse.model.ts | |||
@@ -1,14 +1,21 @@ | |||
1 | import { Account } from '../actors' | 1 | import { Account } from '../actors' |
2 | import { VideoConstant } from './video-constant.model' | ||
3 | import { VideoAbuseState } from './video-abuse-state.model' | ||
2 | 4 | ||
3 | export interface VideoAbuse { | 5 | export interface VideoAbuse { |
4 | id: number | 6 | id: number |
5 | reason: string | 7 | reason: string |
6 | reporterAccount: Account | 8 | reporterAccount: Account |
9 | |||
10 | state: VideoConstant<VideoAbuseState> | ||
11 | moderationComment?: string | ||
12 | |||
7 | video: { | 13 | video: { |
8 | id: number | 14 | id: number |
9 | name: string | 15 | name: string |
10 | uuid: string | 16 | uuid: string |
11 | url: string | 17 | url: string |
12 | } | 18 | } |
19 | |||
13 | createdAt: Date | 20 | createdAt: Date |
14 | } | 21 | } |