Beispiel #1
0
 public static FundingBalance AddFunds(Model.User.User from, FundingBalance balance, decimal amount)
 {
     FundingTransactionRepository.Create(
         from, balance.entity_id, balance.entity_type, amount, balance.currency_type
         );
     return(balance.UpdateBalance(balance.balance + amount));
 }
Beispiel #2
0
 public static FundingBalance AddFunds(FundingBalance balance, Invoice invoice)
 {
     FundingTransactionUtils.CreateTxFromInvoice(invoice);
     return(balance.UpdateBalance(invoice.amount));
 }