public static List<Problema> ListAll() { FiltroProblema f = new FiltroProblema(); f.OrderBY = " order by DESCRIPCION "; return List(f); }
public static List<Problema> List(FiltroProblema f) { List<Problema> resulList = new List<Problema>(); try { ProblemaDS dataservice = new ProblemaDS(); DataSet listado = dataservice.List(f); if (listado.Tables.Count > 0) { foreach (DataRow d in listado.Tables[0].Rows) { Problema p = new Problema(); ORM(p, d); resulList.Add(p); } } } catch (Exception ex) { throw ex; } return resulList; }