diff options
Diffstat (limited to 'client/src/app/+my-account/my-account-video-playlists/my-account-video-playlist-elements.component.ts')
-rw-r--r-- | client/src/app/+my-account/my-account-video-playlists/my-account-video-playlist-elements.component.ts | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/client/src/app/+my-account/my-account-video-playlists/my-account-video-playlist-elements.component.ts b/client/src/app/+my-account/my-account-video-playlists/my-account-video-playlist-elements.component.ts index 6f307a058..22c9af566 100644 --- a/client/src/app/+my-account/my-account-video-playlists/my-account-video-playlist-elements.component.ts +++ b/client/src/app/+my-account/my-account-video-playlists/my-account-video-playlist-elements.component.ts | |||
@@ -3,7 +3,7 @@ import { Notifier, ServerService } from '@app/core' | |||
3 | import { AuthService } from '../../core/auth' | 3 | import { AuthService } from '../../core/auth' |
4 | import { ConfirmService } from '../../core/confirm' | 4 | import { ConfirmService } from '../../core/confirm' |
5 | import { ComponentPagination } from '@app/shared/rest/component-pagination.model' | 5 | import { ComponentPagination } from '@app/shared/rest/component-pagination.model' |
6 | import { Subscription } from 'rxjs' | 6 | import { Subject, Subscription } from 'rxjs' |
7 | import { ActivatedRoute } from '@angular/router' | 7 | import { ActivatedRoute } from '@angular/router' |
8 | import { VideoPlaylistService } from '@app/shared/video-playlist/video-playlist.service' | 8 | import { VideoPlaylistService } from '@app/shared/video-playlist/video-playlist.service' |
9 | import { VideoPlaylist } from '@app/shared/video-playlist/video-playlist.model' | 9 | import { VideoPlaylist } from '@app/shared/video-playlist/video-playlist.model' |
@@ -22,10 +22,12 @@ export class MyAccountVideoPlaylistElementsComponent implements OnInit, OnDestro | |||
22 | 22 | ||
23 | pagination: ComponentPagination = { | 23 | pagination: ComponentPagination = { |
24 | currentPage: 1, | 24 | currentPage: 1, |
25 | itemsPerPage: 30, | 25 | itemsPerPage: 10, |
26 | totalItems: null | 26 | totalItems: null |
27 | } | 27 | } |
28 | 28 | ||
29 | onDataSubject = new Subject<any[]>() | ||
30 | |||
29 | private videoPlaylistId: string | number | 31 | private videoPlaylistId: string | number |
30 | private paramsSub: Subscription | 32 | private paramsSub: Subscription |
31 | 33 | ||
@@ -102,6 +104,8 @@ export class MyAccountVideoPlaylistElementsComponent implements OnInit, OnDestro | |||
102 | .subscribe(({ total, data }) => { | 104 | .subscribe(({ total, data }) => { |
103 | this.playlistElements = this.playlistElements.concat(data) | 105 | this.playlistElements = this.playlistElements.concat(data) |
104 | this.pagination.totalItems = total | 106 | this.pagination.totalItems = total |
107 | |||
108 | this.onDataSubject.next(data) | ||
105 | }) | 109 | }) |
106 | } | 110 | } |
107 | 111 | ||