diff options
Diffstat (limited to 'client/src/app/videos/video-list/video-recently-added.component.ts')
-rw-r--r-- | client/src/app/videos/video-list/video-recently-added.component.ts | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/client/src/app/videos/video-list/video-recently-added.component.ts b/client/src/app/videos/video-list/video-recently-added.component.ts index 1cecd14a0..2bdc20d92 100644 --- a/client/src/app/videos/video-list/video-recently-added.component.ts +++ b/client/src/app/videos/video-list/video-recently-added.component.ts | |||
@@ -6,6 +6,8 @@ import { AuthService } from '../../core/auth' | |||
6 | import { AbstractVideoList } from '../../shared/video/abstract-video-list' | 6 | import { AbstractVideoList } from '../../shared/video/abstract-video-list' |
7 | import { SortField } from '../../shared/video/sort-field.type' | 7 | import { SortField } from '../../shared/video/sort-field.type' |
8 | import { VideoService } from '../../shared/video/video.service' | 8 | import { VideoService } from '../../shared/video/video.service' |
9 | import { FeedFormat } from '../../../../../shared/models/feeds/feed-format.enum' | ||
10 | import * as url from 'url' | ||
9 | 11 | ||
10 | @Component({ | 12 | @Component({ |
11 | selector: 'my-videos-recently-added', | 13 | selector: 'my-videos-recently-added', |
@@ -27,6 +29,7 @@ export class VideoRecentlyAddedComponent extends AbstractVideoList implements On | |||
27 | 29 | ||
28 | ngOnInit () { | 30 | ngOnInit () { |
29 | super.ngOnInit() | 31 | super.ngOnInit() |
32 | this.generateSyndicationList() | ||
30 | } | 33 | } |
31 | 34 | ||
32 | ngOnDestroy () { | 35 | ngOnDestroy () { |
@@ -38,4 +41,11 @@ export class VideoRecentlyAddedComponent extends AbstractVideoList implements On | |||
38 | 41 | ||
39 | return this.videoService.getVideos(newPagination, this.sort) | 42 | return this.videoService.getVideos(newPagination, this.sort) |
40 | } | 43 | } |
44 | |||
45 | generateSyndicationList () { | ||
46 | const feeds = this.videoService.getFeed('local') | ||
47 | this.syndicationItems['rss 2.0'] = feeds[FeedFormat.RSS] | ||
48 | this.syndicationItems['atom 1.0'] = feeds[FeedFormat.ATOM] | ||
49 | this.syndicationItems['json 1.0'] = feeds[FeedFormat.JSON] | ||
50 | } | ||
41 | } | 51 | } |