Exemplo n.º 1
0
        public static DetalleLibroVentas GetDetalleLibroVentasById(int pk)
        {
            AppSales.DAL.DetalleLibroVentasDSTableAdapters.DetalleLibroVentasTableAdapter objDataSet = new AppSales.DAL.DetalleLibroVentasDSTableAdapters.DetalleLibroVentasTableAdapter();
            DetalleLibroVentasDS.DetalleLibroVentasDataTable dtDetalleLibroVentas = objDataSet.GetDetalleLibroVentaByID(pk);
            DetalleLibroVentas objDetalleLibroVentas = rowToDto(dtDetalleLibroVentas[0]);

            return(objDetalleLibroVentas);
        }
Exemplo n.º 2
0
        public static List <DetalleLibroVentas> GetDetalleLibroVentasByIdLibro(int pklibro)
        {
            List <DetalleLibroVentas> listadeDetalleLibroVentas = new List <DetalleLibroVentas>();

            AppSales.DAL.DetalleLibroVentasDSTableAdapters.DetalleLibroVentasTableAdapter objDataSet = new AppSales.DAL.DetalleLibroVentasDSTableAdapters.DetalleLibroVentasTableAdapter();
            DetalleLibroVentasDS.DetalleLibroVentasDataTable dtDetalleLibroVentas = objDataSet.GetDetalleLibroVentaByIdLibro(pklibro);
            foreach (DetalleLibroVentasDS.DetalleLibroVentasRow row in dtDetalleLibroVentas)
            {
                DetalleLibroVentas objDetalleLibroVentas = rowToDto(row);
                listadeDetalleLibroVentas.Add(objDetalleLibroVentas);
            }
            return(listadeDetalleLibroVentas);
        }