diff options
Diffstat (limited to 'client/src/app/+my-account/my-account-ownership/my-account-ownership.component.ts')
-rw-r--r-- | client/src/app/+my-account/my-account-ownership/my-account-ownership.component.ts | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/client/src/app/+my-account/my-account-ownership/my-account-ownership.component.ts b/client/src/app/+my-account/my-account-ownership/my-account-ownership.component.ts index 0b51ac13c..77857c4fd 100644 --- a/client/src/app/+my-account/my-account-ownership/my-account-ownership.component.ts +++ b/client/src/app/+my-account/my-account-ownership/my-account-ownership.component.ts | |||
@@ -1,13 +1,11 @@ | |||
1 | import { Component, OnInit, ViewChild } from '@angular/core' | 1 | import { Component, OnInit, ViewChild } from '@angular/core' |
2 | import { NotificationsService } from 'angular2-notifications' | 2 | import { Notifier } from '@app/core' |
3 | import { I18n } from '@ngx-translate/i18n-polyfill' | ||
4 | import { RestPagination, RestTable } from '@app/shared' | 3 | import { RestPagination, RestTable } from '@app/shared' |
5 | import { SortMeta } from 'primeng/components/common/sortmeta' | 4 | import { SortMeta } from 'primeng/components/common/sortmeta' |
6 | import { VideoChangeOwnership } from '../../../../../shared' | 5 | import { VideoChangeOwnership } from '../../../../../shared' |
7 | import { VideoOwnershipService } from '@app/shared/video-ownership' | 6 | import { VideoOwnershipService } from '@app/shared/video-ownership' |
8 | import { Account } from '@app/shared/account/account.model' | 7 | import { Account } from '@app/shared/account/account.model' |
9 | import { MyAccountAcceptOwnershipComponent } | 8 | import { MyAccountAcceptOwnershipComponent } from './my-account-accept-ownership/my-account-accept-ownership.component' |
10 | from '@app/+my-account/my-account-ownership/my-account-accept-ownership/my-account-accept-ownership.component' | ||
11 | 9 | ||
12 | @Component({ | 10 | @Component({ |
13 | selector: 'my-account-ownership', | 11 | selector: 'my-account-ownership', |
@@ -23,9 +21,8 @@ export class MyAccountOwnershipComponent extends RestTable implements OnInit { | |||
23 | @ViewChild('myAccountAcceptOwnershipComponent') myAccountAcceptOwnershipComponent: MyAccountAcceptOwnershipComponent | 21 | @ViewChild('myAccountAcceptOwnershipComponent') myAccountAcceptOwnershipComponent: MyAccountAcceptOwnershipComponent |
24 | 22 | ||
25 | constructor ( | 23 | constructor ( |
26 | private notificationsService: NotificationsService, | 24 | private notifier: Notifier, |
27 | private videoOwnershipService: VideoOwnershipService, | 25 | private videoOwnershipService: VideoOwnershipService |
28 | private i18n: I18n | ||
29 | ) { | 26 | ) { |
30 | super() | 27 | super() |
31 | } | 28 | } |
@@ -50,7 +47,7 @@ export class MyAccountOwnershipComponent extends RestTable implements OnInit { | |||
50 | this.videoOwnershipService.refuseOwnership(videoChangeOwnership.id) | 47 | this.videoOwnershipService.refuseOwnership(videoChangeOwnership.id) |
51 | .subscribe( | 48 | .subscribe( |
52 | () => this.loadData(), | 49 | () => this.loadData(), |
53 | err => this.notificationsService.error(this.i18n('Error'), err.message) | 50 | err => this.notifier.error(err.message) |
54 | ) | 51 | ) |
55 | } | 52 | } |
56 | 53 | ||
@@ -62,7 +59,7 @@ export class MyAccountOwnershipComponent extends RestTable implements OnInit { | |||
62 | this.totalRecords = resultList.total | 59 | this.totalRecords = resultList.total |
63 | }, | 60 | }, |
64 | 61 | ||
65 | err => this.notificationsService.error(this.i18n('Error'), err.message) | 62 | err => this.notifier.error(err.message) |
66 | ) | 63 | ) |
67 | } | 64 | } |
68 | } | 65 | } |