Disambiguate singleton and multiple record templates.
[mkws-moved-to-github.git] / src / mkws-widget-main.js
index 03eba2e..5106839 100644 (file)
@@ -134,7 +134,8 @@ mkws.registerWidgetType('Records', function() {
       }
     }
     var template = team.loadTemplate(that.config.template || "Records");
-    that.node.html(template({"hits": data.hits}));
+    var targs = $.extend({}, {"hits": data.hits}, that.config.template_vars);
+    that.node.html(template(targs));
   });
 
   that.autosearch();