diff options
author | Chocobozzz <florian.bigard@gmail.com> | 2017-12-11 11:06:32 +0100 |
---|---|---|
committer | Chocobozzz <florian.bigard@gmail.com> | 2017-12-11 11:06:32 +0100 |
commit | fada8d75550dc7365f7e18ee1569b9406251d660 (patch) | |
tree | db9dc01c18693824f83fce5020f4c1f3ae7c0865 /shared | |
parent | 492fd28167f770d79a430fc57451b5a9e075d8e7 (diff) | |
parent | c2830fa8f84f61462098bf36add824f89436dfa9 (diff) | |
download | PeerTube-fada8d75550dc7365f7e18ee1569b9406251d660.tar.gz PeerTube-fada8d75550dc7365f7e18ee1569b9406251d660.tar.zst PeerTube-fada8d75550dc7365f7e18ee1569b9406251d660.zip |
Merge branch 'feature/design' into develop
Diffstat (limited to 'shared')
-rw-r--r-- | shared/models/accounts/account.model.ts | 8 | ||||
-rw-r--r-- | shared/models/avatars/avatar.model.ts | 5 | ||||
-rw-r--r-- | shared/models/users/user.model.ts | 8 | ||||
-rw-r--r-- | shared/models/videos/video-create.model.ts | 10 | ||||
-rw-r--r-- | shared/models/videos/video.model.ts | 4 |
5 files changed, 24 insertions, 11 deletions
diff --git a/shared/models/accounts/account.model.ts b/shared/models/accounts/account.model.ts index 338426dc7..d14701317 100644 --- a/shared/models/accounts/account.model.ts +++ b/shared/models/accounts/account.model.ts | |||
@@ -1,5 +1,13 @@ | |||
1 | import { Avatar } from '../avatars/avatar.model' | ||
2 | |||
1 | export interface Account { | 3 | export interface Account { |
2 | id: number | 4 | id: number |
5 | uuid: string | ||
3 | name: string | 6 | name: string |
4 | host: string | 7 | host: string |
8 | followingCount: number | ||
9 | followersCount: number | ||
10 | createdAt: Date | ||
11 | updatedAt: Date | ||
12 | avatar: Avatar | ||
5 | } | 13 | } |
diff --git a/shared/models/avatars/avatar.model.ts b/shared/models/avatars/avatar.model.ts new file mode 100644 index 000000000..301d00929 --- /dev/null +++ b/shared/models/avatars/avatar.model.ts | |||
@@ -0,0 +1,5 @@ | |||
1 | export interface Avatar { | ||
2 | path: string | ||
3 | createdAt: Date | string | ||
4 | updatedAt: Date | string | ||
5 | } | ||
diff --git a/shared/models/users/user.model.ts b/shared/models/users/user.model.ts index a8012734c..4b17881e5 100644 --- a/shared/models/users/user.model.ts +++ b/shared/models/users/user.model.ts | |||
@@ -1,3 +1,4 @@ | |||
1 | import { Account } from '../accounts' | ||
1 | import { VideoChannel } from '../videos/video-channel.model' | 2 | import { VideoChannel } from '../videos/video-channel.model' |
2 | import { UserRole } from './user-role' | 3 | import { UserRole } from './user-role' |
3 | 4 | ||
@@ -8,10 +9,7 @@ export interface User { | |||
8 | displayNSFW: boolean | 9 | displayNSFW: boolean |
9 | role: UserRole | 10 | role: UserRole |
10 | videoQuota: number | 11 | videoQuota: number |
11 | createdAt: Date, | 12 | createdAt: Date |
12 | account: { | 13 | account: Account |
13 | id: number | ||
14 | uuid: string | ||
15 | } | ||
16 | videoChannels?: VideoChannel[] | 14 | videoChannels?: VideoChannel[] |
17 | } | 15 | } |
diff --git a/shared/models/videos/video-create.model.ts b/shared/models/videos/video-create.model.ts index e537c38a8..8bc6a6639 100644 --- a/shared/models/videos/video-create.model.ts +++ b/shared/models/videos/video-create.model.ts | |||
@@ -1,13 +1,13 @@ | |||
1 | import { VideoPrivacy } from './video-privacy.enum' | 1 | import { VideoPrivacy } from './video-privacy.enum' |
2 | 2 | ||
3 | export interface VideoCreate { | 3 | export interface VideoCreate { |
4 | category: number | 4 | category?: number |
5 | licence: number | 5 | licence?: number |
6 | language: number | 6 | language?: number |
7 | description: string | 7 | description?: string |
8 | channelId: number | 8 | channelId: number |
9 | nsfw: boolean | 9 | nsfw: boolean |
10 | name: string | 10 | name: string |
11 | tags: string[] | 11 | tags?: string[] |
12 | privacy: VideoPrivacy | 12 | privacy: VideoPrivacy |
13 | } | 13 | } |
diff --git a/shared/models/videos/video.model.ts b/shared/models/videos/video.model.ts index 08b29425c..dc12a05d9 100644 --- a/shared/models/videos/video.model.ts +++ b/shared/models/videos/video.model.ts | |||
@@ -1,3 +1,4 @@ | |||
1 | import { Account } from '../accounts' | ||
1 | import { VideoChannel } from './video-channel.model' | 2 | import { VideoChannel } from './video-channel.model' |
2 | import { VideoPrivacy } from './video-privacy.enum' | 3 | import { VideoPrivacy } from './video-privacy.enum' |
3 | 4 | ||
@@ -13,7 +14,7 @@ export interface VideoFile { | |||
13 | export interface Video { | 14 | export interface Video { |
14 | id: number | 15 | id: number |
15 | uuid: string | 16 | uuid: string |
16 | account: string | 17 | accountName: string |
17 | createdAt: Date | string | 18 | createdAt: Date | string |
18 | updatedAt: Date | string | 19 | updatedAt: Date | string |
19 | categoryLabel: string | 20 | categoryLabel: string |
@@ -43,4 +44,5 @@ export interface VideoDetails extends Video { | |||
43 | descriptionPath: string | 44 | descriptionPath: string |
44 | channel: VideoChannel | 45 | channel: VideoChannel |
45 | files: VideoFile[] | 46 | files: VideoFile[] |
47 | account: Account | ||
46 | } | 48 | } |