Exemplo n.º 1
0
        /// <inheritdoc></inheritdoc>
        public void Delete(DalAccount dalAccount)
        {
            var account = dalAccount.ToOrmAccount();

            account = _context.Set <OrmAccount>().Single(acc => acc.Id == account.Id);
            _context.Set <OrmAccount>().Remove(account);
        }
Exemplo n.º 2
0
        public void Create(DalAccount dalAccount)
        {
            if (ReferenceEquals(dalAccount, null))
            {
                throw new ArgumentException(nameof(dalAccount));
            }

            var account = dalAccount.ToOrmAccount();

            SetTypeAndOwner(account);
            context.Set <Account>().Add(account);
        }
Exemplo n.º 3
0
        /// <inheritdoc></inheritdoc>
        public void Create(DalAccount dalAccount)
        {
            var account = dalAccount.ToOrmAccount();

            _context.Set <OrmAccount>().Add(account);
        }