This commit is contained in:
Lurkars
2021-03-13 09:47:25 +01:00
parent 4cd6a0028b
commit 52faaba99e
19 changed files with 109 additions and 363 deletions
@@ -2,11 +2,11 @@
<ng-container matColumnDef="name">
<th mat-header-cell *matHeaderCellDef mat-sort-header="name"> {{'permissions.name' | i18n}} </th>
<td mat-cell *matCellDef="let permission">
<mat-icon inline=true>{{'apps.' + permission.name + '.icon' | i18n}}</mat-icon>
{{'apps.' + permission.name + '.title' | i18n}}
<mat-icon inline=true>{{'services.' + permission.name + '.icon' | i18n}}</mat-icon>
{{'services.' + permission.name + '.title' | i18n}}
<mat-icon *ngIf="permission.addon">add_circle</mat-icon>
<br>
<small>{{'apps.' + permission.name + '.subtitle' | i18n}}</small>
<small>{{'services.' + permission.name + '.subtitle' | i18n}}</small>
</td>
</ng-container>
@@ -29,7 +29,7 @@ export class PermissionsComponent implements OnInit {
this.permissions = data.sort((a, b) => {
const isAsc = sort.direction === 'asc';
switch(sort.active) {
case 'name': return this.compare(this.i18n.get('apps.' + a.name + '.title', []), this.i18n.get('apps.' + b.name + '.title', []), isAsc);
case 'name': return this.compare(this.i18n.get('services.' + a.name + '.title', []), this.i18n.get('services.' + b.name + '.title', []), isAsc);
case 'starts': return this.compare(a.starts, b.starts, isAsc);
case 'expires': return this.compare(a.expires, b.expires, isAsc);
default: return 0;
+2 -2
View File
@@ -3,8 +3,8 @@
<ng-container matColumnDef="name">
<th mat-header-cell *matHeaderCellDef mat-sort-header="name"> {{'quotas.name' | i18n}} </th>
<td mat-cell *matCellDef="let quota">
<mat-icon inline=true>{{'apps.' + quota.name + '.icon' | i18n}}</mat-icon>
{{'apps.' + quota.name + '.title' | i18n}}
<mat-icon inline=true>{{'services.' + quota.name + '.icon' | i18n}}</mat-icon>
{{'services.' + quota.name + '.title' | i18n}}
</td>
</ng-container>
+1 -1
View File
@@ -28,7 +28,7 @@ export class QuotasComponent implements OnInit {
this.quotas = data.sort((a, b) => {
const isAsc = sort.direction === 'asc';
switch(sort.active) {
case 'name': return this.compare(this.i18n.get('apps.' + a.name + '.title', []), this.i18n.get('apps.' + b.name + '.title', []), isAsc);
case 'name': return this.compare(this.i18n.get('services.' + a.name + '.title', []), this.i18n.get('services.' + b.name + '.title', []), isAsc);
case 'value': return this.compare(a.value, b.value, isAsc);
default: return 0;
}