diff options
author | Chocobozzz <me@florianbigard.com> | 2021-08-19 09:24:29 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2021-08-25 11:24:11 +0200 |
commit | dd24f1bb0a4b252e5342b251ba36853364da7b8e (patch) | |
tree | 41a9506d07413f056fb90425705e258f96fdc77d /client/src/app/+my-library/my-videos | |
parent | 2e80d256cc75b4b02c8efc3d3e4cdf57ddf401a8 (diff) | |
download | PeerTube-dd24f1bb0a4b252e5342b251ba36853364da7b8e.tar.gz PeerTube-dd24f1bb0a4b252e5342b251ba36853364da7b8e.tar.zst PeerTube-dd24f1bb0a4b252e5342b251ba36853364da7b8e.zip |
Add video filters to common video pages
Diffstat (limited to 'client/src/app/+my-library/my-videos')
-rw-r--r-- | client/src/app/+my-library/my-videos/my-videos.component.html | 4 | ||||
-rw-r--r-- | client/src/app/+my-library/my-videos/my-videos.component.ts | 6 |
2 files changed, 6 insertions, 4 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 0552b8ce4..9f81f0ad7 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 | |||
@@ -19,7 +19,7 @@ | |||
19 | </h1> | 19 | </h1> |
20 | 20 | ||
21 | <div class="videos-header d-flex justify-content-between"> | 21 | <div class="videos-header d-flex justify-content-between"> |
22 | <my-advanced-input-filter [filters]="inputFilters" (search)="onSearch($event)"></my-advanced-input-filter> | 22 | <my-advanced-input-filter [emitOnInit]="false" [filters]="inputFilters" (search)="onSearch($event)"></my-advanced-input-filter> |
23 | 23 | ||
24 | <div class="peertube-select-container peertube-select-button"> | 24 | <div class="peertube-select-container peertube-select-button"> |
25 | <select [(ngModel)]="sort" (ngModelChange)="onChangeSortColumn()" class="form-control"> | 25 | <select [(ngModel)]="sort" (ngModelChange)="onChangeSortColumn()" class="form-control"> |
@@ -41,7 +41,7 @@ | |||
41 | [titlePage]="titlePage" | 41 | [titlePage]="titlePage" |
42 | [getVideosObservableFunction]="getVideosObservableFunction" | 42 | [getVideosObservableFunction]="getVideosObservableFunction" |
43 | [user]="user" | 43 | [user]="user" |
44 | [loadOnInit]="false" | 44 | [disabled]="disabled" |
45 | #videosSelection | 45 | #videosSelection |
46 | > | 46 | > |
47 | <ng-template ptTemplate="globalButtons"> | 47 | <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 edb9392dd..72d28ced7 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 | |||
@@ -54,6 +54,8 @@ export class MyVideosComponent implements OnInit, DisableForReuseHook { | |||
54 | } | 54 | } |
55 | ] | 55 | ] |
56 | 56 | ||
57 | disabled = false | ||
58 | |||
57 | private search: string | 59 | private search: string |
58 | 60 | ||
59 | constructor ( | 61 | constructor ( |
@@ -89,11 +91,11 @@ export class MyVideosComponent implements OnInit, DisableForReuseHook { | |||
89 | } | 91 | } |
90 | 92 | ||
91 | disableForReuse () { | 93 | disableForReuse () { |
92 | this.videosSelection.disableForReuse() | 94 | this.disabled = true |
93 | } | 95 | } |
94 | 96 | ||
95 | enabledForReuse () { | 97 | enabledForReuse () { |
96 | this.videosSelection.enabledForReuse() | 98 | this.disabled = false |
97 | } | 99 | } |
98 | 100 | ||
99 | getVideosObservable (page: number) { | 101 | getVideosObservable (page: number) { |