Fix code typos

This commit is contained in:
Chocobozzz 2018-10-16 11:51:28 +02:00
parent 26370ce469
commit 92ea70a782
7 changed files with 12 additions and 12 deletions

View File

@ -1,5 +1,5 @@
<p-table
[value]="blockedAccounts" [lazy]="true" [paginator]="true" [totalRecords]="totalRecords" [rows]="rowsPerPage"
[value]="blockedServers" [lazy]="true" [paginator]="true" [totalRecords]="totalRecords" [rows]="rowsPerPage"
[sortField]="sort.field" [sortOrder]="sort.order" (onLazyLoad)="loadLazy($event)"
>

View File

@ -12,7 +12,7 @@ import { ServerBlock } from '../../../../../../shared'
templateUrl: './instance-server-blocklist.component.html'
})
export class InstanceServerBlocklistComponent extends RestTable implements OnInit {
blockedAccounts: ServerBlock[] = []
blockedServers: ServerBlock[] = []
totalRecords = 0
rowsPerPage = 10
sort: SortMeta = { field: 'createdAt', order: -1 }
@ -50,7 +50,7 @@ export class InstanceServerBlocklistComponent extends RestTable implements OnIni
return this.blocklistService.getInstanceServerBlocklist(this.pagination, this.sort)
.subscribe(
resultList => {
this.blockedAccounts = resultList.data
this.blockedServers = resultList.data
this.totalRecords = resultList.total
},

View File

@ -6,9 +6,9 @@
<a *ngIf="hasVideoBlacklistRight()" i18n routerLink="video-blacklist/list" routerLinkActive="active">Blacklisted videos</a>
<a *ngIf="hasAccountsBlacklistRight()" i18n routerLink="blocklist/accounts" routerLinkActive="active">Muted accounts</a>
<a *ngIf="hasAccountsBlocklistRight()" i18n routerLink="blocklist/accounts" routerLinkActive="active">Muted accounts</a>
<a *ngIf="hasServersBlacklistRight()" i18n routerLink="blocklist/servers" routerLinkActive="active">Muted servers</a>
<a *ngIf="hasServersBlocklistRight()" i18n routerLink="blocklist/servers" routerLinkActive="active">Muted servers</a>
</div>
</div>

View File

@ -17,11 +17,11 @@ export class ModerationComponent {
return this.auth.getUser().hasRight(UserRight.MANAGE_VIDEO_BLACKLIST)
}
hasAccountsBlacklistRight () {
hasAccountsBlocklistRight () {
return this.auth.getUser().hasRight(UserRight.MANAGE_ACCOUNTS_BLOCKLIST)
}
hasServersBlacklistRight () {
hasServersBlocklistRight () {
return this.auth.getUser().hasRight(UserRight.MANAGE_SERVERS_BLOCKLIST)
}
}

View File

@ -3,7 +3,7 @@
</div>
<p-table
[value]="blockedAccounts" [lazy]="true" [paginator]="true" [totalRecords]="totalRecords" [rows]="rowsPerPage"
[value]="blockedServers" [lazy]="true" [paginator]="true" [totalRecords]="totalRecords" [rows]="rowsPerPage"
[sortField]="sort.field" [sortOrder]="sort.order" (onLazyLoad)="loadLazy($event)"
>

View File

@ -12,7 +12,7 @@ import { BlocklistService } from '@app/shared/blocklist'
templateUrl: './my-account-server-blocklist.component.html'
})
export class MyAccountServerBlocklistComponent extends RestTable implements OnInit {
blockedAccounts: ServerBlock[] = []
blockedServers: ServerBlock[] = []
totalRecords = 0
rowsPerPage = 10
sort: SortMeta = { field: 'createdAt', order: -1 }
@ -50,7 +50,7 @@ export class MyAccountServerBlocklistComponent extends RestTable implements OnIn
return this.blocklistService.getUserServerBlocklist(this.pagination, this.sort)
.subscribe(
resultList => {
this.blockedAccounts = resultList.data
this.blockedServers = resultList.data
this.totalRecords = resultList.total
},

View File

@ -102,7 +102,7 @@ const myAccountRoutes: Routes = [
component: MyAccountBlocklistComponent,
data: {
meta: {
title: 'Accounts blocklist'
title: 'Muted accounts'
}
}
},
@ -111,7 +111,7 @@ const myAccountRoutes: Routes = [
component: MyAccountServerBlocklistComponent,
data: {
meta: {
title: 'Instances blocklist'
title: 'Muted instances'
}
}
}