[facets] reload breadcrumbs on facets search stable
authorSylvain Thénault <sylvain.thenault@logilab.fr>
Wed, 26 Aug 2009 10:06:47 +0200
branchstable
changeset 3008 094c597c1d01
parent 3007 a15e982aa9a3
child 3009 3deb0fa95761
[facets] reload breadcrumbs on facets search
web/data/cubicweb.facets.js
--- a/web/data/cubicweb.facets.js	Wed Aug 26 10:06:17 2009 +0200
+++ b/web/data/cubicweb.facets.js	Wed Aug 26 10:06:47 2009 +0200
@@ -67,7 +67,8 @@
 	copyParam(zipped, extraparams, 'divid');
 	copyParam(zipped, extraparams, 'subvid');
 	// paginate used to know if the filter box is acting, in which case we
-	// want to reload action box to match current selection
+	// want to reload action box to match current selection (we don't want
+	// this from a table filter)
 	replacePageChunk(divid, rql, vid, extraparams, true, function() {
 	  jQuery(CubicWeb).trigger('facets-content-loaded', [divid, rql, vid, extraparams]);
 	});
@@ -78,6 +79,10 @@
 	    if (jQuery('#edit_box').length) {
 		reloadComponent('edit_box', rql, 'boxes', 'edit_box');
 	    }
+	    if (jQuery('#breadcrumbs').length) {
+		log('reloading breadcrumbs!', rql);
+		reloadComponent('breadcrumbs', rql, 'components', 'breadcrumbs');
+	    } else { log('breadcrumbs not found!'); }
 	}
 	var d = asyncRemoteExec('filter_select_content', toupdate, rql);
 	d.addCallback(function(updateMap) {