From 754300f0ffb2d9c4df23753b237552eb7b88269f Mon Sep 17 00:00:00 2001 From: paf <philipp.franck@dainst.de> Date: Thu, 16 Jan 2020 10:19:24 +0100 Subject: [PATCH] update angular pt ii --- src/app/superadmin/users/users.component.ts | 2 +- src/app/superadmin/workspaces/workspaces.component.ts | 2 +- src/app/workspace/files/files.component.ts | 2 +- src/app/workspace/monitor/monitor.component.ts | 2 +- src/app/workspace/results/results.component.ts | 2 +- src/app/workspace/syscheck/syscheck.component.ts | 2 +- src/environments/environment.ts | 2 +- tsconfig.json | 10 +++++++++- 8 files changed, 16 insertions(+), 8 deletions(-) diff --git a/src/app/superadmin/users/users.component.ts b/src/app/superadmin/users/users.component.ts index 4995c3fe..a4ac3999 100644 --- a/src/app/superadmin/users/users.component.ts +++ b/src/app/superadmin/users/users.component.ts @@ -34,7 +34,7 @@ export class UsersComponent implements OnInit, OnDestroy { public displayedWorkspaceColumns = ['selectCheckbox', 'label']; private logindataSubscription: Subscription = null; - @ViewChild(MatSort) sort: MatSort; + @ViewChild(MatSort, { static: false }) sort: MatSort; constructor( private bs: BackendService, diff --git a/src/app/superadmin/workspaces/workspaces.component.ts b/src/app/superadmin/workspaces/workspaces.component.ts index a5f44d3a..cd077da3 100644 --- a/src/app/superadmin/workspaces/workspaces.component.ts +++ b/src/app/superadmin/workspaces/workspaces.component.ts @@ -34,7 +34,7 @@ export class WorkspacesComponent implements OnInit, OnDestroy { public UserlistDatasource: MatTableDataSource<IdRoleData>; public displayedUserColumns = ['selectCheckbox', 'name']; - @ViewChild(MatSort) sort: MatSort; + @ViewChild(MatSort, { static: false }) sort: MatSort; constructor( private bs: BackendService, diff --git a/src/app/workspace/files/files.component.ts b/src/app/workspace/files/files.component.ts index f8d9b72f..35dd0ed6 100644 --- a/src/app/workspace/files/files.component.ts +++ b/src/app/workspace/files/files.component.ts @@ -37,7 +37,7 @@ export class FilesComponent implements OnInit, OnDestroy { public checkWarnings = []; public checkInfos = []; - @ViewChild(MatSort) sort: MatSort; + @ViewChild(MatSort, { static: true }) sort: MatSort; constructor( @Inject('SERVER_URL') private serverUrl: string, diff --git a/src/app/workspace/monitor/monitor.component.ts b/src/app/workspace/monitor/monitor.component.ts index c69704e8..b8987e79 100644 --- a/src/app/workspace/monitor/monitor.component.ts +++ b/src/app/workspace/monitor/monitor.component.ts @@ -24,7 +24,7 @@ export class MonitorComponent implements OnInit, OnDestroy { public tableselectionCheckbox = new SelectionModel<MonitorData>(true, []); private workspaceIdSubscription: Subscription = null; public dataLoading = false; - @ViewChild(MatSort) sort: MatSort; + @ViewChild(MatSort, { static: true }) sort: MatSort; constructor( private bs: BackendService, diff --git a/src/app/workspace/results/results.component.ts b/src/app/workspace/results/results.component.ts index f68d360c..bf31c736 100644 --- a/src/app/workspace/results/results.component.ts +++ b/src/app/workspace/results/results.component.ts @@ -25,7 +25,7 @@ export class ResultsComponent implements OnInit, OnDestroy { public dataLoading = false; private workspaceIdSubscription: Subscription = null; - @ViewChild(MatSort) sort: MatSort; + @ViewChild(MatSort, { static: true }) sort: MatSort; constructor( private bs: BackendService, diff --git a/src/app/workspace/syscheck/syscheck.component.ts b/src/app/workspace/syscheck/syscheck.component.ts index c1706cda..b95e5d30 100644 --- a/src/app/workspace/syscheck/syscheck.component.ts +++ b/src/app/workspace/syscheck/syscheck.component.ts @@ -22,7 +22,7 @@ export class SyscheckComponent implements OnInit { public tableselectionCheckbox = new SelectionModel<SysCheckStatistics>(true, []); public dataLoading = false; - @ViewChild(MatSort) sort: MatSort; + @ViewChild(MatSort, { static: true }) sort: MatSort; constructor( private bs: BackendService, diff --git a/src/environments/environment.ts b/src/environments/environment.ts index 82b5a8a4..ba15a398 100644 --- a/src/environments/environment.ts +++ b/src/environments/environment.ts @@ -5,7 +5,7 @@ export const environment = { production: false, - testcenterUrl: 'https://itemdb2.iqb.hu-berlin.de/admin/', + testcenterUrl: 'http://localhost/2020/testcenter-iqb-php/admin/', appName: 'IQB-Testcenter Verwaltung', appPublisher: 'IQB - Institut zur Qualitätsentwicklung im Bildungswesen', appVersion: '0.5 (dev)' diff --git a/tsconfig.json b/tsconfig.json index 9187c607..d4754688 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -18,6 +18,14 @@ "lib": [ "es2017", "dom" - ] + ], + "paths": { + "core-js/es7/reflect": [ + "node_modules/core-js/proposals/reflect-metadata" + ], + "core-js/es6/reflect": [ + "node_modules/core-js/proposals/reflect-metadata" + ] + } } } -- GitLab