1 import { Pipe, PipeTransform } from '@angular/core';
3 import _ from 'lodash';
8 export class MgrSummaryPipe implements PipeTransform {
9 transform(value: any): any {
18 let activeCount: number;
19 const activeTitleText = _.isUndefined(value.active_name)
21 : `${$localize`active daemon`}: ${value.active_name}`;
22 // There is always one standbyreplay to replace active daemon, if active one is down
23 if (activeTitleText.length > 0) {
26 const standbyCount = value.standbys.length;
27 const totalCount = activeCount + standbyCount;