Exemplo n.º 1
0
        public Withdraw Add(Withdraw entity)
        {
            if (entity.Id > 0) return entity;
            context.Withdraw.AddObject(entity);

            try
            {
                context.SaveChanges();
            }
            catch (OptimisticConcurrencyException e)
            {
                //An optimistic concurrency violation has occurred in the data source.
                throw new ConcurrencyException(e.Message);
            }

            return entity;
        }
Exemplo n.º 2
0
 public Withdraw Update(Withdraw entity)
 {
     return entity;
 }
Exemplo n.º 3
0
 public void Delete(Withdraw entity)
 {
     context.DeleteObject(entity);
 }