Ejemplo n.º 1
0
        public Order CreateNewOrder(Order order)
        {
            DAL.Entity.Order ord = new DAL.Entity.Order
            {
                Id         = order.Id,
                ClientId   = order.ClientId,
                PeymentId  = order.PeymentId,
                DeliveryId = order.DeliveryId,
                Comment    = order.Comment
            };
            if (ord != null)
            {
                ord = _dal.CreateNewOrder(ord);
                BLL.Models.Order ord_new = new BLL.Models.Order
                {
                    Id         = ord.Id,
                    ClientId   = ord.ClientId,
                    PeymentId  = ord.PeymentId,
                    DeliveryId = ord.DeliveryId,
                    Comment    = ord.Comment
                };

                return(ord_new);
            }
            else
            {
                return(null);
            }
        }