changeset 752:639e82e2089e

remove and hide filters when switching between modes
author Dustin Demuth <dustin@intevation.de>
date Tue, 28 Apr 2015 16:54:25 +0200
parents 704bb359c0fe
children 4dd0c645ea8b
files app/controller/Filter.js app/controller/ProbenPlanungSwitcher.js
diffstat 2 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/app/controller/Filter.js	Tue Apr 28 16:03:59 2015 +0200
+++ b/app/controller/Filter.js	Tue Apr 28 16:54:25 2015 +0200
@@ -203,7 +203,7 @@
             searchParams[filter.getName()] = value;
         }
         // Retrieve the mode
-        var modes = element.up('panel[name=main]').down('probenplanungswitcher').getChecked();
+        var modes = element.up('panel[name=main]').down('radiogroup').getChecked();
         var sname = modes[0].inputValue;
 
         if (sname === 'ProbenList') {
--- a/app/controller/ProbenPlanungSwitcher.js	Tue Apr 28 16:03:59 2015 +0200
+++ b/app/controller/ProbenPlanungSwitcher.js	Tue Apr 28 16:54:25 2015 +0200
@@ -41,7 +41,9 @@
     switchStores: function(field) {
         var cbox = field.up('probenplanungswitcher').up().down('combobox');
         var resultGrid = field.up('panel[name=main]').down('filterresultgrid');
-
+        filters = field.up('panel[name=main]').down('fieldset[name=filtervariables]');
+        filters.removeAll();
+        filters.hide();
         var sname = 'Lada.store.ProbeQueries';
         if (field.inputValue === 'MessprogrammeList' && cbox) {
             sname = 'Lada.store.MessprogrammQueries';

http://lada.wald.intevation.org