X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=src%2Fmkws-widget-main.js;h=c161686e0940b902ece94b5edf12d6b9c2700d72;hb=7c5de3bdff3d3a5eea813c0ed71632480d375a36;hp=0ee99f3c8973cc11bd246a53e3179fe1cf5073e4;hpb=36721667730b5d8aae5b6df304f69d96f2c1d21d;p=mkws-moved-to-github.git diff --git a/src/mkws-widget-main.js b/src/mkws-widget-main.js index 0ee99f3..c161686 100644 --- a/src/mkws-widget-main.js +++ b/src/mkws-widget-main.js @@ -22,6 +22,7 @@ mkws.registerWidgetType('targets', function() { cur.id = data[i].id; cur.hits = data[i].hits; cur.diagnostic = data[i].diagnostic; + cur.message = data[i].message; cur.records = data[i].records; cur.state = data[i].state; cleandata.push(cur); @@ -55,7 +56,7 @@ mkws.registerWidgetType('pager', function() { output.found = data.total; //client indexes pages from 1 but pz2 from 0 - var onsides = 6; + var onsides = 5; var pages = Math.ceil(that.team.totalRecordCount() / that.team.perpage()); var currentPage = that.team.currentPage(); @@ -105,7 +106,6 @@ mkws.registerWidgetType('details', function() { that.node.html(template(data)); } }); - that.autosearch(); }); mkws.registerWidgetType('records', function() { @@ -130,8 +130,9 @@ mkws.registerWidgetType('records', function() { } } var template = team.loadTemplate(that.config.template || "records"); - var targs = $.extend({}, {"hits": data.hits}, that.config.template_vars); - that.node.html(template(targs)); + var summaryPartial = team.loadTemplate("summary"); + var tdata = $.extend({}, {"hits": data.hits}, that.config.template_vars); + that.node.html(template(tdata, {"partials":{"summary":summaryPartial}})); }); that.autosearch();