diff options
Diffstat (limited to 'client/src')
3 files changed, 44 insertions, 10 deletions
diff --git a/client/src/app/+admin/overview/videos/video-admin.service.ts b/client/src/app/+admin/overview/videos/video-admin.service.ts index d0854a2dc..b90fe22d8 100644 --- a/client/src/app/+admin/overview/videos/video-admin.service.ts +++ b/client/src/app/+admin/overview/videos/video-admin.service.ts | |||
@@ -45,11 +45,33 @@ export class VideoAdminService { | |||
45 | children: [ | 45 | children: [ |
46 | { | 46 | { |
47 | queryParams: { search: 'isLive:false' }, | 47 | queryParams: { search: 'isLive:false' }, |
48 | label: $localize`VOD videos` | 48 | label: $localize`VOD` |
49 | }, | 49 | }, |
50 | { | 50 | { |
51 | queryParams: { search: 'isLive:true' }, | 51 | queryParams: { search: 'isLive:true' }, |
52 | label: $localize`Live videos` | 52 | label: $localize`Live` |
53 | } | ||
54 | ] | ||
55 | }, | ||
56 | |||
57 | { | ||
58 | title: $localize`Video files`, | ||
59 | children: [ | ||
60 | { | ||
61 | queryParams: { search: 'webtorrent:true' }, | ||
62 | label: $localize`With WebTorrent` | ||
63 | }, | ||
64 | { | ||
65 | queryParams: { search: 'webtorrent:false' }, | ||
66 | label: $localize`Without WebTorrent` | ||
67 | }, | ||
68 | { | ||
69 | queryParams: { search: 'hls:true' }, | ||
70 | label: $localize`With HLS` | ||
71 | }, | ||
72 | { | ||
73 | queryParams: { search: 'hls:false' }, | ||
74 | label: $localize`Without HLS` | ||
53 | } | 75 | } |
54 | ] | 76 | ] |
55 | }, | 77 | }, |
@@ -69,7 +91,7 @@ export class VideoAdminService { | |||
69 | }, | 91 | }, |
70 | 92 | ||
71 | { | 93 | { |
72 | title: $localize`Include/Exclude`, | 94 | title: $localize`Exclude`, |
73 | children: [ | 95 | children: [ |
74 | { | 96 | { |
75 | queryParams: { search: 'excludeMuted' }, | 97 | queryParams: { search: 'excludeMuted' }, |
@@ -94,6 +116,14 @@ export class VideoAdminService { | |||
94 | prefix: 'isLocal:', | 116 | prefix: 'isLocal:', |
95 | isBoolean: true | 117 | isBoolean: true |
96 | }, | 118 | }, |
119 | hasHLSFiles: { | ||
120 | prefix: 'hls:', | ||
121 | isBoolean: true | ||
122 | }, | ||
123 | hasWebtorrentFiles: { | ||
124 | prefix: 'webtorrent:', | ||
125 | isBoolean: true | ||
126 | }, | ||
97 | isLive: { | 127 | isLive: { |
98 | prefix: 'isLive:', | 128 | prefix: 'isLive:', |
99 | isBoolean: true | 129 | isBoolean: true |
diff --git a/client/src/app/+admin/overview/videos/video-list.component.html b/client/src/app/+admin/overview/videos/video-list.component.html index 67b554aaf..134f64632 100644 --- a/client/src/app/+admin/overview/videos/video-list.component.html +++ b/client/src/app/+admin/overview/videos/video-list.component.html | |||
@@ -66,11 +66,11 @@ | |||
66 | </td> | 66 | </td> |
67 | 67 | ||
68 | <td> | 68 | <td> |
69 | <span [ngClass]="getPrivacyBadgeClass(video.privacy.id)" class="badge">{{ video.privacy.label }}</span> | 69 | <span [ngClass]="getPrivacyBadgeClass(video)" class="badge">{{ video.privacy.label }}</span> |
70 | 70 | ||
71 | <span *ngIf="video.nsfw" class="badge badge-red" i18n>NSFW</span> | 71 | <span *ngIf="video.nsfw" class="badge badge-red" i18n>NSFW</span> |
72 | 72 | ||
73 | <span *ngIf="isUnpublished(video.state.id)" class="badge badge-yellow" i18n>{{ video.state.label }}</span> | 73 | <span *ngIf="isUnpublished(video)" class="badge badge-yellow" i18n>{{ video.state.label }}</span> |
74 | 74 | ||
75 | <span *ngIf="isAccountBlocked(video)" class="badge badge-red" i18n>Account muted</span> | 75 | <span *ngIf="isAccountBlocked(video)" class="badge badge-red" i18n>Account muted</span> |
76 | <span *ngIf="isServerBlocked(video)" class="badge badge-red" i18n>Server muted</span> | 76 | <span *ngIf="isServerBlocked(video)" class="badge badge-red" i18n>Server muted</span> |
@@ -83,7 +83,7 @@ | |||
83 | <span *ngIf="isWebTorrent(video)" class="badge badge-blue">WebTorrent</span> | 83 | <span *ngIf="isWebTorrent(video)" class="badge badge-blue">WebTorrent</span> |
84 | <span *ngIf="video.isLive" class="badge badge-blue">Live</span> | 84 | <span *ngIf="video.isLive" class="badge badge-blue">Live</span> |
85 | 85 | ||
86 | <span *ngIf="!video.isLive && video.isLocal">{{ getFilesSize(video) | bytes: 1 }}</span> | 86 | <span *ngIf="!isImport(video) && !video.isLive && video.isLocal">{{ getFilesSize(video) | bytes: 1 }}</span> |
87 | </td> | 87 | </td> |
88 | 88 | ||
89 | <td> | 89 | <td> |
diff --git a/client/src/app/+admin/overview/videos/video-list.component.ts b/client/src/app/+admin/overview/videos/video-list.component.ts index 8a15e8426..635552cf5 100644 --- a/client/src/app/+admin/overview/videos/video-list.component.ts +++ b/client/src/app/+admin/overview/videos/video-list.component.ts | |||
@@ -85,14 +85,14 @@ export class VideoListComponent extends RestTable implements OnInit { | |||
85 | this.reloadData() | 85 | this.reloadData() |
86 | } | 86 | } |
87 | 87 | ||
88 | getPrivacyBadgeClass (privacy: VideoPrivacy) { | 88 | getPrivacyBadgeClass (video: Video) { |
89 | if (privacy === VideoPrivacy.PUBLIC) return 'badge-blue' | 89 | if (video.privacy.id === VideoPrivacy.PUBLIC) return 'badge-blue' |
90 | 90 | ||
91 | return 'badge-yellow' | 91 | return 'badge-yellow' |
92 | } | 92 | } |
93 | 93 | ||
94 | isUnpublished (state: VideoState) { | 94 | isUnpublished (video: Video) { |
95 | return state !== VideoState.LIVE_ENDED && state !== VideoState.PUBLISHED | 95 | return video.state.id !== VideoState.LIVE_ENDED && video.state.id !== VideoState.PUBLISHED |
96 | } | 96 | } |
97 | 97 | ||
98 | isAccountBlocked (video: Video) { | 98 | isAccountBlocked (video: Video) { |
@@ -107,6 +107,10 @@ export class VideoListComponent extends RestTable implements OnInit { | |||
107 | return video.blacklisted | 107 | return video.blacklisted |
108 | } | 108 | } |
109 | 109 | ||
110 | isImport (video: Video) { | ||
111 | return video.state.id === VideoState.TO_IMPORT | ||
112 | } | ||
113 | |||
110 | isHLS (video: Video) { | 114 | isHLS (video: Video) { |
111 | const p = video.streamingPlaylists.find(p => p.type === VideoStreamingPlaylistType.HLS) | 115 | const p = video.streamingPlaylists.find(p => p.type === VideoStreamingPlaylistType.HLS) |
112 | if (!p) return false | 116 | if (!p) return false |