public static string GetRoute2DefaultDriverID(string routeID) { var first = ROUTE2.Find(x => x.RouteID == routeID).FirstOrDefault() ?? new ROUTE2 { RouteID = routeID, DefaultDriverID = "XX" }; return first.DefaultDriverID; }
public static ROUTE2 GetRoute2(string item) { return(ROUTE2.Find(x => x.RouteID == item).FirstOrDefault() ?? new ROUTE2 { RouteID = item, RouteName = "NOT FOUND" }); }
public static string GetRoute2RouteName(string routeID) { var first = ROUTE2.Find(x => x.RouteID == routeID).FirstOrDefault() ?? new ROUTE2 { RouteID = routeID, RouteName = "NOT SET" }; return(first.RouteName); }
public static int GetRoute2Count() { return ROUTE2.All().Count(); }
public static List<ROUTE2> GetRoute2List() { return (from r in ROUTE2.All() orderby r.RouteID select r).ToList(); }