public static MaquinariaList GetChildList(ExpedientInfo parent, bool childs) { CriteriaEx criteria = Maquinaria.GetCriteria(Maquinaria.OpenSession()); criteria.Query = SELECT(parent); criteria.Childs = childs; MaquinariaList list = DataPortal.Fetch <MaquinariaList>(criteria); list.CloseSession(); return(list); }
public static MaquinariaList GetList(bool childs) { CriteriaEx criteria = Maquinaria.GetCriteria(Maquinaria.OpenSession()); criteria.Childs = childs; criteria.Query = MaquinariaList.SELECT(); MaquinariaList list = DataPortal.Fetch <MaquinariaList>(criteria); CloseSession(criteria.SessionCode); return(list); }