From 7eaddc2e7596bd56db1f9b9ae33d7767bc4d5a81 Mon Sep 17 00:00:00 2001 From: Bill Erickson Date: Fri, 16 Aug 2019 15:44:37 -0400 Subject: [PATCH] LP1840050 FM Editor WIP Signed-off-by: Bill Erickson --- .../eg2/src/app/share/fm-editor/fm-editor-action.component.html | 2 -- .../eg2/src/app/share/fm-editor/fm-editor-action.component.ts | 9 +++++++-- .../src/eg2/src/app/share/fm-editor/fm-editor.component.html | 8 ++++---- 3 files changed, 11 insertions(+), 8 deletions(-) delete mode 100644 Open-ILS/src/eg2/src/app/share/fm-editor/fm-editor-action.component.html diff --git a/Open-ILS/src/eg2/src/app/share/fm-editor/fm-editor-action.component.html b/Open-ILS/src/eg2/src/app/share/fm-editor/fm-editor-action.component.html deleted file mode 100644 index 139597f9cb..0000000000 --- a/Open-ILS/src/eg2/src/app/share/fm-editor/fm-editor-action.component.html +++ /dev/null @@ -1,2 +0,0 @@ - - diff --git a/Open-ILS/src/eg2/src/app/share/fm-editor/fm-editor-action.component.ts b/Open-ILS/src/eg2/src/app/share/fm-editor/fm-editor-action.component.ts index fbc718fc75..ab52b4096d 100644 --- a/Open-ILS/src/eg2/src/app/share/fm-editor/fm-editor-action.component.ts +++ b/Open-ILS/src/eg2/src/app/share/fm-editor/fm-editor-action.component.ts @@ -1,4 +1,4 @@ -import {Component, Input, Output, EventEmitter, Host} from '@angular/core'; +import {Component, Input, Output, EventEmitter, Host, OnInit} from '@angular/core'; import {FmRecordEditorComponent} from './fm-editor.component'; @Component({ @@ -6,13 +6,15 @@ import {FmRecordEditorComponent} from './fm-editor.component'; template: '' // no-op }) -export class FmRecordEditorActionComponent { +export class FmRecordEditorActionComponent implements OnInit { // unique identifier @Input() key: string; @Input() label: string; + @Input() buttonCss: string = 'btn-outline-dark'; + // Emits the 'key' of the clicked action. @Output() actionClick: EventEmitter; @@ -20,6 +22,9 @@ export class FmRecordEditorActionComponent { constructor(@Host() private editor: FmRecordEditorComponent) { this.actionClick = new EventEmitter(); + } + + ngOnInit() { this.editor.actions.push(this); } } diff --git a/Open-ILS/src/eg2/src/app/share/fm-editor/fm-editor.component.html b/Open-ILS/src/eg2/src/app/share/fm-editor/fm-editor.component.html index ecde681b5d..afae0effb1 100644 --- a/Open-ILS/src/eg2/src/app/share/fm-editor/fm-editor.component.html +++ b/Open-ILS/src/eg2/src/app/share/fm-editor/fm-editor.component.html @@ -165,9 +165,9 @@