瀏覽代碼

HUE-186. Add functionality to DataGroupToggle
* Add element.show/element.hide to selectHandler *

Marcus McLaughlin 15 年之前
父節點
當前提交
2fcc85f80d
共有 1 個文件被更改,包括 5 次插入1 次删除
  1. 5 1
      desktop/core/static/js/Source/BehaviorFilters/Behavior.DataGroupToggle.js

+ 5 - 1
desktop/core/static/js/Source/BehaviorFilters/Behavior.DataGroupToggle.js

@@ -46,7 +46,11 @@ Behavior.addGlobalFilters({
                                 return;
                         }
                         sections.each(function(section) {
-                                section.setStyle('display', show.contains(section) ? section.get('data', 'display') : 'none');
+                                if(show.contains(section)) {
+                                        section.show();
+                                } else {
+                                        section.hide();
+                                }
                         });
                 };
                 var linkHandler = function(event) {