aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app
diff options
context:
space:
mode:
Diffstat (limited to 'client/src/app')
-rw-r--r--client/src/app/+my-library/my-videos/my-videos.component.html1
-rw-r--r--client/src/app/+my-library/my-videos/my-videos.component.ts6
-rw-r--r--client/src/app/shared/shared-video-miniature/videos-selection.component.html1
-rw-r--r--client/src/app/shared/shared-video-miniature/videos-selection.component.ts3
4 files changed, 9 insertions, 2 deletions
diff --git a/client/src/app/+my-library/my-videos/my-videos.component.html b/client/src/app/+my-library/my-videos/my-videos.component.html
index 977f7b03b..5fa4c02ec 100644
--- a/client/src/app/+my-library/my-videos/my-videos.component.html
+++ b/client/src/app/+my-library/my-videos/my-videos.component.html
@@ -35,6 +35,7 @@
35 [titlePage]="titlePage" 35 [titlePage]="titlePage"
36 [getVideosObservableFunction]="getVideosObservableFunction" 36 [getVideosObservableFunction]="getVideosObservableFunction"
37 [ownerDisplayType]="ownerDisplayType" 37 [ownerDisplayType]="ownerDisplayType"
38 [user]="user"
38 #videosSelection 39 #videosSelection
39> 40>
40 <ng-template ptTemplate="globalButtons"> 41 <ng-template ptTemplate="globalButtons">
diff --git a/client/src/app/+my-library/my-videos/my-videos.component.ts b/client/src/app/+my-library/my-videos/my-videos.component.ts
index e89bb12e1..6a2a62608 100644
--- a/client/src/app/+my-library/my-videos/my-videos.component.ts
+++ b/client/src/app/+my-library/my-videos/my-videos.component.ts
@@ -2,7 +2,7 @@ import { concat, Observable, Subject } from 'rxjs'
2import { debounceTime, tap, toArray } from 'rxjs/operators' 2import { debounceTime, tap, toArray } from 'rxjs/operators'
3import { Component, OnInit, ViewChild } from '@angular/core' 3import { Component, OnInit, ViewChild } from '@angular/core'
4import { ActivatedRoute, Router } from '@angular/router' 4import { ActivatedRoute, Router } from '@angular/router'
5import { AuthService, ComponentPagination, ConfirmService, Notifier, ScreenService, ServerService } from '@app/core' 5import { AuthService, ComponentPagination, ConfirmService, Notifier, ScreenService, ServerService, User, UserService } from '@app/core'
6import { DisableForReuseHook } from '@app/core/routing/disable-for-reuse-hook' 6import { DisableForReuseHook } from '@app/core/routing/disable-for-reuse-hook'
7import { immutableAssign } from '@app/helpers' 7import { immutableAssign } from '@app/helpers'
8import { DropdownAction, Video, VideoService } from '@app/shared/shared-main' 8import { DropdownAction, Video, VideoService } from '@app/shared/shared-main'
@@ -45,6 +45,8 @@ export class MyVideosComponent implements OnInit, DisableForReuseHook {
45 videosSearchChanged = new Subject<string>() 45 videosSearchChanged = new Subject<string>()
46 getVideosObservableFunction = this.getVideosObservable.bind(this) 46 getVideosObservableFunction = this.getVideosObservable.bind(this)
47 47
48 user: User
49
48 constructor ( 50 constructor (
49 protected router: Router, 51 protected router: Router,
50 protected serverService: ServerService, 52 protected serverService: ServerService,
@@ -61,6 +63,8 @@ export class MyVideosComponent implements OnInit, DisableForReuseHook {
61 ngOnInit () { 63 ngOnInit () {
62 this.buildActions() 64 this.buildActions()
63 65
66 this.user = this.authService.getUser()
67
64 this.videosSearchChanged 68 this.videosSearchChanged
65 .pipe(debounceTime(500)) 69 .pipe(debounceTime(500))
66 .subscribe(() => { 70 .subscribe(() => {
diff --git a/client/src/app/shared/shared-video-miniature/videos-selection.component.html b/client/src/app/shared/shared-video-miniature/videos-selection.component.html
index 5f5593512..8caeaf092 100644
--- a/client/src/app/shared/shared-video-miniature/videos-selection.component.html
+++ b/client/src/app/shared/shared-video-miniature/videos-selection.component.html
@@ -10,6 +10,7 @@
10 <my-video-miniature 10 <my-video-miniature
11 [video]="video" [displayAsRow]="true" [displayOptions]="miniatureDisplayOptions" 11 [video]="video" [displayAsRow]="true" [displayOptions]="miniatureDisplayOptions"
12 [displayVideoActions]="false" [ownerDisplayType]="ownerDisplayType" 12 [displayVideoActions]="false" [ownerDisplayType]="ownerDisplayType"
13 [user]="user"
13 ></my-video-miniature> 14 ></my-video-miniature>
14 15
15 <!-- Display only once --> 16 <!-- Display only once -->
diff --git a/client/src/app/shared/shared-video-miniature/videos-selection.component.ts b/client/src/app/shared/shared-video-miniature/videos-selection.component.ts
index ef59975d4..ca1cf2264 100644
--- a/client/src/app/shared/shared-video-miniature/videos-selection.component.ts
+++ b/client/src/app/shared/shared-video-miniature/videos-selection.component.ts
@@ -13,7 +13,7 @@ import {
13 TemplateRef 13 TemplateRef
14} from '@angular/core' 14} from '@angular/core'
15import { ActivatedRoute, Router } from '@angular/router' 15import { ActivatedRoute, Router } from '@angular/router'
16import { AuthService, ComponentPagination, LocalStorageService, Notifier, ScreenService, ServerService, UserService } from '@app/core' 16import { AuthService, ComponentPagination, LocalStorageService, Notifier, ScreenService, ServerService, User, UserService } from '@app/core'
17import { ResultList, VideoSortField } from '@shared/models' 17import { ResultList, VideoSortField } from '@shared/models'
18import { PeerTubeTemplateDirective, Video } from '../shared-main' 18import { PeerTubeTemplateDirective, Video } from '../shared-main'
19import { AbstractVideoList } from './abstract-video-list' 19import { AbstractVideoList } from './abstract-video-list'
@@ -27,6 +27,7 @@ export type SelectionType = { [ id: number ]: boolean }
27 styleUrls: [ './videos-selection.component.scss' ] 27 styleUrls: [ './videos-selection.component.scss' ]
28}) 28})
29export class VideosSelectionComponent extends AbstractVideoList implements OnInit, OnDestroy, AfterContentInit { 29export class VideosSelectionComponent extends AbstractVideoList implements OnInit, OnDestroy, AfterContentInit {
30 @Input() user: User
30 @Input() pagination: ComponentPagination 31 @Input() pagination: ComponentPagination
31 @Input() titlePage: string 32 @Input() titlePage: string
32 @Input() miniatureDisplayOptions: MiniatureDisplayOptions 33 @Input() miniatureDisplayOptions: MiniatureDisplayOptions