Пример #1
0
        /// <summary>
        /// Find method.
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        public OrderDetail Find(int id)
        {
            var orderDetailDac = new OrderDetailDAC();
            var result         = orderDetailDac.SelectById(id);

            return(result);
        }
Пример #2
0
        public List <OrderDetail> FindByOrderId(int on)
        {
            var OrderDetailDac = new OrderDetailDAC();
            var result         = OrderDetailDac.SelectByOrderId(on);

            return(result);
        }
Пример #3
0
        /// <summary>
        /// FindAll method.
        /// </summary>
        /// <returns></returns>
        public List <OrderDetail> All()
        {
            var orderDetailDac = new OrderDetailDAC();
            var result         = orderDetailDac.Select();

            return(result);
        }
        public void BorrarOrderDetail(int id)
        {
            var orderdetailDAC = new OrderDetailDAC();

            orderdetailDAC.DeleteById(id);
            //db.Delete(id);
        }
        public OrderDetail GetOrderDetail(int id)
        {
            //return db.GetById(id);
            var orderdetailDAC = new OrderDetailDAC();
            var result         = orderdetailDAC.SelectById(id);

            return(result);
        }
        public OrderDetail AgregarOrderDetail(OrderDetail orderdetail)
        {
            //return db.Create(orderdetail);
            OrderDetail result         = default(OrderDetail);
            var         orderdetailDAC = new OrderDetailDAC();

            result = orderdetailDAC.Create(orderdetail);
            return(result);
        }
        public List <OrderDetail> ListarOrderDetail()
        {
            // return db.Get();

            List <OrderDetail> result = default(List <OrderDetail>);
            var orderdetailDAC        = new OrderDetailDAC();

            result = orderdetailDAC.Select();
            return(result);
        }
Пример #8
0
        /// <summary>
        /// Update method.
        /// </summary>
        /// <param name="orderDetail"></param>
        public void Edit(OrderDetail orderDetail)
        {
            var orderDetailDac = new OrderDetailDAC();

            orderDetailDac.UpdateById(orderDetail);
        }
Пример #9
0
        /// <summary>
        /// Delete method.
        /// </summary>
        /// <param name="id"></param>
        public void Remove(int id)
        {
            var orderDetailDac = new OrderDetailDAC();

            orderDetailDac.DeleteById(id);
        }
Пример #10
0
        /// <summary>
        /// Add method.
        /// </summary>
        /// <param name="orderDetail"></param>
        /// <returns></returns>
        public OrderDetail Add(OrderDetail orderDetail)
        {
            var orderDetailDac = new OrderDetailDAC();

            return(orderDetailDac.Create(orderDetail));
        }
        public OrderDetail EditarOrderDetail(OrderDetail orderdetail)
        {
            var orderdetailDAC = new OrderDetailDAC();

            return(orderdetailDAC.UpdateById(orderdetail));
        }