예제 #1
0
        public void CreateAInvalidOrderPlataformTest()
        {
            Order order = new Order();
            order.Plataform = "PC";

            Validator.Validate(order);
        }
예제 #2
0
 public Order Update(Order order)
 {
     DbEntityEntry entry = context.Entry(order);
     entry.State = EntityState.Modified;
     context.SaveChanges();
     return order;
 }
예제 #3
0
        public void CreateAInvalidOrderNameTest()
        {
            Order order = new Order();

            Validator.Validate(order);
        }
예제 #4
0
 public Order Save(Order order)
 {
     var newOrder = context.Orders.Add(order);
     context.SaveChanges();
     return newOrder;
 }