From 68b8b8ecd71e795468bbd599ecfc078601140394 Mon Sep 17 00:00:00 2001 From: Mike Taylor Date: Mon, 12 Jan 2015 17:32:51 +0000 Subject: [PATCH] Part of MKWS-348. New file src/mkws-widget-ru.js, identical to old version in ../examples/htdocs --- src/mkws-widget-ru.js | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 src/mkws-widget-ru.js diff --git a/src/mkws-widget-ru.js b/src/mkws-widget-ru.js new file mode 100644 index 0000000..b616b33 --- /dev/null +++ b/src/mkws-widget-ru.js @@ -0,0 +1,33 @@ +mkws.registerWidgetType('reference-universe', function() { + if (!this.config.target) this.config.target = 'paratext_ruprime'; + if (!this.config.perpage) this.config.perpage = 5; + if (!this.config.sort) this.config.sort = "position"; + this.team.registerTemplate('reference-universe', '\ +

Results from Reference Universe

\ +\ +'); + + var that = this; + var template = that.team.loadTemplate(that.config.template || "reference-universe"); + this.team.queue("records").subscribe(function(data) { + that.node.html(template(data)); + }); + that.autosearch(); +}); + -- 1.7.10.4