public static List <State> GetStates() { List <State> state; using (CustomClearviewEntities ctx = new CustomClearviewEntities()) { StateRepository repo = new StateRepository(ctx); state = repo.All(s => s.StateCode, System.Data.SqlClient.SortOrder.Ascending); } return(state); }
public List <DAL.Entity.State> GetAllState() { try { return(_IStateRepository.All().Where(w => w.DeletedFlag == false).ToList()); } catch (Exception exception) { exception.Log(); return(null); } }
public List <State> All() { return(StateRepository.All()); }