projects
/
mkws-moved-to-github.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Emit each facet's title using the template named facetTitle-NAME,
[mkws-moved-to-github.git]
/
src
/
mkws-team.js
diff --git
a/src/mkws-team.js
b/src/mkws-team.js
index
633052f
..
02dc5ac
100644
(file)
--- a/
src/mkws-team.js
+++ b/
src/mkws-team.js
@@
-126,6
+126,7
@@
function team($, teamName) {
queue("firstrecords").publish(hitcount);
}
if (parseInt(data.activeclients[0], 10) === 0) {
queue("firstrecords").publish(hitcount);
}
if (parseInt(data.activeclients[0], 10) === 0) {
+ log("complete");
queue("complete").publish(hitcount);
}
}
queue("complete").publish(hitcount);
}
}
@@
-248,6
+249,7
@@
function team($, teamName) {
function resetPage() {
m_currentPage = 1;
m_totalRecordCount = 0;
function resetPage() {
m_currentPage = 1;
m_totalRecordCount = 0;
+ m_gotRecords = false;
}
that.resetPage = resetPage;
}
that.resetPage = resetPage;
@@
-384,7
+386,7
@@
function team($, teamName) {
};
};
- function loadTemplate(name) {
+ function loadTemplate(name, fallbackString) {
var template = m_template[name];
if (template === undefined) {
var template = m_template[name];
if (template === undefined) {
@@
-398,10
+400,16
@@
function team($, teamName) {
source = node.html();
}
source = node.html();
}
+ // If the template is not defined in HTML, check the following
+ // in order: template registered in the team by a widget;
+ // fallback string provided on this invocation; global default.
if (!source) {
source = m_templateText[name];
}
if (!source) {
if (!source) {
source = m_templateText[name];
}
if (!source) {
+ source = fallbackString;
+ }
+ if (!source) {
source = mkws.defaultTemplate(name);
}
source = mkws.defaultTemplate(name);
}