Example #1
0
 internal CRPosting(CRTransaction transaction, InstrumentType instrumentType,
                    IFinancialAccount account, decimal amount) {
   this.transaction = transaction;
   this.instrumentType = instrumentType;
   this.instrumentId = account.Id;
   this.instrumentAmount = amount;
   if (this.transaction.TransactionType.UniqueCode.StartsWith("Input.")) {
     this.inputAmount = amount;
   } else {
     this.outputAmount = amount;
   }
 }
Example #2
0
    public CRPosting AppendPosting(InstrumentType instrumentType, IFinancialAccount account, decimal amount) {
      CRPosting posting = new CRPosting(this, instrumentType, account, amount);
      this.Postings.Add(posting);

      return posting;
    }