aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared/models/videos
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2018-08-13 16:57:13 +0200
committerChocobozzz <me@florianbigard.com>2018-08-14 09:27:18 +0200
commit26b7305a232e547709f433a6edf700bf495935d8 (patch)
treeb5676090c61df72f864735bcc881d5ee256cffbd /shared/models/videos
parentefc9e8450a8bbeeef9cd18e3ad6037abc0f815c3 (diff)
downloadPeerTube-26b7305a232e547709f433a6edf700bf495935d8.tar.gz
PeerTube-26b7305a232e547709f433a6edf700bf495935d8.tar.zst
PeerTube-26b7305a232e547709f433a6edf700bf495935d8.zip
Add blacklist reason field
Diffstat (limited to 'shared/models/videos')
-rw-r--r--shared/models/videos/index.ts2
-rw-r--r--shared/models/videos/video-blacklist-create.model.ts3
-rw-r--r--shared/models/videos/video-blacklist-update.model.ts3
-rw-r--r--shared/models/videos/video-blacklist.model.ts22
-rw-r--r--shared/models/videos/video.model.ts3
5 files changed, 24 insertions, 9 deletions
diff --git a/shared/models/videos/index.ts b/shared/models/videos/index.ts
index 02bf2b842..b99dd2d8f 100644
--- a/shared/models/videos/index.ts
+++ b/shared/models/videos/index.ts
@@ -6,6 +6,8 @@ export * from './video-abuse-create.model'
6export * from './video-abuse.model' 6export * from './video-abuse.model'
7export * from './video-abuse-update.model' 7export * from './video-abuse-update.model'
8export * from './video-blacklist.model' 8export * from './video-blacklist.model'
9export * from './video-blacklist-create.model'
10export * from './video-blacklist-update.model'
9export * from './video-channel-create.model' 11export * from './video-channel-create.model'
10export * from './video-channel-update.model' 12export * from './video-channel-update.model'
11export * from './video-channel.model' 13export * from './video-channel.model'
diff --git a/shared/models/videos/video-blacklist-create.model.ts b/shared/models/videos/video-blacklist-create.model.ts
new file mode 100644
index 000000000..89c69cb56
--- /dev/null
+++ b/shared/models/videos/video-blacklist-create.model.ts
@@ -0,0 +1,3 @@
1export interface VideoBlacklistCreate {
2 reason?: string
3}
diff --git a/shared/models/videos/video-blacklist-update.model.ts b/shared/models/videos/video-blacklist-update.model.ts
new file mode 100644
index 000000000..0a86cf7b0
--- /dev/null
+++ b/shared/models/videos/video-blacklist-update.model.ts
@@ -0,0 +1,3 @@
1export interface VideoBlacklistUpdate {
2 reason?: string
3}
diff --git a/shared/models/videos/video-blacklist.model.ts b/shared/models/videos/video-blacklist.model.ts
index af04502e8..a060da357 100644
--- a/shared/models/videos/video-blacklist.model.ts
+++ b/shared/models/videos/video-blacklist.model.ts
@@ -1,14 +1,18 @@
1export interface BlacklistedVideo { 1export interface BlacklistedVideo {
2 id: number 2 id: number
3 videoId: number
4 createdAt: Date 3 createdAt: Date
5 updatedAt: Date 4 updatedAt: Date
6 name: string 5 reason?: string
7 uuid: string 6
8 description: string 7 video: {
9 duration: number 8 id: number
10 views: number 9 name: string
11 likes: number 10 uuid: string
12 dislikes: number 11 description: string
13 nsfw: boolean 12 duration: number
13 views: number
14 likes: number
15 dislikes: number
16 nsfw: boolean
17 }
14} 18}
diff --git a/shared/models/videos/video.model.ts b/shared/models/videos/video.model.ts
index f7bbaac76..8dfa96069 100644
--- a/shared/models/videos/video.model.ts
+++ b/shared/models/videos/video.model.ts
@@ -43,6 +43,9 @@ export interface Video {
43 state?: VideoConstant<VideoState> 43 state?: VideoConstant<VideoState>
44 scheduledUpdate?: VideoScheduleUpdate 44 scheduledUpdate?: VideoScheduleUpdate
45 45
46 blacklisted?: boolean
47 blacklistedReason?: string
48
46 account: { 49 account: {
47 id: number 50 id: number
48 uuid: string 51 uuid: string