projects
/
pazpar2-moved-to-github.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
a9048ec
)
Fix subjects
author
Dennis Schafroth
<dennis@indexdata.com>
Tue, 22 Nov 2011 18:08:31 +0000
(19:08 +0100)
committer
Dennis Schafroth
<dennis@indexdata.com>
Tue, 22 Nov 2011 18:08:31 +0000
(19:08 +0100)
www/iphone/example_client.js
patch
|
blob
|
history
diff --git
a/www/iphone/example_client.js
b/www/iphone/example_client.js
index
e713b06
..
dd2d4f1
100644
(file)
--- a/
www/iphone/example_client.js
+++ b/
www/iphone/example_client.js
@@
-842,11
+842,12
@@
function renderLines(title, values, name, tag) {
if (tag == undefined)
tag = 'big';
var result = "";
if (tag == undefined)
tag = 'big';
var result = "";
- result = '<li><h3>' + title + '</h3><' + tag + '>';
if (values != undefined && values.length)
for (var idx = 0 ; idx < values.length ; idx++)
if (values != undefined && values.length)
for (var idx = 0 ; idx < values.length ; idx++)
- result += values[idx][name];
- result += '</' + tag + '></li>';
+ if (values[idx][name] != undefined )
+ result += values[idx][name] + ' ';
+ if (result != "")
+ result = '<li><h3>' + title + '</h3><' + tag + '>' + result + '</' + tag + '></li>';
return result;
}
return result;
}
@@
-912,8
+913,8
@@
function renderDetails_iphone(data, marker)
+=renderLine('Date', data["md-date"])
+ renderLine('Author', data["md-author"])
// + renderLineURL('URL', data["md-electronic-url"], data["md-electronic-url"])
+=renderLine('Date', data["md-date"])
+ renderLine('Author', data["md-author"])
// + renderLineURL('URL', data["md-electronic-url"], data["md-electronic-url"])
- + renderLine('Description', data["md-description"]);
- + renderLines('Subjects', data["location"], "md-subject");
+ + renderLine('Description', data["md-description"])
+ + renderLines('Subjects', data["location"], "md-subject");
if (coverimagetag.length>0) {
details += renderLine('Cover', coverimagetag);
if (coverimagetag.length>0) {
details += renderLine('Cover', coverimagetag);