internal List <ProductosOE> listarProductosOE(int id) { ProductosOE ot = null; List <ProductosOE> list = new List <ProductosOE>(); using (ProyectoEntities db = new ProyectoEntities()) { var query = (from p in db.ProductosOE where p.IdOrdenE.Equals(id) select new { IdProdOE = p.IdProdOE, POE = p.POE, IdOrdenE = p.IdOrdenE, }).ToList(); if (query != null) { foreach (var r in query) { ot = new ProductosOE(r.IdProdOE, r.POE, r.IdOrdenE); list.Add(ot); } } } return(list); }
public ProductosOE getDataType() { ProductosOE data = new ProductosOE(); data.IdProdOE = IdProdOE; data.POE = POE; data.IdOrdenE = IdOrdenE; return(data); }