private TopoViewModel InitModel() { var model = new TopoViewModel(); model.Countries = _trailDataService.ListCountries().OrderBy(x => x.Name); model.Trails = _trailDataService.ListTrails(); model.FirstDate = model.Trails.Min(x => x.StartLocal); model.LastDate = model.Trails.Max(x => x.StartLocal); return(model); }
/// <summary> /// Resets the current TopoTrailInfo GPX data file cache and reloads from disk /// </summary> public ActionResult Refresh() { ServiceConfig.ResetTopoTrail(); return(Redirect(TopoViewModel.GetTopoUrl())); }