Commit 8fa52fdd authored by igoshin's avatar igoshin Committed by Matija Obreza
Browse files

Bugfixes to filtering

parent 3705c8b3
......@@ -279,7 +279,7 @@ public class ExplorerController extends BaseController {
String[] selectedFilters =new String[0];
jsonFilter=jsonFilter.replaceAll("_",":");
Crop crop=null;
if (StringUtils.isNotBlank(jsonPick)) {
// Cleanup JSON pick
try {
......@@ -297,7 +297,7 @@ public class ExplorerController extends BaseController {
if (filters.get("crop") != null) {
String shortName = filters.get("crop").get(0);
// Add crop descriptors
Crop crop = cropService.getCrop(shortName);
crop = cropService.getCrop(shortName);
if (crop != null) {
List<ParameterCategory> categories = traitService.listCategories();
......@@ -348,8 +348,7 @@ public class ExplorerController extends BaseController {
Page<Accession> accessions = filterService.listAccessions(jsonTree, new PageRequest(page - 1, 50, new Sort("acceNumb")));
_logger.info("Got: " + accessions);
List<GenesysFilterService.GenesysFilter> additionalFilters = filterService.selectFilters(selectedFilters);
List<GenesysFilterService.GenesysFilter> additionalFilters = filterService.selectFilters(crop,selectedFilters);
List<GenesysFilterService.GenesysFilter> availableFilters =filterService.listAvailableFilters();
List<GenesysFilterService.GenesysFilter> allFilters=new ArrayList<>();
......
......@@ -420,7 +420,9 @@
jsonValue = jsonData[key];
}
if (!isNaN(inputValue1) && !isNaN(inputValue2)) {
var notNull=inputValue1!=''&&inputValue2!='';
if (!isNaN(inputValue1) && !isNaN(inputValue2)&&notNull) {
if (inputValue1 == inputValue2) {
jsonValue.push(parseFloat(inputValue1));
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment