Exemplo n.º 1
0
        private TotalsLine CreateTotalsLine(IEnumerable <JournalRecord> journalRecords)
        {
            var result = new TotalsLine();

            result.Quantity = journalRecords.Count();
            var duration = journalRecords.Aggregate(new TimeSpan(), (acc, jr) => acc + jr.Duration);

            result.Duration = duration;
            var normative = journalRecords.Aggregate(new TimeSpan(), (acc, jr) => acc + jr.Normative);

            result.Normative = normative;
            result.Deviation = (duration - normative);
            return(result);
        }
Exemplo n.º 2
0
 protected TotalsLineVM(TotalsLine model)
 {
     Model = model;
 }
Exemplo n.º 3
0
 public TotalLineForMonth(TotalsLine model) : base(model)
 {
 }