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
Rename
[mkws-moved-to-github.git]
/
experiments
/
spdemo
/
example_client.js
diff --git
a/experiments/spdemo/example_client.js
b/experiments/spdemo/example_client.js
index
a8e7c4b
..
a8b9a9a
100644
(file)
--- a/
experiments/spdemo/example_client.js
+++ b/
experiments/spdemo/example_client.js
@@
-5,9
+5,12
@@
// then register the form submit event with the pz2.search function
// autoInit is set to true on default
// then register the form submit event with the pz2.search function
// autoInit is set to true on default
-/* var usesessions = true;
- * var pazpar2path = '/pazpar2/search.pz2';
-*/
+var pazpar2URL = "/pazpar2/search.pz2";
+var serviceProxyURL = "/service-proxy/";
+var authURLServiceProxy = "/service-proxy-auth";
+var pazpar2path = useServiceProxy ? serviceProxyURL : pazpar2URL;
+
+var usesessions;
var showResponseType = '';
if (document.location.hash == '#useproxy') {
var showResponseType = '';
if (document.location.hash == '#useproxy') {
@@
-95,7
+98,10
@@
function my_onstat(data) {
+ data.activeclients
+ '/' + data.clients + ' -- </span>'
+ '<span>Retrieved records: ' + data.records
+ data.activeclients
+ '/' + data.clients + ' -- </span>'
+ '<span>Retrieved records: ' + data.records
- + '/' + data.hits + ' :.</span>';
+ + '/' + data.hits
+ + ' -- by '
+ + (useServiceProxy ? 'service proxy' : 'pazpar2')
+ + ' :.</span>';
}
function my_onterm(data) {
}
function my_onterm(data) {