Exemplo n.º 1
0
        public Guid AddOrderStatus(OrderStatusDTO orderStatus)
        {
            OrderStatus dataModel = new OrderStatus();

            orderStatus.CopyTo(dataModel);
            _context.OrderStatuses.Add(dataModel);
            _context.SaveChanges();
            return(dataModel.Id);
        }
Exemplo n.º 2
0
        public void UpdateOrderStatus(OrderStatusDTO orderStatus)
        {
            OrderStatus dataModel = new OrderStatus();

            orderStatus.CopyTo(dataModel);
            _context.Entry(dataModel).State = System.Data.Entity.EntityState.Modified;
            _context.SaveChanges();
            return;
        }