Service notes are not displayed on stage remote view when the current service item is the last.

This commit is contained in:
Jérémie Nau 2011-11-27 21:39:39 +02:00 committed by Raoul Snyman
parent fee0f79a73
commit 8e86f21cbd

View File

@ -30,10 +30,11 @@ window.OpenLP = {
$("#notes").html(""); $("#notes").html("");
for (idx in data.results.items) { for (idx in data.results.items) {
idx = parseInt(idx, 10); idx = parseInt(idx, 10);
if ((data.results.items[idx]["selected"]) && if (data.results.items[idx]["selected"]) {
(data.results.items.length > idx + 1)) { $("#notes").html(data.results.items[idx]["notes"].replace(/\n/g, "<br />"));
$("#notes").html(data.results.items[idx]["notes"]); if (data.results.items.length > idx + 1) {
OpenLP.nextSong = data.results.items[idx + 1]["title"]; OpenLP.nextSong = data.results.items[idx + 1]["title"];
}
break; break;
} }
} }