mirror of
https://github.com/Tautulli/Tautulli.git
synced 2025-07-15 01:32:57 -07:00
Display smart collection cog icon in collections table
This commit is contained in:
parent
feb8d355c7
commit
cc18b1b177
3 changed files with 14 additions and 3 deletions
|
@ -24,8 +24,12 @@ collections_table_options = {
|
||||||
"data": "titleSort",
|
"data": "titleSort",
|
||||||
"createdCell": function (td, cellData, rowData, row, col) {
|
"createdCell": function (td, cellData, rowData, row, col) {
|
||||||
if (cellData !== '') {
|
if (cellData !== '') {
|
||||||
|
var smart = '<i class="fa fa-blank fa-fw"></i>';
|
||||||
|
if (rowData['smart']) {
|
||||||
|
smart = '<span class="media-type-tooltip" data-toggle="tooltip" title="Smart Collection"><i class="fa fa-cog fa-fw"></i></span> '
|
||||||
|
}
|
||||||
var thumb_popover = '<span class="thumb-tooltip" data-toggle="popover" data-img="' + page('pms_image_proxy', rowData['thumb'], rowData['ratingKey'], 300, 450, null, null, null, 'poster') + '" data-height="120" data-width="80">' + rowData['title'] + '</span>';
|
var thumb_popover = '<span class="thumb-tooltip" data-toggle="popover" data-img="' + page('pms_image_proxy', rowData['thumb'], rowData['ratingKey'], 300, 450, null, null, null, 'poster') + '" data-height="120" data-width="80">' + rowData['title'] + '</span>';
|
||||||
$(td).html('<a href="' + page('info', rowData['ratingKey']) + '"><i class="fa fa-blank fa-fw"></i>' + thumb_popover + '</a>');
|
$(td).html(smart + '<a href="' + page('info', rowData['ratingKey']) + '">' + thumb_popover + '</a>');
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"width": "50%",
|
"width": "50%",
|
||||||
|
@ -90,6 +94,11 @@ collections_table_options = {
|
||||||
//$('html,body').scrollTop(0);
|
//$('html,body').scrollTop(0);
|
||||||
$('#ajaxMsg').fadeOut();
|
$('#ajaxMsg').fadeOut();
|
||||||
|
|
||||||
|
// Create the tooltips.
|
||||||
|
$('body').tooltip({
|
||||||
|
selector: '[data-toggle="tooltip"]',
|
||||||
|
container: 'body'
|
||||||
|
});
|
||||||
$('body').popover({
|
$('body').popover({
|
||||||
selector: '[data-toggle="popover"]',
|
selector: '[data-toggle="popover"]',
|
||||||
html: true,
|
html: true,
|
||||||
|
|
|
@ -34,8 +34,8 @@ playlists_table_options = {
|
||||||
} else if (rowData['librarySectionID']) {
|
} else if (rowData['librarySectionID']) {
|
||||||
breadcrumb = '§ion_id=' + rowData['librarySectionID'];
|
breadcrumb = '§ion_id=' + rowData['librarySectionID'];
|
||||||
}
|
}
|
||||||
var thumb_popover = '<span class="thumb-tooltip" data-toggle="popover" data-img="' + page('pms_image_proxy', rowData['composite'], rowData['ratingKey'], 300, 300, null, null, null, 'cover') + '" data-height="80" data-width="80">' + smart + cellData + '</span>';
|
var thumb_popover = '<span class="thumb-tooltip" data-toggle="popover" data-img="' + page('pms_image_proxy', rowData['composite'], rowData['ratingKey'], 300, 300, null, null, null, 'cover') + '" data-height="80" data-width="80">' + cellData + '</span>';
|
||||||
$(td).html('<a href="' + page('info', rowData['ratingKey']) + breadcrumb +'">' + thumb_popover + '</a>');
|
$(td).html(smart + '<a href="' + page('info', rowData['ratingKey']) + breadcrumb +'">' + thumb_popover + '</a>');
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"width": "60%",
|
"width": "60%",
|
||||||
|
|
|
@ -172,6 +172,7 @@ def get_collections(section_id=None):
|
||||||
'art': collection.art,
|
'art': collection.art,
|
||||||
'childCount': collection.childCount,
|
'childCount': collection.childCount,
|
||||||
'collectionMode': collection_mode,
|
'collectionMode': collection_mode,
|
||||||
|
'collectionPublished': collection.collectionPublished,
|
||||||
'collectionSort': collection_sort,
|
'collectionSort': collection_sort,
|
||||||
'contentRating': collection.contentRating,
|
'contentRating': collection.contentRating,
|
||||||
'guid': collection.guid,
|
'guid': collection.guid,
|
||||||
|
@ -180,6 +181,7 @@ def get_collections(section_id=None):
|
||||||
'maxYear': collection.maxYear,
|
'maxYear': collection.maxYear,
|
||||||
'minYear': collection.minYear,
|
'minYear': collection.minYear,
|
||||||
'ratingKey': collection.ratingKey,
|
'ratingKey': collection.ratingKey,
|
||||||
|
'smart': collection.smart,
|
||||||
'subtype': collection.subtype,
|
'subtype': collection.subtype,
|
||||||
'summary': collection.summary,
|
'summary': collection.summary,
|
||||||
'thumb': collection.thumb,
|
'thumb': collection.thumb,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue