public JsonResult Remove(string title) { var route = _tripRouteRepository.GetByTitle(title); if (route == null) { return(Json(false)); } _tripRouteRepository.Remove(route); return(Json(true)); }
public JsonResult Remove(long id) { var route = _tripRouteRepository.GetById(id); if (route == null) { return(Json(false)); } _busRepository.UpdateBusRoute(route); _tripRouteRepository.Remove(route); return(Json(true)); }