You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
24 lines
607 B
TypeScript
24 lines
607 B
TypeScript
4 years ago
|
import { Component, OnChanges, Input } from '@angular/core';
|
||
|
import { FeesCL } from '../../../shared/models/clModels';
|
||
|
|
||
|
@Component({
|
||
|
selector: 'rtl-cl-fee-info',
|
||
|
templateUrl: './fee-info.component.html',
|
||
|
styleUrls: ['./fee-info.component.scss']
|
||
|
})
|
||
|
export class CLFeeInfoComponent implements OnChanges {
|
||
|
@Input() fees: FeesCL;
|
||
|
totalFees = [{'name': 'Total', 'value': 0}];
|
||
|
maxFeeValue = 100;
|
||
|
|
||
|
constructor() {}
|
||
|
|
||
|
ngOnChanges() {
|
||
|
if(this.fees.feeCollected) {
|
||
|
this.totalFees = [{'name': 'Total', 'value': this.fees.feeCollected}];
|
||
|
Object.assign(this, this.totalFees);
|
||
|
}
|
||
|
}
|
||
|
|
||
|
}
|