|
@@ -238,7 +238,8 @@ function webSocketConnect() {
|
|
|
|
|
|
$('#salamisandwich > tbody').append(
|
|
|
"<tr trackid=\"" + obj.data[song].id + "\"><td>" + (obj.data[song].pos + 1) + "</td>" +
|
|
|
- "<td>" + obj.data[song].artist + " [" + obj.data[song].album + "] - " + obj.data[song].title + "</td>" +
|
|
|
+ "<td>" + obj.data[song].artist + "<br /><span>" + obj.data[song].album + "</span></td>" +
|
|
|
+ "<td>" + obj.data[song].title + "</td>" +
|
|
|
"<td>" + minutes + ":" + (seconds < 10 ? '0' : '') + seconds +
|
|
|
"</td><td></td></tr>");
|
|
|
}
|
|
@@ -334,7 +335,7 @@ function webSocketConnect() {
|
|
|
$('#salamisandwich > tbody').append(
|
|
|
"<tr uri=\"" + encodeURI(obj.data[item].dir) + "\" class=\"" + clazz + "\">" +
|
|
|
"<td><span class=\"glyphicon glyphicon-folder-open\"></span></td>" +
|
|
|
- "<td><a>" + basename(obj.data[item].dir) + "</a></td>" +
|
|
|
+ "<td colspan=\"2\"><a>" + basename(obj.data[item].dir) + "</a></td>" +
|
|
|
"<td></td><td></td></tr>"
|
|
|
);
|
|
|
break;
|
|
@@ -346,7 +347,7 @@ function webSocketConnect() {
|
|
|
$('#salamisandwich > tbody').append(
|
|
|
"<tr uri=\"" + encodeURI(obj.data[item].plist) + "\" class=\"" + clazz + "\">" +
|
|
|
"<td><span class=\"glyphicon glyphicon-list\"></span></td>" +
|
|
|
- "<td><a>" + basename(obj.data[item].plist) + "</a></td>" +
|
|
|
+ "<td colspan=\"2\"><a>" + basename(obj.data[item].plist) + "</a></td>" +
|
|
|
"<td></td><td></td></tr>"
|
|
|
);
|
|
|
break;
|
|
@@ -354,10 +355,15 @@ function webSocketConnect() {
|
|
|
var minutes = Math.floor(obj.data[item].duration / 60);
|
|
|
var seconds = obj.data[item].duration - minutes * 60;
|
|
|
|
|
|
+ if (typeof obj.data[item].artist === 'undefined') {
|
|
|
+ var details = "<td colspan=\"2\">" + obj.data[item].title + "</td>";
|
|
|
+ } else {
|
|
|
+ var details = "<td>" + obj.data[item].artist + "<br /><span>" + obj.data[item].album + "</span></td><td>" + obj.data[item].title + "</td>";
|
|
|
+ }
|
|
|
+
|
|
|
$('#salamisandwich > tbody').append(
|
|
|
"<tr uri=\"" + encodeURI(obj.data[item].uri) + "\" class=\"song\">" +
|
|
|
- "<td><span class=\"glyphicon glyphicon-music\"></span></td>" +
|
|
|
- "<td>" + (typeof obj.data[item].artist !== 'undefined' ? obj.data[item].artist + " [" + obj.data[item].album + "] - " : '') + obj.data[item].title + "</td>" +
|
|
|
+ "<td><span class=\"glyphicon glyphicon-music\"></span></td>" + details +
|
|
|
"<td>" + minutes + ":" + (seconds < 10 ? '0' : '') + seconds +
|
|
|
"</td><td></td></tr>"
|
|
|
);
|
|
@@ -367,8 +373,8 @@ function webSocketConnect() {
|
|
|
$('#next').removeClass('hide');
|
|
|
} else {
|
|
|
$('#salamisandwich > tbody').append(
|
|
|
- "<tr><td><span class=\"glyphicon glyphicon-remove\"></span></td>" +
|
|
|
- "<td>Too many results, please refine your search!</td>" +
|
|
|
+ "<tr><td><span class=\"glyphicon glyphicon-remove\"></span></td>" +
|
|
|
+ "<td colspan=\"2\">Too many results, please refine your search!</td>" +
|
|
|
"<td></td><td></td></tr>"
|
|
|
);
|
|
|
}
|