Пример #1
0
 public void Modify(TransactionModifyArgs args)
 {
     TransactionName   = args.TransactionName;
     DebitAccountId    = args.DebitAccountId;
     CreditAccountId   = args.CreditAccountId;
     TransactionAmount = args.TransactionAmount;
     IssuedTime        = TimeUnit.FromDate(args.IssuedTime);
 }
Пример #2
0
        public static Transaction Create(TransactionCreateArgs args)
        {
            Transaction transaction = new Transaction
            {
                TransactionId     = Guid.NewGuid(),
                TransactionCode   = RandomExpress.RandomizeString(16),
                TransactionName   = args.TransactionName,
                DebitAccountId    = args.DebitAccountId,
                CreditAccountId   = args.CreditAccountId,
                TransactionAmount = args.TransactionAmount,
                IssuedTime        = TimeUnit.FromDate(args.IssuedTime)
            };

            return(transaction);
        }