Zusätzliche Felder - missing files

This commit is contained in:
2020-03-02 16:28:00 +01:00
committed by smuddy
parent f5d9350e53
commit 5b746e0db5
3 changed files with 43 additions and 0 deletions

View File

@@ -0,0 +1,16 @@
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import {LegalOwnerPipe} from './legal-owner.pipe';
@NgModule({
declarations: [LegalOwnerPipe],
exports: [
LegalOwnerPipe
],
imports: [
CommonModule
]
})
export class LegalOwnerTranslatorModule { }

View File

@@ -0,0 +1,8 @@
import { LegalOwnerPipe } from './legal-owner.pipe';
describe('LegalOwnerPipe', () => {
it('create an instance', () => {
const pipe = new LegalOwnerPipe();
expect(pipe).toBeTruthy();
});
});

View File

@@ -0,0 +1,19 @@
import { Pipe, PipeTransform } from '@angular/core';
@Pipe({
name: 'legalOwner'
})
export class LegalOwnerPipe implements PipeTransform {
transform(legalOwnerKey: string): string {
switch (legalOwnerKey) {
case 'CCLI':
return 'CCLI';
case 'other':
return 'andere';
default:
return '';
}
}
}