Fix issue with sorting
This commit is contained in:
parent
a7a7d6581a
commit
04340a5572
@ -25,8 +25,8 @@ import { finalize } from 'rxjs';
|
|||||||
styleUrl: './param-table.component.scss'
|
styleUrl: './param-table.component.scss'
|
||||||
})
|
})
|
||||||
export class ParamTableComponent {
|
export class ParamTableComponent {
|
||||||
@ViewChild(MatPaginator) paginator!: MatPaginator;
|
//@ViewChild(MatPaginator) paginator!: MatPaginator;
|
||||||
@ViewChild(MatSort) sort!: MatSort;
|
//@ViewChild(MatSort) sort!: MatSort;
|
||||||
|
|
||||||
@Input() table_mode: TABLE_MODE = 'TABLE-RECORD';
|
@Input() table_mode: TABLE_MODE = 'TABLE-RECORD';
|
||||||
@Input() paramHeading: string = 'Table Records';
|
@Input() paramHeading: string = 'Table Records';
|
||||||
@ -54,6 +54,17 @@ export class ParamTableComponent {
|
|||||||
private notificationService = inject(NotificationService);
|
private notificationService = inject(NotificationService);
|
||||||
|
|
||||||
dataSource = new MatTableDataSource<any>([]);
|
dataSource = new MatTableDataSource<any>([]);
|
||||||
|
|
||||||
|
@ViewChild(MatPaginator, { static: false })
|
||||||
|
set paginator(value: MatPaginator) {
|
||||||
|
this.dataSource.paginator = value;
|
||||||
|
}
|
||||||
|
|
||||||
|
@ViewChild(MatSort, { static: false })
|
||||||
|
set sort(value: MatSort) {
|
||||||
|
this.dataSource.sort = value;
|
||||||
|
}
|
||||||
|
|
||||||
paramForm: FormGroup;
|
paramForm: FormGroup;
|
||||||
|
|
||||||
ngAfterViewInit() {
|
ngAfterViewInit() {
|
||||||
@ -62,8 +73,8 @@ export class ParamTableComponent {
|
|||||||
this.dataSource.data = this.paramData;
|
this.dataSource.data = this.paramData;
|
||||||
}
|
}
|
||||||
|
|
||||||
displayedColumns: string[] = ['ParamType', 'ParamDesc', 'paramvalue', 'addlparamvalue1', 'addlparamvalue2', 'addlparamvalue3',
|
displayedColumns: string[] = ['paramType', 'paramDesc', 'paramValue', 'addlParamValue1', 'addlParamValue2', 'addlParamValue3',
|
||||||
'addlparamvalue4', 'addlparamvalue5', 'actions'];
|
'addlParamValue4', 'addlParamValue5', 'actions'];
|
||||||
|
|
||||||
formControls: any = {};
|
formControls: any = {};
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user