return html;
};
-Drupal.theme.mkdruFacet = function (terms, facet, max) {
+Drupal.theme.mkdruFacet = function (terms, facet, max, selections) {
var html = "";
for (var i = 0; i < terms.length && i < max; i++ ) {
var term = terms[i];
if (term.selected) html += "</strong>";
html += '</a><span> (' + terms[i].freq
+ ')</span><br/>';
-
+ }
+ var sel = selections[facet];
+ if (terms.length == 0 && sel && sel.length) {
+ for (var i=0; i<sel.length; i++) {
+ if (sel[i]) {
+ html += '<a class="cross" href="'+mkdru.removeLimit(facet, sel[i])
+ + '"><strong>'+sel[i]+'</strong></a><span> (0)</span><br/>';
+ }
+ }
}
return html;
};