src/app/components/payments/payment-payfrom-label/payment-payfrom-label.component.ts
selector | app-payment-payfrom-label |
styleUrls | ./payment-payfrom-label.component.css |
templateUrl | ./payment-payfrom-label.component.html |
Methods |
Inputs |
constructor(materialService: MaterialService)
|
||||||
Parameters :
|
model | |
Type : Payment
|
|
payment | |
Type : Payment
|
|
ngOnInit |
ngOnInit()
|
Returns :
void
|
import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';
import 'rxjs/add/operator/filter';
import { Payment } from '../../../models';
import { MaterialService } from '../../../providers';
@Component({
selector: 'app-payment-payfrom-label',
templateUrl: './payment-payfrom-label.component.html',
styleUrls: ['./payment-payfrom-label.component.css']
// host: {class: 'Payment'}
})
export class PaymentPayFromLabelComponent implements OnInit {
@Input() payment: Payment;
@Input() model: Payment;
constructor(private materialService: MaterialService) {}
ngOnInit() {
this.materialService.render();
}
}
<span id="paymentFromLabel">
<span *ngIf="!payment.payFromAccountDisplayName || payment.payFromAccountDisplayName.length < 1">{{payment.payFromAccountName}}</span>
<span *ngIf="payment.payFromAccountDisplayName && payment.payFromAccountDisplayName.length > 0">{{payment.payFromAccountDisplayName}}</span>
- {{payment.payFromAccount | mask}}
</span>
./payment-payfrom-label.component.css