Minor Update
git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/tabular-data-widgetx@95484 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
0ac054a52f
commit
cb7af38ecc
|
@ -129,50 +129,12 @@ public class TabularDataXServlet extends HttpServlet {
|
|||
logger.debug("Filters:" + filtersList.size());
|
||||
|
||||
|
||||
/*
|
||||
* // SORTING DIRECTION String sortDirectionParameter = request
|
||||
* .getParameter(ServletParameters.SORTDIR);
|
||||
* logger.trace("sortDirectionParameter: " +
|
||||
* sortDirectionParameter); Direction direction =
|
||||
* (sortDirectionParameter == null) ? Direction.ASC :
|
||||
* Direction.valueOf(sortDirectionParameter);
|
||||
*
|
||||
* // SORTING COLUMN String sortColumn = request
|
||||
* .getParameter(ServletParameters.SORTFIELD);
|
||||
* logger.trace("sortColumn: " + sortColumn);
|
||||
*
|
||||
* // START String startParameter = request
|
||||
* .getParameter(ServletParameters.OFFSET);
|
||||
* logger.trace("startParameter: " + startParameter); int start =
|
||||
* Integer.parseInt(startParameter);
|
||||
*
|
||||
* // LIMIT String limitParameter = request
|
||||
* .getParameter(ServletParameters.LIMIT);
|
||||
* logger.trace("limitParameter: " + limitParameter); int limit =
|
||||
* Integer.parseInt(limitParameter);
|
||||
*/
|
||||
|
||||
DataSourceX dataSource = SessionUtil.getDataSource(
|
||||
request.getSession(), tdSessionId);
|
||||
String json = dataSource.getDataAsJSon(start, limit, sortColumn,
|
||||
direction, filtersList);
|
||||
|
||||
/*
|
||||
* DataSourceX dataSource = SessionUtil.getDataSource(
|
||||
* request.getSession(), tdSessionId); int start =
|
||||
* Integer.parseInt(requestData.getOffset()); int limit =
|
||||
* Integer.parseInt(requestData.getLimit());
|
||||
* ArrayList<SortInformation> sorts = requestData.getSorts();
|
||||
*
|
||||
* Direction direction = Direction.ASC; String sortColumn = null;
|
||||
* for (SortInformation sort : sorts) { direction =
|
||||
* (sort.getSortDir() == null) ? Direction.ASC :
|
||||
* Direction.valueOf(sort.getSortDir()); sortColumn =
|
||||
* sort.getSortField(); }
|
||||
*
|
||||
* String json = dataSource.getDataAsJSon(start, limit, sortColumn,
|
||||
* direction);
|
||||
*/
|
||||
|
||||
response.getOutputStream().write(json.getBytes());
|
||||
response.setStatus(HttpServletResponse.SC_OK);
|
||||
// logger.trace("JSON: "+json);
|
||||
|
|
Loading…
Reference in New Issue