private Decimal GetSubLevelSum(fmCPRRepaymentTaskLine parentLine) { Decimal sum = 0; foreach (fmCPRRepaymentTaskLine subLine in parentLine.Lines) { sum += subLine.RequestSum; } return(sum); }
public fmCPRRepaymentTaskLine(Session session, int level, fmCPRPaymentRequestObligation levelObject, fmCPRPaymentRequest paymentRequest, DateTime paymentDate, Decimal operationJournalSum, Decimal requestSum, fmCPRRepaymentTask repaymentTask, fmCPRRepaymentTaskLine parentLine) //, Boolean isCashFlowRegister) : base(session) { _PaymentRequest = paymentRequest; _PaymentDate = paymentDate; _OperationJournalSum = operationJournalSum; _RequestSum = requestSum; _RepaymentTask = repaymentTask; _Level = level; _LevelObject = levelObject; //_IsCashFlowRegister = isCashFlowRegister; if (parentLine != null) { parentLine.Lines.Add(this); } }