예제 #1
0
        public RouteCollections SelectList()
        {
            RouteCollections collection = new RouteCollections();
            IDataReader      Reader     = DataAccess.SelectList();

            while (Reader.Read())
            {
                RouteInfo routeinfo = new RouteInfo();
                routeinfo.RouteID          = Convert.ToString(Reader["RouteID"]);
                routeinfo.RouteCode        = Convert.ToString(Reader["RouteCode"]);
                routeinfo.RouteName        = Convert.ToString(Reader["RouteName"]);
                routeinfo.FromLocationID   = Convert.ToString(Reader["FromLocationID"]);
                routeinfo.FromLocationName = Convert.ToString(Reader["LocationName"]);
                routeinfo.ToLocationID     = Convert.ToString(Reader["ToLocationID"]);
                routeinfo.ToLocationName   = Convert.ToString(Reader["LocationName"]);
                collection.Add(routeinfo);
            }
            Reader.Close();
            return(collection);
        }
예제 #2
0
 public void UpdateByRouteID(RouteInfo routeInfo)
 {
     DataAccess.UpdateByRouteID(routeInfo.RouteID, routeInfo.RouteCode, routeInfo.RouteName, routeInfo.FromLocationID, routeInfo.ToLocationID);
 }
예제 #3
0
 public void Insert(RouteInfo routeInfo)
 {
     DataAccess.Insert(routeInfo.RouteID, routeInfo.RouteCode, routeInfo.RouteName, routeInfo.FromLocationID, routeInfo.ToLocationID);
 }