summaryrefslogtreecommitdiffstats
path: root/cds-ui/designer-client/src/app/modules/feature-modules/packages/package-creation/template-mapping/templ-mapp-creation/templ-mapp-creation.component.ts
diff options
context:
space:
mode:
Diffstat (limited to 'cds-ui/designer-client/src/app/modules/feature-modules/packages/package-creation/template-mapping/templ-mapp-creation/templ-mapp-creation.component.ts')
-rw-r--r--cds-ui/designer-client/src/app/modules/feature-modules/packages/package-creation/template-mapping/templ-mapp-creation/templ-mapp-creation.component.ts9
1 files changed, 7 insertions, 2 deletions
diff --git a/cds-ui/designer-client/src/app/modules/feature-modules/packages/package-creation/template-mapping/templ-mapp-creation/templ-mapp-creation.component.ts b/cds-ui/designer-client/src/app/modules/feature-modules/packages/package-creation/template-mapping/templ-mapp-creation/templ-mapp-creation.component.ts
index 0bf4d9c54..a26f3b90e 100644
--- a/cds-ui/designer-client/src/app/modules/feature-modules/packages/package-creation/template-mapping/templ-mapp-creation/templ-mapp-creation.component.ts
+++ b/cds-ui/designer-client/src/app/modules/feature-modules/packages/package-creation/template-mapping/templ-mapp-creation/templ-mapp-creation.component.ts
@@ -74,8 +74,8 @@ export class TemplMappCreationComponent implements OnInit, OnDestroy, AfterViewI
dataSource: MatTableDataSource<{}>;
initDataSource: MatTableDataSource<{}>;
// dataSource = new MatTableDataSource();
- @ViewChild(MatPaginator, { static: true }) paginator: MatPaginator;
- @ViewChild(MatSort, { static: true }) sort: MatSort;
+ @ViewChild('paginate', { static: true }) paginator: MatPaginator;
+ @ViewChild('sort', { static: true }) sort: MatSort;
@ViewChild(MatPaginator, { static: true }) initPaginator: MatPaginator;
@ViewChild(MatSort, { static: true }) initSort: MatSort;
@@ -519,6 +519,11 @@ export class TemplMappCreationComponent implements OnInit, OnDestroy, AfterViewI
rerender(): void {
this.initDataSource = new MatTableDataSource(this.resourceDictionaryRes);
// this.cdr.detectChanges();
+ /*
+ Hint: the intial page size for the table will be the result size; I did that because the table doesn't load element in DOM,
+ as result some function are not working well like save and you have to move to other pages to fix that.
+ */
+ this.initPaginator.pageSize = this.resourceDictionaryRes.length;
this.initDataSource.paginator = this.initPaginator;
this.initDataSource.sort = this.initSort;
}