use of com.emc.metalnx.core.domain.entity.DataGridSpecificQuery in project metalnx-web by irods-contrib.
the class SpecificQueryController method showAddForm.
@RequestMapping(value = "/add/", method = RequestMethod.GET)
public String showAddForm(Model model) {
model.addAttribute("specificQueryForm", new DataGridSpecificQuery());
model.addAttribute("requestMapping", URLMap.URL_ADD_SPECIFIC_QUERY);
return "specificqueries/form";
}
use of com.emc.metalnx.core.domain.entity.DataGridSpecificQuery in project metalnx-web by irods-contrib.
the class SpecificQueryController method removeSpecificQuery.
@RequestMapping(value = "/remove/{specAlias}/", method = RequestMethod.GET)
public String removeSpecificQuery(Model model, @PathVariable String specAlias) throws DataGridConnectionRefusedException {
DataGridSpecificQuery specQuery = specificQueryService.findByAlias(specAlias);
specificQueryService.removeSpecificQueryByAlias(specQuery);
return "specificqueries/index";
}
use of com.emc.metalnx.core.domain.entity.DataGridSpecificQuery in project metalnx-web by irods-contrib.
the class SpecificQueryController method executeQuery.
@RequestMapping(value = "/execute/{specAlias}/", method = RequestMethod.GET)
public String executeQuery(@PathVariable String specAlias, Model model) throws DataGridConnectionRefusedException {
DataGridSpecificQuery specQuery = specificQueryService.findByAlias(specAlias);
SpecificQueryResultSet results = specificQueryService.executeSpecificQuery(specQuery, irodsZoneName);
int totalRecords = results.getTotalRecords();
model.addAttribute("totalRecords", totalRecords);
model.addAttribute("results", results);
return "specificqueries/results";
}
use of com.emc.metalnx.core.domain.entity.DataGridSpecificQuery in project metalnx-web by irods-contrib.
the class SpecificQueryController method showModifyForm.
@RequestMapping(value = "/modify/{specAlias}/", method = RequestMethod.GET)
public String showModifyForm(Model model, @PathVariable String specAlias) throws DataGridConnectionRefusedException {
DataGridSpecificQuery specQuery = specificQueryService.findByAlias(specAlias);
model.addAttribute("specificQueryForm", specQuery);
model.addAttribute("requestMapping", URLMap.URL_MODIFY_SPECIFIC_QUERY);
return "specificqueries/form";
}
use of com.emc.metalnx.core.domain.entity.DataGridSpecificQuery in project metalnx-web by irods-contrib.
the class SpecificQueryServiceImpl method createDataGridSpecificQuery.
private final DataGridSpecificQuery createDataGridSpecificQuery(SpecificQueryDefinition specificQueryFromIrods) {
DataGridSpecificQuery newQuery = new DataGridSpecificQuery();
newQuery.setAlias(specificQueryFromIrods.getAlias());
newQuery.setQuery(specificQueryFromIrods.getSql());
return newQuery;
}
Aggregations