From a10c818aaf2f151a1da58368e8dff6e701522b46 Mon Sep 17 00:00:00 2001 From: Brian Ferris Date: Tue, 17 Apr 2012 09:05:30 +0200 Subject: [PATCH] Issue #5: Improve the Utility of the Trip Problem Report Admin Interface Fix trip problem label auto-suggest bug. --- .../content/admin/problems/trip-problem-report.jspx | 7 +------ .../webapp/js/oba-admin-problems-trip-problem-reports.js | 6 ++++++ 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/onebusaway-webapp/src/main/webapp/WEB-INF/content/admin/problems/trip-problem-report.jspx b/onebusaway-webapp/src/main/webapp/WEB-INF/content/admin/problems/trip-problem-report.jspx index d9d09b442..c3209cf55 100644 --- a/onebusaway-webapp/src/main/webapp/WEB-INF/content/admin/problems/trip-problem-report.jspx +++ b/onebusaway-webapp/src/main/webapp/WEB-INF/content/admin/problems/trip-problem-report.jspx @@ -34,6 +34,7 @@ var data = {}; data.tripProblemReport = ; data.vehicleLocationRecords = ; + data.problemLabels = ; jQuery(document).ready(function() { oba_admin_problems_trip_problem_reports(data); } ); @@ -184,12 +185,6 @@ - -
diff --git a/onebusaway-webapp/src/main/webapp/js/oba-admin-problems-trip-problem-reports.js b/onebusaway-webapp/src/main/webapp/js/oba-admin-problems-trip-problem-reports.js index 6df7f687a..e2d4ae92b 100644 --- a/onebusaway-webapp/src/main/webapp/js/oba-admin-problems-trip-problem-reports.js +++ b/onebusaway-webapp/src/main/webapp/js/oba-admin-problems-trip-problem-reports.js @@ -14,6 +14,12 @@ * limitations under the License. */ function oba_admin_problems_trip_problem_reports(data) { + + var labelElement = jQuery("input#trip-problem-report_label"); + labelElement.autocomplete({ + source: data.problemLabels + }); + var mapElement = jQuery("#tripProblemReportMap"); var map = OBA.Maps.map(mapElement); var infoWindow = new google.maps.InfoWindow();