LP1864371 Migrate deprecated loadChildren invocations
authorBill Erickson <berickxx@gmail.com>
Fri, 26 Jun 2020 18:24:00 +0000 (14:24 -0400)
committerBill Erickson <berickxx@gmail.com>
Thu, 6 Aug 2020 16:34:31 +0000 (12:34 -0400)
https://angular.io/guide/deprecations#loadchildren-string-syntax

Signed-off-by: Bill Erickson <berickxx@gmail.com>
Signed-off-by: Jane Sandberg <sandbej@linnbenton.edu>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
Open-ILS/src/eg2/src/app/routing.module.ts
Open-ILS/src/eg2/src/app/staff/admin/local/routing.module.ts
Open-ILS/src/eg2/src/app/staff/admin/routing.module.ts
Open-ILS/src/eg2/src/app/staff/admin/server/routing.module.ts
Open-ILS/src/eg2/src/app/staff/admin/workstation/routing.module.ts
Open-ILS/src/eg2/src/app/staff/cat/routing.module.ts
Open-ILS/src/eg2/src/app/staff/circ/patron/routing.module.ts
Open-ILS/src/eg2/src/app/staff/circ/routing.module.ts
Open-ILS/src/eg2/src/app/staff/routing.module.ts
Open-ILS/src/eg2/tsconfig.json

index db3ee19..3b7d2e3 100644 (file)
@@ -16,7 +16,7 @@ const routes: Routes = [
   }, {
     path: 'staff',
     resolve : {startup : BaseResolver},
-    loadChildren: './staff/staff.module#StaffModule'
+    loadChildren: () => import('./staff/staff.module').then(m => m.StaffModule)
   }
 ];
 
index 15a9153..c29e7e6 100644 (file)
@@ -24,7 +24,8 @@ const routes: Routes = [{
     component: StandingPenaltyComponent
 }, {
     path: 'action/survey',
-    loadChildren: '@eg/staff/admin/local/survey/survey.module#SurveyModule'
+    loadChildren: () =>
+      import('./survey/survey.module').then(m => m.SurveyModule)
 }, {
     path: ':schema/:table',
     component: BasicAdminPageComponent
index a0df70e..b94adf9 100644 (file)
@@ -3,21 +3,26 @@ import {RouterModule, Routes} from '@angular/router';
 
 const routes: Routes = [{
   path: '',
-  children : [
-  { path: 'workstation',
-   loadChildren: '@eg/staff/admin/workstation/routing.module#AdminWsRoutingModule'
+  children : [{
+    path: 'workstation',
+    loadChildren: () =>
+      import('./workstation/routing.module').then(m => m.AdminWsRoutingModule)
   }, {
     path: 'server',
-    loadChildren: '@eg/staff/admin/server/admin-server.module#AdminServerModule'
+    loadChildren: () =>
+      import('./server/admin-server.module').then(m => m.AdminServerModule)
   }, {
     path: 'local',
-    loadChildren: '@eg/staff/admin/local/admin-local.module#AdminLocalModule'
+    loadChildren: () =>
+      import('./local/admin-local.module').then(m => m.AdminLocalModule)
   }, {
     path: 'acq',
-    loadChildren: '@eg/staff/admin/acq/admin-acq.module#AdminAcqModule'
+    loadChildren: () =>
+      import('./acq/admin-acq.module').then(m => m.AdminAcqModule)
   }, {
     path: 'booking',
-    loadChildren: '@eg/staff/admin/booking/admin-booking.module#AdminBookingModule'
+    loadChildren: () =>
+      import('./booking/admin-booking.module').then(m => m.AdminBookingModule)
   }]
 }];
 
index ec37bc2..194a979 100644 (file)
@@ -14,7 +14,8 @@ const routes: Routes = [{
     component: OrgUnitTypeComponent
 }, {
     path: 'config/floating_group',
-    loadChildren: '@eg/staff/admin/server/floating-group/floating-group.module#FloatingGroupModule'
+    loadChildren: () =>
+      import('./floating-group/floating-group.module').then(m => m.FloatingGroupModule)
 }, {
     path: 'config/print_template',
     component: PrintTemplateComponent
@@ -23,7 +24,8 @@ const routes: Routes = [{
     component: PermGroupTreeComponent
 }, {
     path: 'actor/org_unit',
-    loadChildren: '@eg/staff/admin/server/org-unit.module#OrgUnitModule'
+    loadChildren: () =>
+      import('./org-unit.module').then(m => m.OrgUnitModule)
 }, {
     path: 'actor/org_unit_proximity_adjustment',
     component: BasicAdminPageComponent,
index acdb9a1..6996a85 100644 (file)
@@ -3,7 +3,8 @@ import {RouterModule, Routes} from '@angular/router';
 
 const routes: Routes = [{
     path: 'workstations',
-    loadChildren: '@eg/staff/admin/workstation/workstations/workstations.module#ManageWorkstationsModule'
+    loadChildren: () =>
+      import('./workstations/workstations.module').then(m => m.ManageWorkstationsModule)
 }];
 
 @NgModule({
index 67fb59b..d4b2770 100644 (file)
@@ -3,10 +3,12 @@ import {RouterModule, Routes} from '@angular/router';
 
 const routes: Routes = [
   { path: 'vandelay',
-    loadChildren: '@eg/staff/cat/vandelay/vandelay.module#VandelayModule'
+    loadChildren: () =>
+      import('./vandelay/vandelay.module').then(m => m.VandelayModule)
   }, {
     path: 'authority',
-    loadChildren: '@eg/staff/cat/authority/authority.module#AuthorityModule'
+    loadChildren: () =>
+      import('./authority/authority.module').then(m => m.AuthorityModule)
   }
 ];
 
index 9033f92..c2b7432 100644 (file)
@@ -3,7 +3,8 @@ import {RouterModule, Routes} from '@angular/router';
 
 const routes: Routes = [
   { path: 'bcsearch',
-    loadChildren: '@eg/staff/circ/patron/bcsearch/bcsearch.module#BcSearchModule'
+    loadChildren: () =>
+      import('./bcsearch/bcsearch.module').then(m => m.BcSearchModule)
   }
 ];
 
index 2409977..fae4330 100644 (file)
@@ -3,7 +3,8 @@ import {RouterModule, Routes} from '@angular/router';
 
 const routes: Routes = [
   { path: 'patron',
-    loadChildren: '@eg/staff/circ/patron/routing.module#CircPatronRoutingModule'
+    loadChildren: () =>
+      import('./patron/routing.module').then(m => m.CircPatronRoutingModule)
   }
 ];
 
index e390a3d..16c21c9 100644 (file)
@@ -20,7 +20,8 @@ const routes: Routes = [{
     pathMatch: 'full',
   }, {
     path: 'booking',
-    loadChildren : '@eg/staff/booking/booking.module#BookingModule'
+    loadChildren: () =>
+      import('./booking/booking.module').then(m => m.BookingModule)
   }, {
     path: 'about',
     component: AboutComponent
@@ -32,19 +33,24 @@ const routes: Routes = [{
     component: StaffSplashComponent
   }, {
     path: 'circ',
-    loadChildren : '@eg/staff/circ/routing.module#CircRoutingModule'
+    loadChildren: () =>
+      import('./circ/routing.module').then(m => m.CircRoutingModule)
   }, {
     path: 'cat',
-    loadChildren : '@eg/staff/cat/routing.module#CatRoutingModule'
+    loadChildren: () =>
+      import('./cat/routing.module').then(m => m.CatRoutingModule)
   }, {
     path: 'catalog',
-    loadChildren : '@eg/staff/catalog/catalog.module#CatalogModule'
+    loadChildren: () =>
+      import('./catalog/catalog.module').then(m => m.CatalogModule)
   }, {
     path: 'sandbox',
-    loadChildren : '@eg/staff/sandbox/sandbox.module#SandboxModule'
+    loadChildren: () =>
+      import('./sandbox/sandbox.module').then(m => m.SandboxModule)
   }, {
     path: 'admin',
-    loadChildren : '@eg/staff/admin/routing.module#AdminRoutingModule'
+    loadChildren: () =>
+      import('./admin/routing.module').then(m => m.AdminRoutingModule)
   }]
 }];
 
index e50f1d4..803f251 100644 (file)
@@ -4,7 +4,7 @@
     "outDir": "./dist/out-tsc",
     "sourceMap": true,
     "declaration": false,
-    "module": "es6",
+    "module": "esnext",
     "moduleResolution": "node",
     "emitDecoratorMetadata": true,
     "experimentalDecorators": true,