diff options
Diffstat (limited to 'shared/models')
73 files changed, 292 insertions, 63 deletions
diff --git a/shared/models/activitypub/objects/index.ts b/shared/models/activitypub/objects/index.ts index a6a20e87a..9e2c6b728 100644 --- a/shared/models/activitypub/objects/index.ts +++ b/shared/models/activitypub/objects/index.ts | |||
@@ -2,5 +2,9 @@ export * from './abuse-object' | |||
2 | export * from './cache-file-object' | 2 | export * from './cache-file-object' |
3 | export * from './common-objects' | 3 | export * from './common-objects' |
4 | export * from './dislike-object' | 4 | export * from './dislike-object' |
5 | export * from './object.model' | ||
6 | export * from './playlist-element-object' | ||
7 | export * from './playlist-object' | ||
8 | export * from './video-comment-object' | ||
5 | export * from './video-torrent-object' | 9 | export * from './video-torrent-object' |
6 | export * from './view-object' | 10 | export * from './view-object' |
diff --git a/shared/models/actors/custom-page.model.ts b/shared/models/actors/custom-page.model.ts new file mode 100644 index 000000000..1e33584c1 --- /dev/null +++ b/shared/models/actors/custom-page.model.ts | |||
@@ -0,0 +1,3 @@ | |||
1 | export interface CustomPage { | ||
2 | content: string | ||
3 | } | ||
diff --git a/shared/models/actors/index.ts b/shared/models/actors/index.ts index 156f83248..e03f168cd 100644 --- a/shared/models/actors/index.ts +++ b/shared/models/actors/index.ts | |||
@@ -2,4 +2,5 @@ export * from './account.model' | |||
2 | export * from './actor-image.model' | 2 | export * from './actor-image.model' |
3 | export * from './actor-image.type' | 3 | export * from './actor-image.type' |
4 | export * from './actor.model' | 4 | export * from './actor.model' |
5 | export * from './custom-page.model' | ||
5 | export * from './follow.model' | 6 | export * from './follow.model' |
diff --git a/shared/models/common/index.ts b/shared/models/common/index.ts new file mode 100644 index 000000000..4db85eff2 --- /dev/null +++ b/shared/models/common/index.ts | |||
@@ -0,0 +1 @@ | |||
export * from './result-list.model' | |||
diff --git a/shared/models/result-list.model.ts b/shared/models/common/result-list.model.ts index fcafcfb2f..fcafcfb2f 100644 --- a/shared/models/result-list.model.ts +++ b/shared/models/common/result-list.model.ts | |||
diff --git a/shared/models/custom-markup/custom-markup-data.model.ts b/shared/models/custom-markup/custom-markup-data.model.ts new file mode 100644 index 000000000..8cbe3cfa4 --- /dev/null +++ b/shared/models/custom-markup/custom-markup-data.model.ts | |||
@@ -0,0 +1,54 @@ | |||
1 | export type EmbedMarkupData = { | ||
2 | // Video or playlist uuid | ||
3 | uuid: string | ||
4 | } | ||
5 | |||
6 | export type VideoMiniatureMarkupData = { | ||
7 | // Video uuid | ||
8 | uuid: string | ||
9 | |||
10 | onlyDisplayTitle?: string // boolean | ||
11 | } | ||
12 | |||
13 | export type PlaylistMiniatureMarkupData = { | ||
14 | // Playlist uuid | ||
15 | uuid: string | ||
16 | } | ||
17 | |||
18 | export type ChannelMiniatureMarkupData = { | ||
19 | // Channel name (username) | ||
20 | name: string | ||
21 | |||
22 | displayLatestVideo?: string // boolean | ||
23 | displayDescription?: string // boolean | ||
24 | } | ||
25 | |||
26 | export type VideosListMarkupData = { | ||
27 | onlyDisplayTitle?: string // boolean | ||
28 | maxRows?: string // number | ||
29 | |||
30 | sort?: string | ||
31 | count?: string // number | ||
32 | |||
33 | categoryOneOf?: string // coma separated values, number[] | ||
34 | languageOneOf?: string // coma separated values | ||
35 | |||
36 | channelHandle?: string | ||
37 | accountHandle?: string | ||
38 | |||
39 | onlyLocal?: string // boolean | ||
40 | } | ||
41 | |||
42 | export type ButtonMarkupData = { | ||
43 | theme: 'primary' | 'secondary' | ||
44 | href: string | ||
45 | label: string | ||
46 | blankTarget?: string // boolean | ||
47 | } | ||
48 | |||
49 | export type ContainerMarkupData = { | ||
50 | width?: string | ||
51 | title?: string | ||
52 | description?: string | ||
53 | layout?: 'row' | 'column' | ||
54 | } | ||
diff --git a/shared/models/custom-markup/index.ts b/shared/models/custom-markup/index.ts new file mode 100644 index 000000000..2898dfa90 --- /dev/null +++ b/shared/models/custom-markup/index.ts | |||
@@ -0,0 +1 @@ | |||
export * from './custom-markup-data.model' | |||
diff --git a/shared/models/index.ts b/shared/models/index.ts index dff5fdf0e..5c2bc480e 100644 --- a/shared/models/index.ts +++ b/shared/models/index.ts | |||
@@ -1,15 +1,16 @@ | |||
1 | export * from './activitypub' | 1 | export * from './activitypub' |
2 | export * from './actors' | 2 | export * from './actors' |
3 | export * from './moderation' | ||
4 | export * from './bulk' | 3 | export * from './bulk' |
5 | export * from './redundancy' | 4 | export * from './common' |
6 | export * from './users' | 5 | export * from './custom-markup' |
7 | export * from './videos' | ||
8 | export * from './feeds' | 6 | export * from './feeds' |
9 | export * from './joinpeertube' | 7 | export * from './joinpeertube' |
8 | export * from './moderation' | ||
10 | export * from './overviews' | 9 | export * from './overviews' |
11 | export * from './plugins' | 10 | export * from './plugins' |
11 | export * from './redundancy' | ||
12 | export * from './search' | 12 | export * from './search' |
13 | export * from './server' | 13 | export * from './server' |
14 | export * from './oauth-client-local.model' | 14 | export * from './tokens' |
15 | export * from './result-list.model' | 15 | export * from './users' |
16 | export * from './videos' | ||
diff --git a/shared/models/moderation/abuse/abuse-create.model.ts b/shared/models/moderation/abuse/abuse-create.model.ts index 0e7e9587f..7d35555c3 100644 --- a/shared/models/moderation/abuse/abuse-create.model.ts +++ b/shared/models/moderation/abuse/abuse-create.model.ts | |||
@@ -10,7 +10,7 @@ export interface AbuseCreate { | |||
10 | } | 10 | } |
11 | 11 | ||
12 | video?: { | 12 | video?: { |
13 | id: number | 13 | id: number | string |
14 | startAt?: number | 14 | startAt?: number |
15 | endAt?: number | 15 | endAt?: number |
16 | } | 16 | } |
diff --git a/shared/models/nodeinfo/index.ts b/shared/models/nodeinfo/index.ts new file mode 100644 index 000000000..faa64302a --- /dev/null +++ b/shared/models/nodeinfo/index.ts | |||
@@ -0,0 +1 @@ | |||
export * from './nodeinfo.model' | |||
diff --git a/shared/models/nodeinfo/index.d.ts b/shared/models/nodeinfo/nodeinfo.model.ts index 336cb66d2..336cb66d2 100644 --- a/shared/models/nodeinfo/index.d.ts +++ b/shared/models/nodeinfo/nodeinfo.model.ts | |||
diff --git a/shared/models/overviews/index.ts b/shared/models/overviews/index.ts index 376609efa..468507c6b 100644 --- a/shared/models/overviews/index.ts +++ b/shared/models/overviews/index.ts | |||
@@ -1 +1 @@ | |||
export * from './videos-overview' | export * from './videos-overview.model' | ||
diff --git a/shared/models/overviews/videos-overview.ts b/shared/models/overviews/videos-overview.model.ts index 0f3cb4a52..0f3cb4a52 100644 --- a/shared/models/overviews/videos-overview.ts +++ b/shared/models/overviews/videos-overview.model.ts | |||
diff --git a/shared/models/plugins/client-hook.model.ts b/shared/models/plugins/client/client-hook.model.ts index 620651051..cedd1be61 100644 --- a/shared/models/plugins/client-hook.model.ts +++ b/shared/models/plugins/client/client-hook.model.ts | |||
@@ -37,9 +37,12 @@ export const clientFilterHookObject = { | |||
37 | // Filter params/result of the function that fetch videos according to the user search | 37 | // Filter params/result of the function that fetch videos according to the user search |
38 | 'filter:api.search.videos.list.params': true, | 38 | 'filter:api.search.videos.list.params': true, |
39 | 'filter:api.search.videos.list.result': true, | 39 | 'filter:api.search.videos.list.result': true, |
40 | // Filter params/result of the function that fetch video-channels according to the user search | 40 | // Filter params/result of the function that fetch video channels according to the user search |
41 | 'filter:api.search.video-channels.list.params': true, | 41 | 'filter:api.search.video-channels.list.params': true, |
42 | 'filter:api.search.video-channels.list.result': true, | 42 | 'filter:api.search.video-channels.list.result': true, |
43 | // Filter params/result of the function that fetch video playlists according to the user search | ||
44 | 'filter:api.search.video-playlists.list.params': true, | ||
45 | 'filter:api.search.video-playlists.list.result': true, | ||
43 | 46 | ||
44 | // Filter form | 47 | // Filter form |
45 | 'filter:api.signup.registration.create.params': true, | 48 | 'filter:api.signup.registration.create.params': true, |
@@ -50,7 +53,13 @@ export const clientFilterHookObject = { | |||
50 | 53 | ||
51 | // Filter our SVG icons content | 54 | // Filter our SVG icons content |
52 | 'filter:internal.common.svg-icons.get-content.params': true, | 55 | 'filter:internal.common.svg-icons.get-content.params': true, |
53 | 'filter:internal.common.svg-icons.get-content.result': true | 56 | 'filter:internal.common.svg-icons.get-content.result': true, |
57 | |||
58 | // Filter left menu links | ||
59 | 'filter:left-menu.links.create.result': true, | ||
60 | |||
61 | // Filter videojs options built for PeerTube player | ||
62 | 'filter:internal.player.videojs.options.result': true | ||
54 | } | 63 | } |
55 | 64 | ||
56 | export type ClientFilterHookName = keyof typeof clientFilterHookObject | 65 | export type ClientFilterHookName = keyof typeof clientFilterHookObject |
diff --git a/shared/models/plugins/client/index.ts b/shared/models/plugins/client/index.ts new file mode 100644 index 000000000..6dfc6351f --- /dev/null +++ b/shared/models/plugins/client/index.ts | |||
@@ -0,0 +1,6 @@ | |||
1 | export * from './client-hook.model' | ||
2 | export * from './plugin-client-scope.type' | ||
3 | export * from './plugin-element-placeholder.type' | ||
4 | export * from './register-client-form-field.model' | ||
5 | export * from './register-client-hook.model' | ||
6 | export * from './register-client-settings-script.model' | ||
diff --git a/shared/models/plugins/plugin-client-scope.type.ts b/shared/models/plugins/client/plugin-client-scope.type.ts index 8cc234ff2..8cc234ff2 100644 --- a/shared/models/plugins/plugin-client-scope.type.ts +++ b/shared/models/plugins/client/plugin-client-scope.type.ts | |||
diff --git a/shared/models/plugins/plugin-element-placeholder.type.ts b/shared/models/plugins/client/plugin-element-placeholder.type.ts index 129099c62..129099c62 100644 --- a/shared/models/plugins/plugin-element-placeholder.type.ts +++ b/shared/models/plugins/client/plugin-element-placeholder.type.ts | |||
diff --git a/shared/models/plugins/register-client-form-field.model.ts b/shared/models/plugins/client/register-client-form-field.model.ts index 2df071337..2df071337 100644 --- a/shared/models/plugins/register-client-form-field.model.ts +++ b/shared/models/plugins/client/register-client-form-field.model.ts | |||
diff --git a/shared/models/plugins/register-client-hook.model.ts b/shared/models/plugins/client/register-client-hook.model.ts index 81047b21d..81047b21d 100644 --- a/shared/models/plugins/register-client-hook.model.ts +++ b/shared/models/plugins/client/register-client-hook.model.ts | |||
diff --git a/shared/models/plugins/register-client-settings-script.model.ts b/shared/models/plugins/client/register-client-settings-script.model.ts index ac16af366..481ceef96 100644 --- a/shared/models/plugins/register-client-settings-script.model.ts +++ b/shared/models/plugins/client/register-client-settings-script.model.ts | |||
@@ -1,4 +1,4 @@ | |||
1 | import { RegisterServerSettingOptions } from "./register-server-setting.model" | 1 | import { RegisterServerSettingOptions } from '../server' |
2 | 2 | ||
3 | export interface RegisterClientSettingsScript { | 3 | export interface RegisterClientSettingsScript { |
4 | isSettingHidden (options: { | 4 | isSettingHidden (options: { |
diff --git a/shared/models/plugins/index.ts b/shared/models/plugins/index.ts index 03b27f907..cbbe4916e 100644 --- a/shared/models/plugins/index.ts +++ b/shared/models/plugins/index.ts | |||
@@ -1,28 +1,6 @@ | |||
1 | export * from './client-hook.model' | 1 | export * from './client' |
2 | export * from './plugin-index' | ||
3 | export * from './server' | ||
2 | export * from './hook-type.enum' | 4 | export * from './hook-type.enum' |
3 | export * from './install-plugin.model' | ||
4 | export * from './manage-plugin.model' | ||
5 | export * from './peertube-plugin-index-list.model' | ||
6 | export * from './peertube-plugin-index.model' | ||
7 | export * from './peertube-plugin-latest-version.model' | ||
8 | export * from './peertube-plugin.model' | ||
9 | export * from './plugin-client-scope.type' | ||
10 | export * from './plugin-element-placeholder.type' | ||
11 | export * from './plugin-package-json.model' | 5 | export * from './plugin-package-json.model' |
12 | export * from './plugin-playlist-privacy-manager.model' | ||
13 | export * from './plugin-settings-manager.model' | ||
14 | export * from './plugin-storage-manager.model' | ||
15 | export * from './plugin-transcoding-manager.model' | ||
16 | export * from './plugin-translation.model' | ||
17 | export * from './plugin-video-category-manager.model' | ||
18 | export * from './plugin-video-language-manager.model' | ||
19 | export * from './plugin-video-licence-manager.model' | ||
20 | export * from './plugin-video-privacy-manager.model' | ||
21 | export * from './plugin.type' | 6 | export * from './plugin.type' |
22 | export * from './public-server.setting' | ||
23 | export * from './register-client-hook.model' | ||
24 | export * from './register-client-settings-script.model' | ||
25 | export * from './register-client-form-field.model' | ||
26 | export * from './register-server-hook.model' | ||
27 | export * from './register-server-setting.model' | ||
28 | export * from './server-hook.model' | ||
diff --git a/shared/models/plugins/plugin-index/index.ts b/shared/models/plugins/plugin-index/index.ts new file mode 100644 index 000000000..913846638 --- /dev/null +++ b/shared/models/plugins/plugin-index/index.ts | |||
@@ -0,0 +1,3 @@ | |||
1 | export * from './peertube-plugin-index-list.model' | ||
2 | export * from './peertube-plugin-index.model' | ||
3 | export * from './peertube-plugin-latest-version.model' | ||
diff --git a/shared/models/plugins/peertube-plugin-index-list.model.ts b/shared/models/plugins/plugin-index/peertube-plugin-index-list.model.ts index 817bac31e..ecb46482e 100644 --- a/shared/models/plugins/peertube-plugin-index-list.model.ts +++ b/shared/models/plugins/plugin-index/peertube-plugin-index-list.model.ts | |||
@@ -1,4 +1,4 @@ | |||
1 | import { PluginType } from './plugin.type' | 1 | import { PluginType } from '../plugin.type' |
2 | 2 | ||
3 | export interface PeertubePluginIndexList { | 3 | export interface PeertubePluginIndexList { |
4 | start: number | 4 | start: number |
diff --git a/shared/models/plugins/peertube-plugin-index.model.ts b/shared/models/plugins/plugin-index/peertube-plugin-index.model.ts index e91c8b4dc..e91c8b4dc 100644 --- a/shared/models/plugins/peertube-plugin-index.model.ts +++ b/shared/models/plugins/plugin-index/peertube-plugin-index.model.ts | |||
diff --git a/shared/models/plugins/peertube-plugin-latest-version.model.ts b/shared/models/plugins/plugin-index/peertube-plugin-latest-version.model.ts index 811a64429..811a64429 100644 --- a/shared/models/plugins/peertube-plugin-latest-version.model.ts +++ b/shared/models/plugins/plugin-index/peertube-plugin-latest-version.model.ts | |||
diff --git a/shared/models/plugins/plugin-package-json.model.ts b/shared/models/plugins/plugin-package-json.model.ts index c26e9ae5b..b2f92af80 100644 --- a/shared/models/plugins/plugin-package-json.model.ts +++ b/shared/models/plugins/plugin-package-json.model.ts | |||
@@ -1,4 +1,4 @@ | |||
1 | import { PluginClientScope } from './plugin-client-scope.type' | 1 | import { PluginClientScope } from './client/plugin-client-scope.type' |
2 | 2 | ||
3 | export type PluginTranslationPaths = { | 3 | export type PluginTranslationPaths = { |
4 | [ locale: string ]: string | 4 | [ locale: string ]: string |
diff --git a/shared/models/plugins/server/api/index.ts b/shared/models/plugins/server/api/index.ts new file mode 100644 index 000000000..eb59a03f0 --- /dev/null +++ b/shared/models/plugins/server/api/index.ts | |||
@@ -0,0 +1,3 @@ | |||
1 | export * from './install-plugin.model' | ||
2 | export * from './manage-plugin.model' | ||
3 | export * from './peertube-plugin.model' | ||
diff --git a/shared/models/plugins/install-plugin.model.ts b/shared/models/plugins/server/api/install-plugin.model.ts index 5a268ebe1..5a268ebe1 100644 --- a/shared/models/plugins/install-plugin.model.ts +++ b/shared/models/plugins/server/api/install-plugin.model.ts | |||
diff --git a/shared/models/plugins/manage-plugin.model.ts b/shared/models/plugins/server/api/manage-plugin.model.ts index 612b3056c..612b3056c 100644 --- a/shared/models/plugins/manage-plugin.model.ts +++ b/shared/models/plugins/server/api/manage-plugin.model.ts | |||
diff --git a/shared/models/plugins/peertube-plugin.model.ts b/shared/models/plugins/server/api/peertube-plugin.model.ts index 2b0bb8cfa..54c383f57 100644 --- a/shared/models/plugins/peertube-plugin.model.ts +++ b/shared/models/plugins/server/api/peertube-plugin.model.ts | |||
@@ -1,4 +1,4 @@ | |||
1 | import { PluginType } from './plugin.type' | 1 | import { PluginType } from '../../plugin.type' |
2 | 2 | ||
3 | export interface PeerTubePlugin { | 3 | export interface PeerTubePlugin { |
4 | name: string | 4 | name: string |
diff --git a/shared/models/plugins/server/index.ts b/shared/models/plugins/server/index.ts new file mode 100644 index 000000000..d3ff49d3b --- /dev/null +++ b/shared/models/plugins/server/index.ts | |||
@@ -0,0 +1,6 @@ | |||
1 | export * from './api' | ||
2 | export * from './managers' | ||
3 | export * from './settings' | ||
4 | export * from './plugin-translation.model' | ||
5 | export * from './register-server-hook.model' | ||
6 | export * from './server-hook.model' | ||
diff --git a/shared/models/plugins/server/managers/index.ts b/shared/models/plugins/server/managers/index.ts new file mode 100644 index 000000000..49365a854 --- /dev/null +++ b/shared/models/plugins/server/managers/index.ts | |||
@@ -0,0 +1,9 @@ | |||
1 | |||
2 | export * from './plugin-playlist-privacy-manager.model' | ||
3 | export * from './plugin-settings-manager.model' | ||
4 | export * from './plugin-storage-manager.model' | ||
5 | export * from './plugin-transcoding-manager.model' | ||
6 | export * from './plugin-video-category-manager.model' | ||
7 | export * from './plugin-video-language-manager.model' | ||
8 | export * from './plugin-video-licence-manager.model' | ||
9 | export * from './plugin-video-privacy-manager.model' | ||
diff --git a/shared/models/plugins/plugin-playlist-privacy-manager.model.ts b/shared/models/plugins/server/managers/plugin-playlist-privacy-manager.model.ts index d1823ef4e..4703c0a8b 100644 --- a/shared/models/plugins/plugin-playlist-privacy-manager.model.ts +++ b/shared/models/plugins/server/managers/plugin-playlist-privacy-manager.model.ts | |||
@@ -1,4 +1,4 @@ | |||
1 | import { VideoPlaylistPrivacy } from '../videos/playlist/video-playlist-privacy.model' | 1 | import { VideoPlaylistPrivacy } from '../../../videos/playlist/video-playlist-privacy.model' |
2 | 2 | ||
3 | export interface PluginPlaylistPrivacyManager { | 3 | export interface PluginPlaylistPrivacyManager { |
4 | // PUBLIC = 1, | 4 | // PUBLIC = 1, |
diff --git a/shared/models/plugins/plugin-settings-manager.model.ts b/shared/models/plugins/server/managers/plugin-settings-manager.model.ts index 3c28c0565..3c28c0565 100644 --- a/shared/models/plugins/plugin-settings-manager.model.ts +++ b/shared/models/plugins/server/managers/plugin-settings-manager.model.ts | |||
diff --git a/shared/models/plugins/plugin-storage-manager.model.ts b/shared/models/plugins/server/managers/plugin-storage-manager.model.ts index 51567044a..51567044a 100644 --- a/shared/models/plugins/plugin-storage-manager.model.ts +++ b/shared/models/plugins/server/managers/plugin-storage-manager.model.ts | |||
diff --git a/shared/models/plugins/plugin-transcoding-manager.model.ts b/shared/models/plugins/server/managers/plugin-transcoding-manager.model.ts index 8babccd4e..a0422a460 100644 --- a/shared/models/plugins/plugin-transcoding-manager.model.ts +++ b/shared/models/plugins/server/managers/plugin-transcoding-manager.model.ts | |||
@@ -1,4 +1,4 @@ | |||
1 | import { EncoderOptionsBuilder } from '../videos/video-transcoding.model' | 1 | import { EncoderOptionsBuilder } from '../../../videos/video-transcoding.model' |
2 | 2 | ||
3 | export interface PluginTranscodingManager { | 3 | export interface PluginTranscodingManager { |
4 | addLiveProfile (encoder: string, profile: string, builder: EncoderOptionsBuilder): boolean | 4 | addLiveProfile (encoder: string, profile: string, builder: EncoderOptionsBuilder): boolean |
diff --git a/shared/models/plugins/plugin-video-category-manager.model.ts b/shared/models/plugins/server/managers/plugin-video-category-manager.model.ts index 201bfa979..201bfa979 100644 --- a/shared/models/plugins/plugin-video-category-manager.model.ts +++ b/shared/models/plugins/server/managers/plugin-video-category-manager.model.ts | |||
diff --git a/shared/models/plugins/plugin-video-language-manager.model.ts b/shared/models/plugins/server/managers/plugin-video-language-manager.model.ts index 3fd577a79..3fd577a79 100644 --- a/shared/models/plugins/plugin-video-language-manager.model.ts +++ b/shared/models/plugins/server/managers/plugin-video-language-manager.model.ts | |||
diff --git a/shared/models/plugins/plugin-video-licence-manager.model.ts b/shared/models/plugins/server/managers/plugin-video-licence-manager.model.ts index 82a634d3a..82a634d3a 100644 --- a/shared/models/plugins/plugin-video-licence-manager.model.ts +++ b/shared/models/plugins/server/managers/plugin-video-licence-manager.model.ts | |||
diff --git a/shared/models/plugins/plugin-video-privacy-manager.model.ts b/shared/models/plugins/server/managers/plugin-video-privacy-manager.model.ts index 3ada99608..7717115e3 100644 --- a/shared/models/plugins/plugin-video-privacy-manager.model.ts +++ b/shared/models/plugins/server/managers/plugin-video-privacy-manager.model.ts | |||
@@ -1,4 +1,4 @@ | |||
1 | import { VideoPrivacy } from '../videos/video-privacy.enum' | 1 | import { VideoPrivacy } from '../../../videos/video-privacy.enum' |
2 | 2 | ||
3 | export interface PluginVideoPrivacyManager { | 3 | export interface PluginVideoPrivacyManager { |
4 | // PUBLIC = 1 | 4 | // PUBLIC = 1 |
diff --git a/shared/models/plugins/plugin-translation.model.ts b/shared/models/plugins/server/plugin-translation.model.ts index a2dd8e560..a2dd8e560 100644 --- a/shared/models/plugins/plugin-translation.model.ts +++ b/shared/models/plugins/server/plugin-translation.model.ts | |||
diff --git a/shared/models/plugins/register-server-hook.model.ts b/shared/models/plugins/server/register-server-hook.model.ts index 746fdc329..746fdc329 100644 --- a/shared/models/plugins/register-server-hook.model.ts +++ b/shared/models/plugins/server/register-server-hook.model.ts | |||
diff --git a/shared/models/plugins/server-hook.model.ts b/shared/models/plugins/server/server-hook.model.ts index 88277af5a..5f29534b5 100644 --- a/shared/models/plugins/server-hook.model.ts +++ b/shared/models/plugins/server/server-hook.model.ts | |||
@@ -27,6 +27,10 @@ export const serverFilterHookObject = { | |||
27 | 'filter:api.search.video-channels.local.list.result': true, | 27 | 'filter:api.search.video-channels.local.list.result': true, |
28 | 'filter:api.search.video-channels.index.list.params': true, | 28 | 'filter:api.search.video-channels.index.list.params': true, |
29 | 'filter:api.search.video-channels.index.list.result': true, | 29 | 'filter:api.search.video-channels.index.list.result': true, |
30 | 'filter:api.search.video-playlists.local.list.params': true, | ||
31 | 'filter:api.search.video-playlists.local.list.result': true, | ||
32 | 'filter:api.search.video-playlists.index.list.params': true, | ||
33 | 'filter:api.search.video-playlists.index.list.result': true, | ||
30 | 34 | ||
31 | // Filter the result of the get function | 35 | // Filter the result of the get function |
32 | // Used to get detailed video information (video watch page for example) | 36 | // Used to get detailed video information (video watch page for example) |
@@ -110,7 +114,10 @@ export const serverActionHookObject = { | |||
110 | 'action:api.user.updated': true, | 114 | 'action:api.user.updated': true, |
111 | 115 | ||
112 | // Fired when a user got a new oauth2 token | 116 | // Fired when a user got a new oauth2 token |
113 | 'action:api.user.oauth2-got-token': true | 117 | 'action:api.user.oauth2-got-token': true, |
118 | |||
119 | // Fired when a video is added to a playlist | ||
120 | 'action:api.video-playlist-element.created': true | ||
114 | } | 121 | } |
115 | 122 | ||
116 | export type ServerActionHookName = keyof typeof serverActionHookObject | 123 | export type ServerActionHookName = keyof typeof serverActionHookObject |
diff --git a/shared/models/plugins/server/settings/index.ts b/shared/models/plugins/server/settings/index.ts new file mode 100644 index 000000000..b456de019 --- /dev/null +++ b/shared/models/plugins/server/settings/index.ts | |||
@@ -0,0 +1,2 @@ | |||
1 | export * from './public-server.setting' | ||
2 | export * from './register-server-setting.model' | ||
diff --git a/shared/models/plugins/public-server.setting.ts b/shared/models/plugins/server/settings/public-server.setting.ts index 9802c4d7d..9802c4d7d 100644 --- a/shared/models/plugins/public-server.setting.ts +++ b/shared/models/plugins/server/settings/public-server.setting.ts | |||
diff --git a/shared/models/plugins/register-server-setting.model.ts b/shared/models/plugins/server/settings/register-server-setting.model.ts index 9f45c3c37..d9a798cac 100644 --- a/shared/models/plugins/register-server-setting.model.ts +++ b/shared/models/plugins/server/settings/register-server-setting.model.ts | |||
@@ -1,4 +1,4 @@ | |||
1 | import { RegisterClientFormFieldOptions } from './register-client-form-field.model' | 1 | import { RegisterClientFormFieldOptions } from '../../client' |
2 | 2 | ||
3 | export type RegisterServerSettingOptions = RegisterClientFormFieldOptions & { | 3 | export type RegisterServerSettingOptions = RegisterClientFormFieldOptions & { |
4 | // If the setting is not private, anyone can view its value (client code included) | 4 | // If the setting is not private, anyone can view its value (client code included) |
diff --git a/shared/models/redundancy/index.ts b/shared/models/redundancy/index.ts index 649cc489f..641a5d625 100644 --- a/shared/models/redundancy/index.ts +++ b/shared/models/redundancy/index.ts | |||
@@ -1,3 +1,4 @@ | |||
1 | export * from './videos-redundancy-strategy.model' | ||
2 | export * from './video-redundancies-filters.model' | 1 | export * from './video-redundancies-filters.model' |
2 | export * from './video-redundancy-config-filter.type' | ||
3 | export * from './video-redundancy.model' | 3 | export * from './video-redundancy.model' |
4 | export * from './videos-redundancy-strategy.model' | ||
diff --git a/shared/models/search/index.ts b/shared/models/search/index.ts index 697ceccb1..50aeeddc8 100644 --- a/shared/models/search/index.ts +++ b/shared/models/search/index.ts | |||
@@ -1,5 +1,6 @@ | |||
1 | export * from './boolean-both-query.model' | 1 | export * from './boolean-both-query.model' |
2 | export * from './search-target-query.model' | 2 | export * from './search-target-query.model' |
3 | export * from './videos-common-query.model' | 3 | export * from './videos-common-query.model' |
4 | export * from './videos-search-query.model' | ||
5 | export * from './video-channels-search-query.model' | 4 | export * from './video-channels-search-query.model' |
5 | export * from './video-playlists-search-query.model' | ||
6 | export * from './videos-search-query.model' | ||
diff --git a/shared/models/search/video-channels-search-query.model.ts b/shared/models/search/video-channels-search-query.model.ts index c96aa8c1d..8f93c4bd5 100644 --- a/shared/models/search/video-channels-search-query.model.ts +++ b/shared/models/search/video-channels-search-query.model.ts | |||
@@ -1,4 +1,4 @@ | |||
1 | import { SearchTargetQuery } from "./search-target-query.model" | 1 | import { SearchTargetQuery } from './search-target-query.model' |
2 | 2 | ||
3 | export interface VideoChannelsSearchQuery extends SearchTargetQuery { | 3 | export interface VideoChannelsSearchQuery extends SearchTargetQuery { |
4 | search: string | 4 | search: string |
diff --git a/shared/models/search/video-playlists-search-query.model.ts b/shared/models/search/video-playlists-search-query.model.ts new file mode 100644 index 000000000..31f05218e --- /dev/null +++ b/shared/models/search/video-playlists-search-query.model.ts | |||
@@ -0,0 +1,9 @@ | |||
1 | import { SearchTargetQuery } from './search-target-query.model' | ||
2 | |||
3 | export interface VideoPlaylistsSearchQuery extends SearchTargetQuery { | ||
4 | search: string | ||
5 | |||
6 | start?: number | ||
7 | count?: number | ||
8 | sort?: string | ||
9 | } | ||
diff --git a/shared/models/server/custom-config.model.ts b/shared/models/server/custom-config.model.ts index 0bccd63e3..75d04423a 100644 --- a/shared/models/server/custom-config.model.ts +++ b/shared/models/server/custom-config.model.ts | |||
@@ -69,6 +69,7 @@ export interface CustomConfig { | |||
69 | enabled: boolean | 69 | enabled: boolean |
70 | limit: number | 70 | limit: number |
71 | requiresEmailVerification: boolean | 71 | requiresEmailVerification: boolean |
72 | minimumAge: number | ||
72 | } | 73 | } |
73 | 74 | ||
74 | admin: { | 75 | admin: { |
diff --git a/shared/models/server/index.ts b/shared/models/server/index.ts index b5163954a..06bf5c599 100644 --- a/shared/models/server/index.ts +++ b/shared/models/server/index.ts | |||
@@ -6,6 +6,7 @@ export * from './debug.model' | |||
6 | export * from './emailer.model' | 6 | export * from './emailer.model' |
7 | export * from './job.model' | 7 | export * from './job.model' |
8 | export * from './log-level.type' | 8 | export * from './log-level.type' |
9 | export * from './peertube-problem-document.model' | ||
9 | export * from './server-config.model' | 10 | export * from './server-config.model' |
10 | export * from './server-debug.model' | 11 | export * from './server-debug.model' |
11 | export * from './server-error-code.enum' | 12 | export * from './server-error-code.enum' |
diff --git a/shared/models/server/job.model.ts b/shared/models/server/job.model.ts index e4acfee8d..4ab249e0b 100644 --- a/shared/models/server/job.model.ts +++ b/shared/models/server/job.model.ts | |||
@@ -53,7 +53,6 @@ export type ActivitypubHttpFetcherPayload = { | |||
53 | uri: string | 53 | uri: string |
54 | type: FetchType | 54 | type: FetchType |
55 | videoId?: number | 55 | videoId?: number |
56 | accountId?: number | ||
57 | } | 56 | } |
58 | 57 | ||
59 | export type ActivitypubHttpUnicastPayload = { | 58 | export type ActivitypubHttpUnicastPayload = { |
diff --git a/shared/models/server/peertube-problem-document.model.ts b/shared/models/server/peertube-problem-document.model.ts new file mode 100644 index 000000000..e391d5aad --- /dev/null +++ b/shared/models/server/peertube-problem-document.model.ts | |||
@@ -0,0 +1,32 @@ | |||
1 | import { HttpStatusCode } from '../../core-utils' | ||
2 | import { OAuth2ErrorCode, ServerErrorCode } from './server-error-code.enum' | ||
3 | |||
4 | export interface PeerTubeProblemDocumentData { | ||
5 | 'invalid-params'?: Record<string, Object> | ||
6 | |||
7 | originUrl?: string | ||
8 | |||
9 | keyId?: string | ||
10 | |||
11 | targetUrl?: string | ||
12 | |||
13 | actorUrl?: string | ||
14 | |||
15 | // Feeds | ||
16 | format?: string | ||
17 | url?: string | ||
18 | } | ||
19 | |||
20 | export interface PeerTubeProblemDocument extends PeerTubeProblemDocumentData { | ||
21 | type: string | ||
22 | title: string | ||
23 | |||
24 | detail: string | ||
25 | // Compat PeerTube <= 3.2 | ||
26 | error: string | ||
27 | |||
28 | status: HttpStatusCode | ||
29 | |||
30 | docs?: string | ||
31 | code?: ServerErrorCode | OAuth2ErrorCode | ||
32 | } | ||
diff --git a/shared/models/server/server-config.model.ts b/shared/models/server/server-config.model.ts index 85d84af44..585e99aca 100644 --- a/shared/models/server/server-config.model.ts +++ b/shared/models/server/server-config.model.ts | |||
@@ -84,6 +84,7 @@ export interface ServerConfig { | |||
84 | allowed: boolean | 84 | allowed: boolean |
85 | allowedForCurrentIP: boolean | 85 | allowedForCurrentIP: boolean |
86 | requiresEmailVerification: boolean | 86 | requiresEmailVerification: boolean |
87 | minimumAge: number | ||
87 | } | 88 | } |
88 | 89 | ||
89 | transcoding: { | 90 | transcoding: { |
@@ -214,4 +215,10 @@ export interface ServerConfig { | |||
214 | level: BroadcastMessageLevel | 215 | level: BroadcastMessageLevel |
215 | dismissable: boolean | 216 | dismissable: boolean |
216 | } | 217 | } |
218 | |||
219 | homepage: { | ||
220 | enabled: boolean | ||
221 | } | ||
217 | } | 222 | } |
223 | |||
224 | export type HTMLServerConfig = Omit<ServerConfig, 'signup'> | ||
diff --git a/shared/models/server/server-error-code.enum.ts b/shared/models/server/server-error-code.enum.ts index c02b0e6c7..115421d4d 100644 --- a/shared/models/server/server-error-code.enum.ts +++ b/shared/models/server/server-error-code.enum.ts | |||
@@ -1,5 +1,72 @@ | |||
1 | export const enum ServerErrorCode { | 1 | export const enum ServerErrorCode { |
2 | DOES_NOT_RESPECT_FOLLOW_CONSTRAINTS = 1, | 2 | /** |
3 | MAX_INSTANCE_LIVES_LIMIT_REACHED = 2, | 3 | * The simplest form of payload too large: when the file size is over the |
4 | MAX_USER_LIVES_LIMIT_REACHED = 3, | 4 | * global file size limit |
5 | */ | ||
6 | MAX_FILE_SIZE_REACHED = 'max_file_size_reached', | ||
7 | |||
8 | /** | ||
9 | * The payload is too large for the user quota set | ||
10 | */ | ||
11 | QUOTA_REACHED = 'quota_reached', | ||
12 | |||
13 | /** | ||
14 | * Error yielded upon trying to access a video that is not federated, nor can | ||
15 | * be. This may be due to: remote videos on instances that are not followed by | ||
16 | * yours, and with your instance disallowing unknown instances being accessed. | ||
17 | */ | ||
18 | DOES_NOT_RESPECT_FOLLOW_CONSTRAINTS = 'does_not_respect_follow_constraints', | ||
19 | |||
20 | LIVE_NOT_ENABLED = 'live_not_enabled', | ||
21 | LIVE_NOT_ALLOWING_REPLAY = 'live_not_allowing_replay', | ||
22 | LIVE_CONFLICTING_PERMANENT_AND_SAVE_REPLAY = 'live_conflicting_permanent_and_save_replay', | ||
23 | /** | ||
24 | * Pretty self-explanatory: the set maximum number of simultaneous lives was | ||
25 | * reached, and this error is typically there to inform the user trying to | ||
26 | * broadcast one. | ||
27 | */ | ||
28 | MAX_INSTANCE_LIVES_LIMIT_REACHED = 'max_instance_lives_limit_reached', | ||
29 | /** | ||
30 | * Pretty self-explanatory: the set maximum number of simultaneous lives FOR | ||
31 | * THIS USER was reached, and this error is typically there to inform the user | ||
32 | * trying to broadcast one. | ||
33 | */ | ||
34 | MAX_USER_LIVES_LIMIT_REACHED = 'max_user_lives_limit_reached', | ||
35 | |||
36 | /** | ||
37 | * A torrent should have at most one correct video file. Any more and we will | ||
38 | * not be able to choose automatically. | ||
39 | */ | ||
40 | INCORRECT_FILES_IN_TORRENT = 'incorrect_files_in_torrent' | ||
41 | } | ||
42 | |||
43 | /** | ||
44 | * oauthjs/oauth2-server error codes | ||
45 | * @see https://datatracker.ietf.org/doc/html/rfc6749#section-5.2 | ||
46 | **/ | ||
47 | export const enum OAuth2ErrorCode { | ||
48 | /** | ||
49 | * The provided authorization grant (e.g., authorization code, resource owner | ||
50 | * credentials) or refresh token is invalid, expired, revoked, does not match | ||
51 | * the redirection URI used in the authorization request, or was issued to | ||
52 | * another client. | ||
53 | * | ||
54 | * @see https://github.com/oauthjs/node-oauth2-server/blob/master/lib/errors/invalid-grant-error.js | ||
55 | */ | ||
56 | INVALID_GRANT = 'invalid_grant', | ||
57 | |||
58 | /** | ||
59 | * Client authentication failed (e.g., unknown client, no client authentication | ||
60 | * included, or unsupported authentication method). | ||
61 | * | ||
62 | * @see https://github.com/oauthjs/node-oauth2-server/blob/master/lib/errors/invalid-client-error.js | ||
63 | */ | ||
64 | INVALID_CLIENT = 'invalid_client', | ||
65 | |||
66 | /** | ||
67 | * The access token provided is expired, revoked, malformed, or invalid for other reasons | ||
68 | * | ||
69 | * @see https://github.com/oauthjs/node-oauth2-server/blob/master/lib/errors/invalid-token-error.js | ||
70 | */ | ||
71 | INVALID_TOKEN = 'invalid_token', | ||
5 | } | 72 | } |
diff --git a/shared/models/tokens/index.ts b/shared/models/tokens/index.ts new file mode 100644 index 000000000..fe130f153 --- /dev/null +++ b/shared/models/tokens/index.ts | |||
@@ -0,0 +1 @@ | |||
export * from './oauth-client-local.model' | |||
diff --git a/shared/models/oauth-client-local.model.ts b/shared/models/tokens/oauth-client-local.model.ts index 0c6ce6c5d..0c6ce6c5d 100644 --- a/shared/models/oauth-client-local.model.ts +++ b/shared/models/tokens/oauth-client-local.model.ts | |||
diff --git a/shared/models/users/user-right.enum.ts b/shared/models/users/user-right.enum.ts index bbedc9f00..950b22bad 100644 --- a/shared/models/users/user-right.enum.ts +++ b/shared/models/users/user-right.enum.ts | |||
@@ -16,6 +16,7 @@ export const enum UserRight { | |||
16 | MANAGE_JOBS, | 16 | MANAGE_JOBS, |
17 | 17 | ||
18 | MANAGE_CONFIGURATION, | 18 | MANAGE_CONFIGURATION, |
19 | MANAGE_INSTANCE_CUSTOM_PAGE, | ||
19 | 20 | ||
20 | MANAGE_ACCOUNTS_BLOCKLIST, | 21 | MANAGE_ACCOUNTS_BLOCKLIST, |
21 | MANAGE_SERVERS_BLOCKLIST, | 22 | MANAGE_SERVERS_BLOCKLIST, |
diff --git a/shared/models/videos/change-ownership/index.ts b/shared/models/videos/change-ownership/index.ts new file mode 100644 index 000000000..a942fb2cd --- /dev/null +++ b/shared/models/videos/change-ownership/index.ts | |||
@@ -0,0 +1,3 @@ | |||
1 | export * from './video-change-ownership-accept.model' | ||
2 | export * from './video-change-ownership-create.model' | ||
3 | export * from './video-change-ownership.model' | ||
diff --git a/shared/models/videos/video-change-ownership-accept.model.ts b/shared/models/videos/change-ownership/video-change-ownership-accept.model.ts index f27247633..f27247633 100644 --- a/shared/models/videos/video-change-ownership-accept.model.ts +++ b/shared/models/videos/change-ownership/video-change-ownership-accept.model.ts | |||
diff --git a/shared/models/videos/video-change-ownership-create.model.ts b/shared/models/videos/change-ownership/video-change-ownership-create.model.ts index 40fcca285..40fcca285 100644 --- a/shared/models/videos/video-change-ownership-create.model.ts +++ b/shared/models/videos/change-ownership/video-change-ownership-create.model.ts | |||
diff --git a/shared/models/videos/video-change-ownership.model.ts b/shared/models/videos/change-ownership/video-change-ownership.model.ts index 669c7f3e7..3d31cad0a 100644 --- a/shared/models/videos/video-change-ownership.model.ts +++ b/shared/models/videos/change-ownership/video-change-ownership.model.ts | |||
@@ -1,5 +1,5 @@ | |||
1 | import { Account } from '../actors' | 1 | import { Account } from '../../actors' |
2 | import { Video } from './video.model' | 2 | import { Video } from '../video.model' |
3 | 3 | ||
4 | export interface VideoChangeOwnership { | 4 | export interface VideoChangeOwnership { |
5 | id: number | 5 | id: number |
diff --git a/shared/models/videos/comment/index.ts b/shared/models/videos/comment/index.ts new file mode 100644 index 000000000..7b9261a36 --- /dev/null +++ b/shared/models/videos/comment/index.ts | |||
@@ -0,0 +1 @@ | |||
export * from './video-comment.model' | |||
diff --git a/shared/models/videos/video-comment.model.ts b/shared/models/videos/comment/video-comment.model.ts index 9730a3f76..79c0e4c0a 100644 --- a/shared/models/videos/video-comment.model.ts +++ b/shared/models/videos/comment/video-comment.model.ts | |||
@@ -1,4 +1,4 @@ | |||
1 | import { Account } from '../actors' | 1 | import { Account } from '../../actors' |
2 | 2 | ||
3 | export interface VideoComment { | 3 | export interface VideoComment { |
4 | id: number | 4 | id: number |
diff --git a/shared/models/videos/index.ts b/shared/models/videos/index.ts index fac3e0b2f..faa9b9868 100644 --- a/shared/models/videos/index.ts +++ b/shared/models/videos/index.ts | |||
@@ -1,6 +1,8 @@ | |||
1 | export * from './blacklist' | 1 | export * from './blacklist' |
2 | export * from './caption' | 2 | export * from './caption' |
3 | export * from './change-ownership' | ||
3 | export * from './channel' | 4 | export * from './channel' |
5 | export * from './comment' | ||
4 | export * from './live' | 6 | export * from './live' |
5 | export * from './import' | 7 | export * from './import' |
6 | export * from './playlist' | 8 | export * from './playlist' |
@@ -10,17 +12,11 @@ export * from './nsfw-policy.type' | |||
10 | 12 | ||
11 | export * from './thumbnail.type' | 13 | export * from './thumbnail.type' |
12 | 14 | ||
13 | export * from './video-change-ownership-accept.model' | ||
14 | export * from './video-change-ownership-create.model' | ||
15 | export * from './video-change-ownership.model' | ||
16 | |||
17 | export * from './video-comment.model' | ||
18 | export * from './video-constant.model' | 15 | export * from './video-constant.model' |
19 | export * from './video-create.model' | 16 | export * from './video-create.model' |
20 | export * from './video-file-metadata' | ||
21 | export * from './video-file.model' | ||
22 | 17 | ||
23 | export * from './live/live-video.model' | 18 | export * from './video-file-metadata.model' |
19 | export * from './video-file.model' | ||
24 | 20 | ||
25 | export * from './video-privacy.enum' | 21 | export * from './video-privacy.enum' |
26 | export * from './video-query.type' | 22 | export * from './video-query.type' |
@@ -39,3 +35,4 @@ export * from './video-transcoding-fps.model' | |||
39 | 35 | ||
40 | export * from './video-update.model' | 36 | export * from './video-update.model' |
41 | export * from './video.model' | 37 | export * from './video.model' |
38 | export * from './video-create-result.model' | ||
diff --git a/shared/models/videos/playlist/index.ts b/shared/models/videos/playlist/index.ts index 99f7e9bab..f11a4bd28 100644 --- a/shared/models/videos/playlist/index.ts +++ b/shared/models/videos/playlist/index.ts | |||
@@ -1,4 +1,5 @@ | |||
1 | export * from './video-exist-in-playlist.model' | 1 | export * from './video-exist-in-playlist.model' |
2 | export * from './video-playlist-create-result.model' | ||
2 | export * from './video-playlist-create.model' | 3 | export * from './video-playlist-create.model' |
3 | export * from './video-playlist-element-create.model' | 4 | export * from './video-playlist-element-create.model' |
4 | export * from './video-playlist-element-update.model' | 5 | export * from './video-playlist-element-update.model' |
diff --git a/shared/models/videos/playlist/video-playlist-create-result.model.ts b/shared/models/videos/playlist/video-playlist-create-result.model.ts new file mode 100644 index 000000000..cd9b170ae --- /dev/null +++ b/shared/models/videos/playlist/video-playlist-create-result.model.ts | |||
@@ -0,0 +1,5 @@ | |||
1 | export interface VideoPlaylistCreateResult { | ||
2 | id: number | ||
3 | uuid: string | ||
4 | shortUUID: string | ||
5 | } | ||
diff --git a/shared/models/videos/playlist/video-playlist.model.ts b/shared/models/videos/playlist/video-playlist.model.ts index f45d0ff88..b8a9955d9 100644 --- a/shared/models/videos/playlist/video-playlist.model.ts +++ b/shared/models/videos/playlist/video-playlist.model.ts | |||
@@ -6,19 +6,25 @@ import { VideoPlaylistType } from './video-playlist-type.model' | |||
6 | export interface VideoPlaylist { | 6 | export interface VideoPlaylist { |
7 | id: number | 7 | id: number |
8 | uuid: string | 8 | uuid: string |
9 | shortUUID: string | ||
10 | |||
9 | isLocal: boolean | 11 | isLocal: boolean |
10 | 12 | ||
13 | url: string | ||
14 | |||
11 | displayName: string | 15 | displayName: string |
12 | description: string | 16 | description: string |
13 | privacy: VideoConstant<VideoPlaylistPrivacy> | 17 | privacy: VideoConstant<VideoPlaylistPrivacy> |
14 | 18 | ||
15 | thumbnailPath: string | 19 | thumbnailPath: string |
20 | thumbnailUrl?: string | ||
16 | 21 | ||
17 | videosLength: number | 22 | videosLength: number |
18 | 23 | ||
19 | type: VideoConstant<VideoPlaylistType> | 24 | type: VideoConstant<VideoPlaylistType> |
20 | 25 | ||
21 | embedPath: string | 26 | embedPath: string |
27 | embedUrl?: string | ||
22 | 28 | ||
23 | createdAt: Date | string | 29 | createdAt: Date | string |
24 | updatedAt: Date | string | 30 | updatedAt: Date | string |
diff --git a/shared/models/videos/video-create-result.model.ts b/shared/models/videos/video-create-result.model.ts new file mode 100644 index 000000000..a9f8e25a0 --- /dev/null +++ b/shared/models/videos/video-create-result.model.ts | |||
@@ -0,0 +1,5 @@ | |||
1 | export interface VideoCreateResult { | ||
2 | id: number | ||
3 | uuid: string | ||
4 | shortUUID: string | ||
5 | } | ||
diff --git a/shared/models/videos/video-file-metadata.ts b/shared/models/videos/video-file-metadata.model.ts index 8f527c0a7..8f527c0a7 100644 --- a/shared/models/videos/video-file-metadata.ts +++ b/shared/models/videos/video-file-metadata.model.ts | |||
diff --git a/shared/models/videos/video-file.model.ts b/shared/models/videos/video-file.model.ts index 1e830b19c..28fce0aaf 100644 --- a/shared/models/videos/video-file.model.ts +++ b/shared/models/videos/video-file.model.ts | |||
@@ -1,5 +1,5 @@ | |||
1 | import { VideoConstant } from './video-constant.model' | 1 | import { VideoConstant } from './video-constant.model' |
2 | import { VideoFileMetadata } from './video-file-metadata' | 2 | import { VideoFileMetadata } from './video-file-metadata.model' |
3 | import { VideoResolution } from './video-resolution.enum' | 3 | import { VideoResolution } from './video-resolution.enum' |
4 | 4 | ||
5 | export interface VideoFile { | 5 | export interface VideoFile { |
diff --git a/shared/models/videos/video.model.ts b/shared/models/videos/video.model.ts index caefeff82..0e3e89f43 100644 --- a/shared/models/videos/video.model.ts +++ b/shared/models/videos/video.model.ts | |||
@@ -10,6 +10,8 @@ import { VideoStreamingPlaylist } from './video-streaming-playlist.model' | |||
10 | export interface Video { | 10 | export interface Video { |
11 | id: number | 11 | id: number |
12 | uuid: string | 12 | uuid: string |
13 | shortUUID: string | ||
14 | |||
13 | createdAt: Date | string | 15 | createdAt: Date | string |
14 | updatedAt: Date | string | 16 | updatedAt: Date | string |
15 | publishedAt: Date | string | 17 | publishedAt: Date | string |