import { Component, Input, OnChanges, OnInit, TemplateRef, ViewChild } from '@angular/core';
-import { I18n } from '@ngx-translate/i18n-polyfill';
-import { TableComponent } from '../../../shared/datatable/table/table.component';
-import { CdTableColumn } from '../../../shared/models/cd-table-column';
+import { TableComponent } from '~/app/shared/datatable/table/table.component';
+import { CdTableColumn } from '~/app/shared/models/cd-table-column';
import {
RbdConfigurationEntry,
RbdConfigurationSourceField,
RbdConfigurationType
-} from '../../../shared/models/configuration';
-import { RbdConfigurationSourcePipe } from '../../../shared/pipes/rbd-configuration-source.pipe';
-import { FormatterService } from '../../../shared/services/formatter.service';
-import { RbdConfigurationService } from '../../../shared/services/rbd-configuration.service';
+} from '~/app/shared/models/configuration';
+import { RbdConfigurationSourcePipe } from '~/app/shared/pipes/rbd-configuration-source.pipe';
+import { FormatterService } from '~/app/shared/services/formatter.service';
+import { RbdConfigurationService } from '~/app/shared/services/rbd-configuration.service';
@Component({
selector: 'cd-rbd-configuration-table',
constructor(
public formatterService: FormatterService,
- private rbdConfigurationService: RbdConfigurationService,
- private i18n: I18n
+ private rbdConfigurationService: RbdConfigurationService
) {}
ngOnInit() {
this.poolConfigurationColumns = [
- { prop: 'displayName', name: this.i18n('Name') },
- { prop: 'description', name: this.i18n('Description') },
- { prop: 'name', name: this.i18n('Key') },
+ { prop: 'displayName', name: $localize`Name` },
+ { prop: 'description', name: $localize`Description` },
+ { prop: 'name', name: $localize`Key` },
{
prop: 'source',
- name: this.i18n('Source'),
+ name: $localize`Source`,
cellTemplate: this.configurationSourceTpl,
pipe: new RbdConfigurationSourcePipe()
},
- { prop: 'value', name: this.i18n('Value'), cellTemplate: this.configurationValueTpl }
+ { prop: 'value', name: $localize`Value`, cellTemplate: this.configurationValueTpl }
];
}