2018-05-30 10:00:46 +00:00
|
|
|
import { Directive, Input, Output, TemplateRef } from '@angular/core';
|
|
|
|
|
|
|
|
@Directive({
|
|
|
|
selector: '[ofUITemplate]',
|
|
|
|
})
|
|
|
|
export class UITemplateDirective {
|
|
|
|
|
|
|
|
@Input() type: string;
|
|
|
|
|
2018-05-31 06:48:49 +00:00
|
|
|
// tslint:disable-next-line:no-input-rename
|
|
|
|
@Input('ofUITemplate') name: string;
|
2018-05-30 10:00:46 +00:00
|
|
|
|
|
|
|
constructor(public template: TemplateRef<any>) { }
|
|
|
|
|
|
|
|
getType(): string {
|
2018-05-31 06:48:49 +00:00
|
|
|
return this.name;
|
2018-05-30 10:00:46 +00:00
|
|
|
}
|
|
|
|
}
|