1
0
mirror of https://github.com/SuperBFG7/ympd synced 2024-12-26 02:50:26 +00:00

Fix: extra icon for smart playlists

Fix: edit smart playlists - sticker type selection
This commit is contained in:
jcorporation 2018-11-26 16:17:46 +00:00
parent 8852586b74
commit 3b8cdf457a
2 changed files with 5 additions and 5 deletions

View File

@ -746,7 +746,7 @@
<div class="modal-dialog"> <div class="modal-dialog">
<div class="modal-content"> <div class="modal-content">
<div class="modal-header"> <div class="modal-header">
<h5 class="modal-title"><span class="material-icons title-icon">playlist_add</span>Save smart playlist</h5> <h5 class="modal-title"><span class="material-icons title-icon">queue_music</span>Save smart playlist</h5>
<button type="button" class="close" data-dismiss="modal">&times;</button> <button type="button" class="close" data-dismiss="modal">&times;</button>
</div> </div>
<div class="modal-body"> <div class="modal-body">

View File

@ -1607,7 +1607,7 @@ function parseFilesystem(obj) {
if (obj.data[i].Type == 'dir') if (obj.data[i].Type == 'dir')
tds += '<span class="material-icons">folder_open</span>'; tds += '<span class="material-icons">folder_open</span>';
else else
tds += '<span class="material-icons">list</span>'; tds += '<span class="material-icons">' + (obj.data[i].Type == 'smartpls' ? 'queue_music' :'list') + '</span>';
} }
else if (settings['cols' + list][c] == 'Title') else if (settings['cols' + list][c] == 'Title')
tds += obj.data[i].name; tds += obj.data[i].name;
@ -1693,7 +1693,7 @@ function parsePlaylists(obj) {
row.setAttribute('data-uri', uri); row.setAttribute('data-uri', uri);
row.setAttribute('data-type', obj.data[i].Type); row.setAttribute('data-type', obj.data[i].Type);
row.setAttribute('data-name', obj.data[i].name); row.setAttribute('data-name', obj.data[i].name);
row.innerHTML = '<td data-col="Type"><span class="material-icons">list</span></td>' + row.innerHTML = '<td data-col="Type"><span class="material-icons">' + (obj.data[i].Type == 'smartpls' ? 'queue_music' :'list') + '</span></td>' +
'<td>' + obj.data[i].name + '</td>' + '<td>' + obj.data[i].name + '</td>' +
'<td>'+ d.toUTCString() + '</td>' + '<td>'+ d.toUTCString() + '</td>' +
'<td data-col="Action"><a href="#" class="material-icons color-darkgrey">playlist_add</a></td>'; '<td data-col="Action"><a href="#" class="material-icons color-darkgrey">playlist_add</a></td>';
@ -2200,7 +2200,7 @@ function parseSmartPlaylist(obj) {
} }
else if (obj.data.type == 'sticker') { else if (obj.data.type == 'sticker') {
document.getElementById('saveSmartPlaylistSticker').classList.remove('hide'); document.getElementById('saveSmartPlaylistSticker').classList.remove('hide');
document.getElementById('selectSaveSmartPlaylistSticker').value = obj.data.feat_sticker; document.getElementById('selectSaveSmartPlaylistSticker').value = obj.data.sticker;
document.getElementById('inputSaveSmartPlaylistStickerMaxentries').value = obj.data.maxentries; document.getElementById('inputSaveSmartPlaylistStickerMaxentries').value = obj.data.maxentries;
} }
else if (obj.data.type == 'newest') { else if (obj.data.type == 'newest') {
@ -2449,7 +2449,7 @@ function showMenu(el, event) {
addMenuItem({"cmd": "replaceQueue", "options": [type, uri, name]},'Replace queue') + addMenuItem({"cmd": "replaceQueue", "options": [type, uri, name]},'Replace queue') +
(type == 'smartpls' ? addMenuItem({"cmd": "playlistDetails", "options": [uri]}, 'View playlist') : addMenuItem({"cmd": "playlistDetails", "options": [uri]}, 'Edit playlist'))+ (type == 'smartpls' ? addMenuItem({"cmd": "playlistDetails", "options": [uri]}, 'View playlist') : addMenuItem({"cmd": "playlistDetails", "options": [uri]}, 'Edit playlist'))+
(type == 'smartpls' ? addMenuItem({"cmd": "showSmartPlaylist", "options": [uri]}, 'Edit smart playlist') : '') + (type == 'smartpls' ? addMenuItem({"cmd": "showSmartPlaylist", "options": [uri]}, 'Edit smart playlist') : '') +
(uri.indexOf('myMPDsmart') != 0 ? (type != 'smartpls' ?
addMenuItem({"cmd": "showRenamePlaylist", "options": [uri]}, 'Rename playlist') + addMenuItem({"cmd": "showRenamePlaylist", "options": [uri]}, 'Rename playlist') +
addMenuItem({"cmd": "showDelPlaylist", "options": [uri]}, 'Delete playlist') : ''); addMenuItem({"cmd": "showDelPlaylist", "options": [uri]}, 'Delete playlist') : '');
} }