Skip to content
Snippets Groups Projects
Commit 5f95c2d4 authored by Christopher Schankula's avatar Christopher Schankula :earth_africa:
Browse files

proper search for map.jsp

parent 3d0208a7
No related branches found
No related tags found
No related merge requests found
......@@ -6,11 +6,14 @@
<%
// Sample result data containing an iterable of records
TrawlExpert te = (TrawlExpert)request.getServletContext().getAttribute("trawl");
BasicSearchResult result = te.rangeSearch(2, 1960, 2016);
JSONParser parser = new JSONParser();
JSONObject req = (JSONObject) parser.parse(request.getReader().readLine());
Integer taxonId = (int) (long) req.get("taxId");
Integer yearLo = (int) (long) req.get("yearF");
Integer yearHi = (int) (long) req.get("yearT");
BasicSearchResult result = te.rangeSearch(taxonId, yearLo, yearHi);
// Initialize JSON Object and Arrays
JSONObject js = new JSONObject();
......@@ -30,7 +33,6 @@
dateobj.put("year",r.getDate().getYear());
dateobj.put("month",r.getDate().getMonth());
dateobj.put("day",r.getDate().getDay());
date.add(r.getDate());
count.add(r.getCount());
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment