From d595a40dd39fede429d7fd81432a530739a0f882 Mon Sep 17 00:00:00 2001 From: Bill Erickson Date: Fri, 6 Apr 2018 15:08:57 +0000 Subject: [PATCH] LP#1626157 Ang2 misc repairs Signed-off-by: Bill Erickson --- Open-ILS/src/eg2/src/app/migration.module.ts | 22 ++++++---------------- .../app/staff/catalog/result/record.component.html | 2 +- .../src/eg2/src/app/staff/login.component.html | 2 +- 3 files changed, 8 insertions(+), 18 deletions(-) diff --git a/Open-ILS/src/eg2/src/app/migration.module.ts b/Open-ILS/src/eg2/src/app/migration.module.ts index 68fe67a073..4502e07516 100644 --- a/Open-ILS/src/eg2/src/app/migration.module.ts +++ b/Open-ILS/src/eg2/src/app/migration.module.ts @@ -11,19 +11,16 @@ */ import {BrowserModule} from '@angular/platform-browser'; import {NgModule} from '@angular/core'; -// Load ng-bootstrap because it might be used by downgraded components import {NgbModule} from '@ng-bootstrap/ng-bootstrap'; // ng-bootstrap import {CookieModule} from 'ngx-cookie'; // import CookieMonster -import {UpgradeModule, downgradeInjectable, - downgradeComponent} from '@angular/upgrade/static'; +import {UpgradeModule, downgradeInjectable, downgradeComponent} + from '@angular/upgrade/static'; -// Import and provide some Angular built-ins -// TODO: string interpolation a la ang1 egStrings titles +// Replacement for egStrings.setPageTitle() import {Title} from '@angular/platform-browser'; -import {EgCommonModule} from './common.module'; - // Import service handles so we can downgrade them. +import {EgCommonModule} from './common.module'; import {EgEventService} from '@eg/core/event'; import {EgStoreService} from '@eg/core/store'; import {EgIdlService} from '@eg/core/idl'; @@ -36,15 +33,13 @@ import {EgOrgService} from '@eg/core/org'; declare var angular: any; @NgModule({ - declarations: [], imports: [ UpgradeModule, BrowserModule, NgbModule.forRoot(), CookieModule.forRoot(), EgCommonModule.forRoot() - ], - exports: [] + ] }) export class EgMigrationModule { @@ -52,7 +47,7 @@ export class EgMigrationModule { constructor(private upgrade: UpgradeModule) {} ngDoBootstrap() { - let myWin: any = window; // avoid TS compiler warnings + let myWin: any = window; // hush compiler warnings if (!myWin.ang1PageApp) { console.error('NO PAGE APP DEFINED'); @@ -62,11 +57,6 @@ export class EgMigrationModule { console.log(`Ang2 loading Ang1 app ${myWin.ang1PageApp}`); angular.module(myWin.ang1PageApp) - /* sample directive downgrade - .directive('heroDetail', - downgradeComponent({ component: HeroDetailComponent }) - */ - .factory('eg2Event', downgradeInjectable(EgEventService)) .factory('eg2Store', downgradeInjectable(EgStoreService)) .factory('eg2Idl', downgradeInjectable(EgIdlService)) diff --git a/Open-ILS/src/eg2/src/app/staff/catalog/result/record.component.html b/Open-ILS/src/eg2/src/app/staff/catalog/result/record.component.html index c9a0cd9b45..1625bc5b2a 100644 --- a/Open-ILS/src/eg2/src/app/staff/catalog/result/record.component.html +++ b/Open-ILS/src/eg2/src/app/staff/catalog/result/record.component.html @@ -38,7 +38,7 @@
- + {{bibSummary.ccvms.icon_format.label}} diff --git a/Open-ILS/src/eg2/src/app/staff/login.component.html b/Open-ILS/src/eg2/src/app/staff/login.component.html index bafe28819c..58c2226b6f 100644 --- a/Open-ILS/src/eg2/src/app/staff/login.component.html +++ b/Open-ILS/src/eg2/src/app/staff/login.component.html @@ -41,7 +41,7 @@ name="workstation" required [(ngModel)]="args.workstation"> - -- 2.11.0