예제 #1
0
        public async Task <Guid> Create()
        {
            var account = new Models.Account
            {
                AccountId = Guid.NewGuid(),
                DateAdded = DateTime.UtcNow
            };

            _unitOfWork.AccountRepository.Register(account);
            await _unitOfWork.CommitAsync();

            return(account.AccountId);
        }
예제 #2
0
 public async Task Update(Models.Account account)
 {
     _unitOfWork.AccountRepository.Update(account);
     await _unitOfWork.CommitAsync();
 }