X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=src%2Fmkws-widget-main.js;h=c3eac87ffa036716c512a5dc1c05dc70f94b44da;hb=e215340ab13b641a83b5f6aa1a027b81b6566670;hp=96937df162060f3ffd233bfcce9cd0b676157c20;hpb=0d9aa1a4cc69782eb4037cf11fe9012c6a362b6c;p=mkws-moved-to-github.git
diff --git a/src/mkws-widget-main.js b/src/mkws-widget-main.js
index 96937df..c3eac87 100644
--- a/src/mkws-widget-main.js
+++ b/src/mkws-widget-main.js
@@ -7,10 +7,7 @@ mkws.registerWidgetType('Targets', function() {
var that = this;
var M = mkws.M;
- $(this.node).html('\
-
\
-No information available yet.\
-
');
+ $(this.node).html('No information available yet.');
$(this.node).css("display", "none");
this.team.queue("targets").subscribe(function(data) {
@@ -31,8 +28,7 @@ No information available yet.\
}
table += '';
- var subnode = $(that.node).children('.mkwsBytarget');
- subnode.html(table);
+ $(that.node).html(table);
});
});
@@ -44,11 +40,10 @@ mkws.registerWidgetType('Stat', function() {
this.team.queue("stat").subscribe(function(data) {
if (that.node.length === 0) alert("huh?!");
- $(that.node).html('' + M('Status info') + '' +
- ' -- ' +
- '' + M('Active clients') + ': ' + data.activeclients + '/' + data.clients + '' +
+ $(that.node).html(' -- ' +
+ '' + M('Active clients') + ': ' + data.activeclients + '/' + data.clients + '' +
' -- ' +
- '' + M('Retrieved records') + ': ' + data.records + '/' + data.hits + '');
+ M('Retrieved records') + ': ' + data.records + '/' + data.hits);
});
});
@@ -89,7 +84,7 @@ mkws.registerWidgetType('Pager', function() {
for(var i = firstClkbl; i <= lastClkbl; i++) {
var numLabel = i;
if(i == currentPage)
- numLabel = '' + i + '';
+ numLabel = '' + i + '';
middle += ' '
+ numLabel + ' ';
@@ -127,7 +122,7 @@ mkws.registerWidgetType('Records', function() {
var hit = data.hits[i];
that.team.queue("record").publish(hit);
var divId = team.recordElementId(hit.recid[0]);
- html.push('', renderSummary(hit), '
');
+ html.push('', renderSummary(hit), '
');
// ### At some point, we may be able to move the
// m_currentRecordId and m_currentRecordData members
// from the team object into this widget.
@@ -161,13 +156,13 @@ mkws.registerWidgetType('Navi', function() {
filters.visitTargets(function(id, name) {
if (text) text += " | ";
- text += M('source') + ': ' + name + '';
});
filters.visitFields(function(field, value) {
if (text) text += " | ";
- text += M(field) + ': ' + value + '';
});
@@ -238,7 +233,7 @@ mkws.registerWidgetType('Search', function() {
mkws.registerWidgetType('SearchForm', function() {
- var team = this.team;
+ var team = this.team;
$(this.node).submit(function() {
var val = team.widget('Query').value();
team.newSearch(val);
@@ -279,7 +274,7 @@ mkws.registerWidgetType('Ranking', function() {
var that = this;
var M = mkws.M;
- var s = '