mirror of
https://github.com/Tautulli/Tautulli.git
synced 2025-07-07 21:51:14 -07:00
Start front-end clean up and documentation.
This commit is contained in:
parent
54ee7f4c0d
commit
c0f487940f
19 changed files with 1320 additions and 896 deletions
|
@ -49,42 +49,94 @@
|
||||||
</div>
|
</div>
|
||||||
% elif plexpy.CONFIG.CHECK_GITHUB and plexpy.CURRENT_VERSION != plexpy.LATEST_VERSION and plexpy.COMMITS_BEHIND > 0 and plexpy.INSTALL_TYPE != 'win':
|
% elif plexpy.CONFIG.CHECK_GITHUB and plexpy.CURRENT_VERSION != plexpy.LATEST_VERSION and plexpy.COMMITS_BEHIND > 0 and plexpy.INSTALL_TYPE != 'win':
|
||||||
<div id="updatebar">
|
<div id="updatebar">
|
||||||
A <a href="https://github.com/${plexpy.CONFIG.GIT_USER}/plexpy/compare/${plexpy.CURRENT_VERSION}...${plexpy.LATEST_VERSION}"> newer version</a> is available. You're ${plexpy.COMMITS_BEHIND} commits behind. <a href="update">Update</a> or <a href="#" onclick="$('#updatebar').slideUp('slow');">Close</a>
|
A <a
|
||||||
|
href="https://github.com/${plexpy.CONFIG.GIT_USER}/plexpy/compare/${plexpy.CURRENT_VERSION}...${plexpy.LATEST_VERSION}">
|
||||||
|
newer version</a> is available. You're ${plexpy.COMMITS_BEHIND} commits behind. <a href="update">Update</a> or
|
||||||
|
<a href="#" onclick="$('#updatebar').slideUp('slow');">Close</a>
|
||||||
</div>
|
</div>
|
||||||
% endif
|
% endif
|
||||||
<div class="navbar navbar-fixed-top">
|
<div class="navbar navbar-fixed-top">
|
||||||
<div class="navbar-inner">
|
<div class="navbar-inner">
|
||||||
<a href="home"><div class="logo hidden-phone"></div></a>
|
<a href="home">
|
||||||
|
<div class="logo hidden-phone"></div>
|
||||||
|
</a>
|
||||||
<ul class="nav">
|
<ul class="nav">
|
||||||
% if title=="Home":
|
% if title=="Home":
|
||||||
<li class="active"><a href="home"><i class="fa fa-home fa-2x" data-toggle="tooltip" data-placement="bottom" title="Home" id="home"></i></a></li>
|
<li class="active">
|
||||||
|
<a href="home">
|
||||||
|
<i class="fa fa-home fa-2x" data-toggle="tooltip" data-placement="bottom" title="Home" id="home"></i>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
% else:
|
% else:
|
||||||
<li><a href="home"><i class="fa fa-home fa-2x" data-toggle="tooltip" data-placement="bottom" title="Home" id="home"></i></a></li>
|
<li>
|
||||||
|
<a href="home">
|
||||||
|
<i class="fa fa-home fa-2x" data-toggle="tooltip" data-placement="bottom" title="Home" id="home"></i>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
% endif
|
% endif
|
||||||
% if title=="History":
|
% if title=="History":
|
||||||
<li class="active"><a href="history"><i class="fa fa-history fa-2x" data-toggle="tooltip" data-placement="bottom" title="History" id="history"></i></a></li>
|
<li class="active">
|
||||||
|
<a href="history">
|
||||||
|
<i class="fa fa-history fa-2x" data-toggle="tooltip" data-placement="bottom" title="History" id="history"></i>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
% else:
|
% else:
|
||||||
<li><a href="history"><i class="fa fa-history fa-2x" data-toggle="tooltip" data-placement="bottom" title="History" id="history"></i></a></li>
|
<li>
|
||||||
|
<a href="history">
|
||||||
|
<i class="fa fa-history fa-2x" data-toggle="tooltip" data-placement="bottom" title="History" id="history"></i>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
% endif
|
% endif
|
||||||
% if title=="Users":
|
% if title=="Users":
|
||||||
<li class="active"><a href="users"><i class="fa fa-users fa-2x" data-toggle="tooltip" data-placement="bottom" title="Users" id="users"></i></a></li>
|
<li class="active">
|
||||||
|
<a href="users">
|
||||||
|
<i class="fa fa-users fa-2x" data-toggle="tooltip" data-placement="bottom" title="Users" id="users"></i>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
% else:
|
% else:
|
||||||
<li><a href="users"><i class="fa fa-users fa-2x" data-toggle="tooltip" data-placement="bottom" title="Users" id="users"></i></a></li>
|
<li>
|
||||||
|
<a href="users">
|
||||||
|
<i class="fa fa-users fa-2x" data-toggle="tooltip" data-placement="bottom" title="Users" id="users"></i>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
% endif
|
% endif
|
||||||
% if title=="Graphs":
|
% if title=="Graphs":
|
||||||
<li class="active"><a href="graphs"><i class="fa fa-bar-chart fa-2x" data-toggle="tooltip" data-placement="bottom" title="Graphs" id="graphs"></i></a></li>
|
<li class="active">
|
||||||
|
<a href="graphs">
|
||||||
|
<i class="fa fa-bar-chart fa-2x" data-toggle="tooltip" data-placement="bottom" title="Graphs" id="graphs"></i>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
% else:
|
% else:
|
||||||
<li><a href="graphs"><i class="fa fa-bar-chart fa-2x" data-toggle="tooltip" data-placement="bottom" title="Graphs" id="graphs"></i></a></li>
|
<li>
|
||||||
|
<a href="graphs">
|
||||||
|
<i class="fa fa-bar-chart fa-2x" data-toggle="tooltip" data-placement="bottom" title="Graphs" id="graphs"></i>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
% endif
|
% endif
|
||||||
% if title=="Log":
|
% if title=="Log":
|
||||||
<li class="active"><a href="logs"><i class="fa fa-book fa-2x" data-toggle="tooltip" data-placement="bottom" title="Logs" id="logs"></i></a></li>
|
<li class="active">
|
||||||
|
<a href="logs">
|
||||||
|
<i class="fa fa-book fa-2x" data-toggle="tooltip" data-placement="bottom" title="Logs" id="logs"></i>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
% else:
|
% else:
|
||||||
<li><a href="logs"><i class="fa fa-book fa-2x" data-toggle="tooltip" data-placement="bottom" title="Logs" id="logs"></i></a></li>
|
<li>
|
||||||
|
<a href="logs">
|
||||||
|
<i class="fa fa-book fa-2x" data-toggle="tooltip" data-placement="bottom" title="Logs" id="logs"></i>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
% endif
|
% endif
|
||||||
% if title=="Settings":
|
% if title=="Settings":
|
||||||
<li class="active"><a href="config"><i class="fa fa-cog fa-2x" data-toggle="tooltip" data-placement="bottom" title="Settings" id="settings"></i></a></li>
|
<li class="active">
|
||||||
|
<a href="config">
|
||||||
|
<i class="fa fa-cog fa-2x" data-toggle="tooltip" data-placement="bottom" title="Settings" id="settings"></i>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
% else:
|
% else:
|
||||||
<li><a href="config"><i class="fa fa-cog fa-2x" data-toggle="tooltip" data-placement="bottom" title="Settings" id="settings"></i></a></li>
|
<li>
|
||||||
|
<a href="config">
|
||||||
|
<i class="fa fa-cog fa-2x" data-toggle="tooltip" data-placement="bottom"
|
||||||
|
title="Settings" id="settings"></i></a></li>
|
||||||
% endif
|
% endif
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
@ -115,6 +167,7 @@
|
||||||
$(document).ready(function() {
|
$(document).ready(function() {
|
||||||
$('#settings').tooltip();
|
$('#settings').tooltip();
|
||||||
});
|
});
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
<script src="interfaces/default/js/script.js"></script>
|
<script src="interfaces/default/js/script.js"></script>
|
||||||
${next.javascriptIncludes()}
|
${next.javascriptIncludes()}
|
||||||
|
|
|
@ -1,10 +1,58 @@
|
||||||
% if activity is not None:
|
<%doc>
|
||||||
% if activity['stream_count'] != '0':
|
USAGE DOCUMENTATION :: PLEASE LEAVE THIS AT THE TOP OF THIS FILE
|
||||||
% for a in activity['sessions']:
|
|
||||||
|
For Mako templating syntax documentation please visit: http://docs.makotemplates.org/en/latest/
|
||||||
|
|
||||||
|
Filename: current_activity.html
|
||||||
|
Version: 0.1
|
||||||
|
Variable names: data [list]
|
||||||
|
|
||||||
|
data :: Usable parameters
|
||||||
|
|
||||||
|
data['stream_count'] Returns the current number of active streams
|
||||||
|
data['sessions'] Returns an array containing session data
|
||||||
|
|
||||||
|
data[sessions] :: Usable parameters
|
||||||
|
|
||||||
|
== Global keys ==
|
||||||
|
sessionKey Returns a unique session id for the active stream
|
||||||
|
ratingKey Returns the unique identifier for the media item.
|
||||||
|
type Returns the type of session. Either 'track', 'episode' or 'movie'.
|
||||||
|
thumb Returns the location of the item's thumbnail. Use with pms_image_proxy.
|
||||||
|
art Returns the location of the item's artwork
|
||||||
|
progress_percent Returns the current progress of the item. 0 to 100.
|
||||||
|
user Returns the name of the user owning the session.
|
||||||
|
state Returns the state of the current session. Either 'playing', 'paused' or 'buffering'.
|
||||||
|
title Returns the name of the episode, movie or music track.
|
||||||
|
player Returns the name of the platform used to play the stream.
|
||||||
|
audioDecision Returns the audio transcode decision. Either 'transcode', 'copy' or 'direct play'.
|
||||||
|
audioCodec Returns the name of the audio codec.
|
||||||
|
audioChannels Returns the number of audio channels.
|
||||||
|
|
||||||
|
== Only if 'type' is 'episode' ==
|
||||||
|
grandparentTitle Returns the name of the TV Show.
|
||||||
|
|
||||||
|
== Only if 'type' is 'track' ==
|
||||||
|
artist Returns the name of the artist of a music track.
|
||||||
|
album Returns the name of the album of the music track.
|
||||||
|
|
||||||
|
== Only if 'type' is 'episode' or 'movie' ==
|
||||||
|
videoDecision Returns the video transcode decision. Either 'transcode', 'copy' or 'direct play'.
|
||||||
|
videoCodec Returns the name of the video codec.
|
||||||
|
height Returns the value of the video height.
|
||||||
|
width Returns the value of the video width.
|
||||||
|
|
||||||
|
DOCUMENTATION :: END
|
||||||
|
</%doc>
|
||||||
|
|
||||||
|
% if data is not None:
|
||||||
|
% if data['stream_count'] != '0':
|
||||||
|
% for a in data['sessions']:
|
||||||
<div class="instance" id="instance-${a['sessionKey']}">
|
<div class="instance" id="instance-${a['sessionKey']}">
|
||||||
<div class="poster">
|
<div class="poster">
|
||||||
% if a['type'] == 'track-to-do':
|
% if a['type'] == 'track-to-do':
|
||||||
<div class="art-music-face" style="background-image:url(pms_image_proxy?img=${a['thumb']}&width=300&height=300)"></div>
|
<div class="art-music-face"
|
||||||
|
style="background-image:url(pms_image_proxy?img=${a['thumb']}&width=300&height=300)"></div>
|
||||||
% elif a['type'] == 'movie':
|
% elif a['type'] == 'movie':
|
||||||
<div class="dashboard-activity-poster-face">
|
<div class="dashboard-activity-poster-face">
|
||||||
<img src="pms_image_proxy?img=${a['art']}&width=300&height=169"/> <!-- media artwork -->
|
<img src="pms_image_proxy?img=${a['art']}&width=300&height=169"/> <!-- media artwork -->
|
||||||
|
@ -22,7 +70,6 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="dashboard-activity-metadata-platform" id="platform-${a['sessionKey']}">
|
<div class="dashboard-activity-metadata-platform" id="platform-${a['sessionKey']}">
|
||||||
<!-- <img src="interfaces/default/images/platforms/roku.png"> platform image -->
|
|
||||||
</div>
|
</div>
|
||||||
<div class="dashboard-activity-metadata-user">
|
<div class="dashboard-activity-metadata-user">
|
||||||
<a href="user?user=${a['user']}">${a['user']}</a> is ${a['state']}
|
<a href="user?user=${a['user']}">${a['user']}</a> is ${a['state']}
|
||||||
|
@ -71,7 +118,8 @@
|
||||||
Stream: <strong>Transcoding</strong>
|
Stream: <strong>Transcoding</strong>
|
||||||
% endif
|
% endif
|
||||||
<br/>
|
<br/>
|
||||||
Video: <strong>${a['videoDecision']} (${a['videoCodec']}) (${a['width']}x${a['height']})</strong>
|
Video: <strong>${a['videoDecision']} (${a['videoCodec']})
|
||||||
|
(${a['width']}x${a['height']})</strong>
|
||||||
<br/>
|
<br/>
|
||||||
Audio: <strong>${a['audioDecision']} (${a['audioCodec']}) (${a['audioChannels']}ch)</strong>
|
Audio: <strong>${a['audioDecision']} (${a['audioCodec']}) (${a['audioChannels']}ch)</strong>
|
||||||
% endif
|
% endif
|
||||||
|
@ -89,11 +137,14 @@
|
||||||
</div>
|
</div>
|
||||||
<script>
|
<script>
|
||||||
$("#platform-${a['sessionKey']}").html("<img src='" + getPlatformImagePath('${a['player']}') + "'>");
|
$("#platform-${a['sessionKey']}").html("<img src='" + getPlatformImagePath('${a['player']}') + "'>");
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
% endfor
|
% endfor
|
||||||
% else:
|
% else:
|
||||||
<div class="muted">Nothing is currently being watched.</div><br>
|
<div class="muted">Nothing is currently being watched.</div><br>
|
||||||
% endif
|
% endif
|
||||||
% else:
|
% else:
|
||||||
<div class="muted">There was an error communicating with your Plex Server. Please check your <a href="config">settings</a>.</div><br>
|
<div class="muted">There was an error communicating with your Plex Server. Please check your <a
|
||||||
|
href="config">settings</a>.
|
||||||
|
</div><br>
|
||||||
% endif
|
% endif
|
|
@ -1,8 +1,24 @@
|
||||||
% if activity != None:
|
<%doc>
|
||||||
% if activity == '0':
|
USAGE DOCUMENTATION :: PLEASE LEAVE THIS AT THE TOP OF THIS FILE
|
||||||
|
|
||||||
|
For Mako templating syntax documentation please visit: http://docs.makotemplates.org/en/latest/
|
||||||
|
|
||||||
|
Filename: current_activity_header.html
|
||||||
|
Version: 0.1
|
||||||
|
Variable names: data [string]
|
||||||
|
|
||||||
|
data :: Usable parameters
|
||||||
|
|
||||||
|
data Returns the current number of active streams
|
||||||
|
|
||||||
|
DOCUMENTATION :: END
|
||||||
|
</%doc>
|
||||||
|
|
||||||
|
% if data != None:
|
||||||
|
% if data == '0':
|
||||||
<h3>Activity</h3>
|
<h3>Activity</h3>
|
||||||
% else:
|
% else:
|
||||||
<h3>Activity <strong>${activity}</strong> stream(s)</h3>
|
<h3>Activity <strong>${data}</strong> stream(s)</h3>
|
||||||
% endif
|
% endif
|
||||||
% else:
|
% else:
|
||||||
<h3>Activity</h3>
|
<h3>Activity</h3>
|
||||||
|
|
|
@ -26,7 +26,8 @@ from plexpy import helpers
|
||||||
<div class="wellheader">
|
<div class="wellheader">
|
||||||
<div class="dashboard-wellheader">
|
<div class="dashboard-wellheader">
|
||||||
<div class="span12">
|
<div class="span12">
|
||||||
<div class="span8"><h4>Daily Watch History (Past <span class="days">30</span> days)</h4></div>
|
<div class="span8"><h4>Daily Watch History (Past <span class="days">30</span> days)</h4>
|
||||||
|
</div>
|
||||||
<div class="span4" style="text-align: right; padding-right: 30px;">
|
<div class="span4" style="text-align: right; padding-right: 30px;">
|
||||||
<h5>
|
<h5>
|
||||||
<a href="javascript:void(0)" id="graph-30"> 30 days</a> |
|
<a href="javascript:void(0)" id="graph-30"> 30 days</a> |
|
||||||
|
@ -40,7 +41,8 @@ from plexpy import helpers
|
||||||
<div>
|
<div>
|
||||||
<div class="graphs-instance">
|
<div class="graphs-instance">
|
||||||
<div class="watch-chart" id="chart_div_plays_by_day">
|
<div class="watch-chart" id="chart_div_plays_by_day">
|
||||||
<div class="graphs-load"><i class="fa fa-refresh fa-spin"></i> Loading chart...</div><br>
|
<div class="graphs-load"><i class="fa fa-refresh fa-spin"></i> Loading chart...</div>
|
||||||
|
<br>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -55,7 +57,9 @@ from plexpy import helpers
|
||||||
</div>
|
</div>
|
||||||
<div class="graphs-instance">
|
<div class="graphs-instance">
|
||||||
<div class="watch-chart" id="chart_div_plays_by_dayofweek" style="float: left;">
|
<div class="watch-chart" id="chart_div_plays_by_dayofweek" style="float: left;">
|
||||||
<div class="graphs-load"><i class="fa fa-refresh fa-spin"></i> Loading chart...</div><br>
|
<div class="graphs-load"><i class="fa fa-refresh fa-spin"></i> Loading chart...
|
||||||
|
</div>
|
||||||
|
<br>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -67,7 +71,9 @@ from plexpy import helpers
|
||||||
</div>
|
</div>
|
||||||
<div class="graphs-instance">
|
<div class="graphs-instance">
|
||||||
<div class="watch-chart" id="chart_div_plays_by_hourofday">
|
<div class="watch-chart" id="chart_div_plays_by_hourofday">
|
||||||
<div class="graphs-load"><i class="fa fa-refresh fa-spin"></i> Loading chart...</div><br>
|
<div class="graphs-load"><i class="fa fa-refresh fa-spin"></i> Loading chart...
|
||||||
|
</div>
|
||||||
|
<br>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -159,5 +165,6 @@ from plexpy import helpers
|
||||||
});
|
});
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
</%def>
|
</%def>
|
|
@ -45,7 +45,8 @@
|
||||||
<tbody>
|
<tbody>
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
<div id="info-modal" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="info-modal" aria-hidden="true">
|
<div id="info-modal" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="info-modal"
|
||||||
|
aria-hidden="true">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -69,6 +70,7 @@
|
||||||
|
|
||||||
history_table = $('#history_table').DataTable(history_table_options);
|
history_table = $('#history_table').DataTable(history_table_options);
|
||||||
});
|
});
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
</%def>
|
</%def>
|
||||||
|
|
|
@ -1,8 +1,45 @@
|
||||||
% if stats != None:
|
<%doc>
|
||||||
% if stats[0]['rows']:
|
USAGE DOCUMENTATION :: PLEASE LEAVE THIS AT THE TOP OF THIS FILE
|
||||||
|
|
||||||
|
For Mako templating syntax documentation please visit: http://docs.makotemplates.org/en/latest/
|
||||||
|
|
||||||
|
Filename: home_stats.html
|
||||||
|
Version: 0.1
|
||||||
|
Variable names: data [array]
|
||||||
|
|
||||||
|
data[array_index] :: Usable parameters
|
||||||
|
|
||||||
|
data['stat_id'] Returns the name of the stat. Either 'top_tv', 'popular_tv', 'top_user' or 'top_platform'
|
||||||
|
data['rows'] Returns an array containing stat data
|
||||||
|
|
||||||
|
data[array_index]['rows'] :: Usable parameters
|
||||||
|
|
||||||
|
== Only if 'stat_id' is 'top_tv' or 'popular_tv' ==
|
||||||
|
grandparent_thumb Returns location of the item's thumbnail. Use with pms_image_proxy.
|
||||||
|
rating_key Returns the unique identifier for the media item.
|
||||||
|
orig_title Returns the title for the associated stat.
|
||||||
|
|
||||||
|
== Only if 'stat_id' is 'top_tv' or 'top_user' or 'top_platform' ==
|
||||||
|
total_plays Returns the count for the associated stat.
|
||||||
|
|
||||||
|
== Only of 'stat_id' is 'popular_tv' ==
|
||||||
|
users_watched Returns the count for the associated stat.
|
||||||
|
|
||||||
|
== Only if 'stat_id' is 'top_user' ==
|
||||||
|
thumb Returns url of the user's gravatar. Returns '' if none exists.
|
||||||
|
user Returns the username for the associated stat.
|
||||||
|
|
||||||
|
== Only if 'stat_id' is 'top_platform' ==
|
||||||
|
platform_type Returns the platform name for the associated stat.
|
||||||
|
|
||||||
|
DOCUMENTATION :: END
|
||||||
|
</%doc>
|
||||||
|
|
||||||
|
% if data != None:
|
||||||
|
% if data[0]['rows']:
|
||||||
<div class="user-platforms">
|
<div class="user-platforms">
|
||||||
<ul>
|
<ul>
|
||||||
% for a in stats:
|
% for a in data:
|
||||||
% if a['stat_id'] == 'top_tv':
|
% if a['stat_id'] == 'top_tv':
|
||||||
<div class="home-platforms-instance">
|
<div class="home-platforms-instance">
|
||||||
<li>
|
<li>
|
||||||
|
@ -16,6 +53,7 @@
|
||||||
% endif
|
% endif
|
||||||
</a>
|
</a>
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
<div class="home-platforms-instance-name">
|
<div class="home-platforms-instance-name">
|
||||||
<h4>Most Watched TV</h4>
|
<h4>Most Watched TV</h4>
|
||||||
<a href="info?rating_key=${a['rows'][0]['rating_key']}">
|
<a href="info?rating_key=${a['rows'][0]['rating_key']}">
|
||||||
|
@ -24,6 +62,7 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="user-platforms-instance-playcount">
|
<div class="user-platforms-instance-playcount">
|
||||||
<h3>${a['rows'][0]['total_plays']}</h3>
|
<h3>${a['rows'][0]['total_plays']}</h3>
|
||||||
|
|
||||||
<p> plays</p>
|
<p> plays</p>
|
||||||
</div>
|
</div>
|
||||||
</li>
|
</li>
|
||||||
|
@ -41,6 +80,7 @@
|
||||||
% endif
|
% endif
|
||||||
</a>
|
</a>
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
<div class="home-platforms-instance-name">
|
<div class="home-platforms-instance-name">
|
||||||
<h4>Most Popular TV</h4>
|
<h4>Most Popular TV</h4>
|
||||||
<a href="info?rating_key=${a['rows'][0]['rating_key']}">
|
<a href="info?rating_key=${a['rows'][0]['rating_key']}">
|
||||||
|
@ -49,6 +89,7 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="user-platforms-instance-playcount">
|
<div class="user-platforms-instance-playcount">
|
||||||
<h3>${a['rows'][0]['users_watched']}</h3>
|
<h3>${a['rows'][0]['users_watched']}</h3>
|
||||||
|
|
||||||
<p> users</p>
|
<p> users</p>
|
||||||
</div>
|
</div>
|
||||||
</li>
|
</li>
|
||||||
|
@ -67,6 +108,7 @@
|
||||||
% endif
|
% endif
|
||||||
</a>
|
</a>
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
<div class="home-platforms-instance-name">
|
<div class="home-platforms-instance-name">
|
||||||
<h4>Most Active User</h4>
|
<h4>Most Active User</h4>
|
||||||
<a href="user?user=${a['rows'][0]['user']}">
|
<a href="user?user=${a['rows'][0]['user']}">
|
||||||
|
@ -75,6 +117,7 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="user-platforms-instance-playcount">
|
<div class="user-platforms-instance-playcount">
|
||||||
<h3>${a['rows'][0]['total_plays']}</h3>
|
<h3>${a['rows'][0]['total_plays']}</h3>
|
||||||
|
|
||||||
<p> plays</p>
|
<p> plays</p>
|
||||||
</div>
|
</div>
|
||||||
</li>
|
</li>
|
||||||
|
@ -91,12 +134,14 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="user-platforms-instance-playcount">
|
<div class="user-platforms-instance-playcount">
|
||||||
<h3>${a['rows'][0]['total_plays']}</h3>
|
<h3>${a['rows'][0]['total_plays']}</h3>
|
||||||
|
|
||||||
<p> plays</p>
|
<p> plays</p>
|
||||||
</div>
|
</div>
|
||||||
</li>
|
</li>
|
||||||
</div>
|
</div>
|
||||||
<script>
|
<script>
|
||||||
$("#platform-stat").html("<img class='home-platforms-instance-box' src='" + getPlatformImagePath('${a['rows'][0]['platform_type']}') + "'>");
|
$("#platform-stat").html("<img class='home-platforms-instance-box' src='" + getPlatformImagePath('${a['rows'][0]['platform_type']}') + "'>");
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
% endif
|
% endif
|
||||||
% endfor
|
% endfor
|
||||||
|
|
|
@ -21,7 +21,8 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div id="currentActivity">
|
<div id="currentActivity">
|
||||||
<div class="muted"><i class="fa fa-refresh fa-spin"></i> Checking for activity...</div><br>
|
<div class="muted"><i class="fa fa-refresh fa-spin"></i> Checking for activity...</div>
|
||||||
|
<br>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -35,7 +36,8 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div id="home-stats" class="user-platforms">
|
<div id="home-stats" class="user-platforms">
|
||||||
<div class='muted'><i class="fa fa-refresh fa-spin"></i> Loading stats...</div><br>
|
<div class='muted'><i class="fa fa-refresh fa-spin"></i> Loading stats...</div>
|
||||||
|
<br>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -48,7 +50,8 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div id='recentlyAdded'>
|
<div id='recentlyAdded'>
|
||||||
<div class='muted'><i class="fa fa-refresh fa-spin"></i> Looking for new items...</div><br>
|
<div class='muted'><i class="fa fa-refresh fa-spin"></i> Looking for new items...</div>
|
||||||
|
<br>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -127,6 +130,7 @@
|
||||||
|
|
||||||
getHomeStats(30);
|
getHomeStats(30);
|
||||||
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
</%def>
|
</%def>
|
||||||
|
|
|
@ -1,3 +1,53 @@
|
||||||
|
<%doc>
|
||||||
|
USAGE DOCUMENTATION :: PLEASE LEAVE THIS AT THE TOP OF THIS FILE
|
||||||
|
|
||||||
|
For Mako templating syntax documentation please visit: http://docs.makotemplates.org/en/latest/
|
||||||
|
|
||||||
|
Filename: info.html
|
||||||
|
Version: 0.1
|
||||||
|
Variable names: data [list]
|
||||||
|
|
||||||
|
data :: Usable parameters
|
||||||
|
|
||||||
|
== Global keys ==
|
||||||
|
ratingKey Returns the unique identifier for the media item.
|
||||||
|
type Returns the type of media. Either 'movie', 'episode' or 'show' or 'season'.
|
||||||
|
art Returns the location of the item's artwork
|
||||||
|
title Returns the name of the episode, show, season or movie.
|
||||||
|
duration Returns the standard runtime of the media.
|
||||||
|
contentRating Returns the age rating for the media.
|
||||||
|
summary Returns a brief description of the media plot.
|
||||||
|
|
||||||
|
== Only if 'type' is 'episode' ==
|
||||||
|
grandparentTitle Returns the name of the TV show.
|
||||||
|
parentIndex Returns the season number of the TV show.
|
||||||
|
index Returns the episode number.
|
||||||
|
parentThumb Returns the location of the item's thumbnail. Use with pms_image_proxy.
|
||||||
|
writers Returns an array of writers.
|
||||||
|
|
||||||
|
== Only if 'type' is 'movie' or 'season' or 'show' ==
|
||||||
|
thumb Returns the location of the item's thumbnail. Use with pms_image_proxy.
|
||||||
|
|
||||||
|
== Only if 'type' is 'season' ==
|
||||||
|
parentTitle Returns the name of the TV show.
|
||||||
|
|
||||||
|
== Only if 'type' is 'movie' ==
|
||||||
|
rating Returns the 5 star rating value for the movie. Between 1 and 5.
|
||||||
|
year Returns the release year of the movie.
|
||||||
|
|
||||||
|
== Only if 'type' is 'movie' or 'show' ==
|
||||||
|
genres Returns an array of genres.
|
||||||
|
actors Returns an array of actors.
|
||||||
|
|
||||||
|
== Only if 'type' is 'episode' or 'movie' ==
|
||||||
|
directors Returns an array of directors.
|
||||||
|
|
||||||
|
== Only if 'type' is 'show' or 'season' ==
|
||||||
|
studio Returns the name of the studio.
|
||||||
|
|
||||||
|
DOCUMENTATION :: END
|
||||||
|
</%doc>
|
||||||
|
|
||||||
<%inherit file="base.html"/>
|
<%inherit file="base.html"/>
|
||||||
<%!
|
<%!
|
||||||
from plexpy import helpers
|
from plexpy import helpers
|
||||||
|
@ -8,77 +58,72 @@
|
||||||
</%def>
|
</%def>
|
||||||
|
|
||||||
<%def name="body()">
|
<%def name="body()">
|
||||||
% if metadata:
|
% if data:
|
||||||
<div class="clear"></div>
|
<div class="clear"></div>
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<!-- Some span12 if parameter -->
|
|
||||||
<div class="row-fluid">
|
<div class="row-fluid">
|
||||||
<div class="span12">
|
<div class="span12">
|
||||||
<!-- end span12 if -->
|
<div class="art-face"
|
||||||
<!-- if art -->
|
style="background-image:url(pms_image_proxy?img=${data['art']}&width=1920&height=1080)">
|
||||||
<div class="art-face" style="background-image:url(pms_image_proxy?img=${metadata['art']}&width=1920&height=1080)">
|
|
||||||
<!-- if not art
|
|
||||||
<div class="art-face">
|
|
||||||
-->
|
|
||||||
<div class="summary-wrapper">
|
<div class="summary-wrapper">
|
||||||
<div class="summary-overlay">
|
<div class="summary-overlay">
|
||||||
<div class="row-fluid">
|
<div class="row-fluid">
|
||||||
|
|
||||||
<div class="span9">
|
<div class="span9">
|
||||||
|
|
||||||
<div class="summary-content-poster hidden-phone hidden-tablet">
|
<div class="summary-content-poster hidden-phone hidden-tablet">
|
||||||
% if metadata['type'] == 'episode':
|
% if data['type'] == 'episode':
|
||||||
<img src="pms_image_proxy?img=${metadata['parentThumb']}&width=256&height=352">
|
<img src="pms_image_proxy?img=${data['parentThumb']}&width=256&height=352">
|
||||||
% else:
|
% else:
|
||||||
<img src="pms_image_proxy?img=${metadata['thumb']}&width=256&height=352">
|
<img src="pms_image_proxy?img=${data['thumb']}&width=256&height=352">
|
||||||
% endif
|
% endif
|
||||||
</div>
|
</div>
|
||||||
<div class="summary-content">
|
<div class="summary-content">
|
||||||
<div class="summary-content-title">
|
<div class="summary-content-title">
|
||||||
% if metadata['type'] == 'movie':
|
% if data['type'] == 'movie':
|
||||||
<h1>${metadata['title']} (${metadata['year']})</h1>
|
<h1>${data['title']} (${data['year']})</h1>
|
||||||
% elif metadata['type'] == 'season':
|
% elif data['type'] == 'season':
|
||||||
<h1>${metadata['parentTitle']} (${metadata['title']})</h1>
|
<h1>${data['parentTitle']} (${data['title']})</h1>
|
||||||
% elif metadata['type'] == 'episode':
|
% elif data['type'] == 'episode':
|
||||||
<h1>${metadata['grandparentTitle']} (Season ${metadata['parentIndex']}, Episode ${metadata['index']}) "${metadata['title']}"</h1>
|
<h1>${data['grandparentTitle']} (Season ${data['parentIndex']}, Episode
|
||||||
|
${data['index']}) "${data['title']}"</h1>
|
||||||
% else:
|
% else:
|
||||||
<h1>${metadata['title']}</h1>
|
<h1>${data['title']}</h1>
|
||||||
% endif
|
% endif
|
||||||
</div>
|
</div>
|
||||||
% if metadata['type'] == 'movie':
|
% if data['type'] == 'movie':
|
||||||
<div id="stars" class="rateit hidden-phone hidden-tablet" data-rateit-value="" data-rateit-ispreset="true" data-rateit-readonly="true"></div>
|
<div id="stars" class="rateit hidden-phone hidden-tablet" data-rateit-value=""
|
||||||
|
data-rateit-ispreset="true" data-rateit-readonly="true"></div>
|
||||||
% endif
|
% endif
|
||||||
<div class="summary-content-details-wrapper">
|
<div class="summary-content-details-wrapper">
|
||||||
<div class="summary-content-director">
|
<div class="summary-content-director">
|
||||||
% if metadata['type'] == 'episode' or metadata['type'] == 'movie':
|
% if data['type'] == 'episode' or data['type'] == 'movie':
|
||||||
% if metadata['directors']:
|
% if data['directors']:
|
||||||
Directed by <strong> ${metadata['directors'][0]}</strong>
|
Directed by <strong> ${data['directors'][0]}</strong>
|
||||||
% else:
|
% else:
|
||||||
Directed by <strong> unknown</strong>
|
Directed by <strong> unknown</strong>
|
||||||
% endif
|
% endif
|
||||||
% elif metadata['type'] == 'show' or metadata['type'] == 'season':
|
% elif data['type'] == 'show' or data['type'] == 'season':
|
||||||
Studio <strong> ${metadata['studio']}</strong>
|
Studio <strong> ${data['studio']}</strong>
|
||||||
% endif
|
% endif
|
||||||
</div>
|
</div>
|
||||||
<div class="summary-content-duration">
|
<div class="summary-content-duration">
|
||||||
Runtime <strong> ${metadata['duration']} mins</strong>
|
Runtime <strong> ${data['duration']} mins</strong>
|
||||||
</div>
|
</div>
|
||||||
<div class="summary-content-content-rating">
|
<div class="summary-content-content-rating">
|
||||||
Rated <strong> ${metadata['contentRating']} </strong>
|
Rated <strong> ${data['contentRating']} </strong>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="summary-content-summary">
|
<div class="summary-content-summary">
|
||||||
<p> ${metadata['summary']} </p>
|
<p> ${data['summary']} </p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
% if metadata['type'] == 'episode':
|
% if data['type'] == 'episode':
|
||||||
<div class="span3">
|
<div class="span3">
|
||||||
<div class="summary-content-people-wrapper hidden-phone hidden-tablet">
|
<div class="summary-content-people-wrapper hidden-phone hidden-tablet">
|
||||||
<div class="summary-content-writers">
|
<div class="summary-content-writers">
|
||||||
<h6><strong>Written by</strong></h6>
|
<h6><strong>Written by</strong></h6>
|
||||||
<ul>
|
<ul>
|
||||||
% for writer in metadata['writers']:
|
% for writer in data['writers']:
|
||||||
% if loop.index < 5:
|
% if loop.index < 5:
|
||||||
<li>
|
<li>
|
||||||
${writer}
|
${writer}
|
||||||
|
@ -89,13 +134,13 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
% elif metadata['type'] == 'movie' or metadata['type'] == 'show':
|
% elif data['type'] == 'movie' or data['type'] == 'show':
|
||||||
<div class="span3">
|
<div class="span3">
|
||||||
<div class="summary-content-people-wrapper hidden-phone hidden-tablet">
|
<div class="summary-content-people-wrapper hidden-phone hidden-tablet">
|
||||||
<div class="summary-content-actors">
|
<div class="summary-content-actors">
|
||||||
<h6><strong>Genres</strong></h6>
|
<h6><strong>Genres</strong></h6>
|
||||||
<ul>
|
<ul>
|
||||||
% for genre in metadata['genres']:
|
% for genre in data['genres']:
|
||||||
% if loop.index < 5:
|
% if loop.index < 5:
|
||||||
<li>
|
<li>
|
||||||
${genre}
|
${genre}
|
||||||
|
@ -108,7 +153,7 @@
|
||||||
<div class="summary-content-actors">
|
<div class="summary-content-actors">
|
||||||
<h6><strong>Starring</strong></h6>
|
<h6><strong>Starring</strong></h6>
|
||||||
<ul>
|
<ul>
|
||||||
% for actor in metadata['actors']:
|
% for actor in data['actors']:
|
||||||
% if loop.index < 5:
|
% if loop.index < 5:
|
||||||
<li>
|
<li>
|
||||||
${actor}
|
${actor}
|
||||||
|
@ -120,26 +165,24 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
% elif metadata['type'] == 'season':
|
% elif data['type'] == 'season':
|
||||||
<div class="span3"></div>
|
<div class="span3"></div>
|
||||||
% endif
|
% endif
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!-- span rule -->
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!--}-->
|
|
||||||
</div>
|
</div>
|
||||||
<div class='container-fluid'>
|
<div class='container-fluid'>
|
||||||
<div class='row-fluid'>
|
<div class='row-fluid'>
|
||||||
<div class='span12'>
|
<div class='span12'>
|
||||||
<div class='wellbg'>
|
<div class='wellbg'>
|
||||||
% if metadata['type'] == 'movie' or metadata['type'] == 'episode' or metadata['type'] == 'show':
|
% if data['type'] == 'movie' or data['type'] == 'episode' or data['type'] == 'show':
|
||||||
<div class="wellheader">
|
<div class="wellheader">
|
||||||
<div class="dashboard-wellheader">
|
<div class="dashboard-wellheader">
|
||||||
<h3>Watch history for <strong>${metadata['title']}</strong></h3>
|
<h3>Watch history for <strong>${data['title']}</strong></h3>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<table class="display" id="history_table" width="100%">
|
<table class="display" id="history_table" width="100%">
|
||||||
|
@ -163,12 +206,13 @@
|
||||||
<tbody>
|
<tbody>
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
<div id="info-modal" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="info-modal" aria-hidden="true">
|
<div id="info-modal" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="info-modal"
|
||||||
|
aria-hidden="true">
|
||||||
</div>
|
</div>
|
||||||
% elif metadata['type'] == 'season':
|
% elif data['type'] == 'season':
|
||||||
<div class="wellheader">
|
<div class="wellheader">
|
||||||
<div class="dashboard-wellheader">
|
<div class="dashboard-wellheader">
|
||||||
<h3>Episode list for <strong>${metadata['title']}</strong></h3>
|
<h3>Episode list for <strong>${data['title']}</strong></h3>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div id="episode-list">
|
<div id="episode-list">
|
||||||
|
@ -183,7 +227,8 @@
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<div class="row-fluid">
|
<div class="row-fluid">
|
||||||
<div class="span10 offset1">
|
<div class="span10 offset1">
|
||||||
<h3>Error retrieving item metadata. This media may not be available in the Plex Media Server database anymore.</h3>
|
<h3>Error retrieving item data. This media may not be available in the Plex Media Server database
|
||||||
|
anymore.</h3>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -196,22 +241,23 @@
|
||||||
<script src="interfaces/default/js/jquery.dataTables.bootstrap.pagination.integration.js"></script>
|
<script src="interfaces/default/js/jquery.dataTables.bootstrap.pagination.integration.js"></script>
|
||||||
<script src="interfaces/default/js/moment-with-locale.js"></script>
|
<script src="interfaces/default/js/moment-with-locale.js"></script>
|
||||||
|
|
||||||
% if metadata:
|
% if data:
|
||||||
% if metadata['type'] == 'movie':
|
% if data['type'] == 'movie':
|
||||||
<script>
|
<script>
|
||||||
// Convert rating to 5 star rating type
|
// Convert rating to 5 star rating type
|
||||||
var starRating = Math.round(${metadata['rating']} / 2)
|
var starRating = Math.round(${data['rating']} / 2)
|
||||||
$('#stars').attr('data-rateit-value', starRating)
|
$('#stars').attr('data-rateit-value', starRating)
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
% endif
|
% endif
|
||||||
% if metadata['type'] == 'movie' or metadata['type'] == 'episode':
|
% if data['type'] == 'movie' or data['type'] == 'episode':
|
||||||
<script src="interfaces/default/js/tables/history_table.js"></script>
|
<script src="interfaces/default/js/tables/history_table.js"></script>
|
||||||
<script>
|
<script>
|
||||||
$(document).ready(function () {
|
$(document).ready(function () {
|
||||||
history_table_options.ajax = {
|
history_table_options.ajax = {
|
||||||
"url": "get_history",
|
"url": "get_history",
|
||||||
"data": function(d) {
|
"data": function(d) {
|
||||||
d.rating_key = ${metadata['ratingKey']};
|
d.rating_key = ${data['ratingKey']};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -220,33 +266,38 @@
|
||||||
// Hide the title column
|
// Hide the title column
|
||||||
history_table.column(5).visible(false);
|
history_table.column(5).visible(false);
|
||||||
});
|
});
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
% elif metadata['type'] == 'show':
|
% elif data['type'] == 'show':
|
||||||
<script src="interfaces/default/js/tables/history_table.js"></script>
|
<script src="interfaces/default/js/tables/history_table.js"></script>
|
||||||
<script>
|
<script>
|
||||||
$(document).ready(function () {
|
$(document).ready(function () {
|
||||||
history_table_options.ajax = {
|
history_table_options.ajax = {
|
||||||
"url": "get_history",
|
"url": "get_history",
|
||||||
"data": function(d) {
|
"data": function(d) {
|
||||||
d.grandparent_rating_key = ${metadata['ratingKey']};
|
d.grandparent_rating_key = ${data['ratingKey']};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
history_table = $('#history_table').DataTable(history_table_options);
|
history_table = $('#history_table').DataTable(history_table_options);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
% endif
|
% endif
|
||||||
% if metadata['type'] == 'season':
|
% if data['type'] == 'season':
|
||||||
<script>
|
<script>
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: 'get_children',
|
url: 'get_children',
|
||||||
type: "GET",
|
type: "GET",
|
||||||
async: true,
|
async: true,
|
||||||
data: { rating_key : ${metadata['ratingKey']} },
|
data: { rating_key : ${data['ratingKey']} },
|
||||||
complete: function(xhr, status) {
|
complete: function(xhr, status) {
|
||||||
$("#episode-list").html(xhr.responseText);
|
$("#episode-list").html(xhr.responseText);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
% endif
|
% endif
|
||||||
% endif
|
% endif
|
||||||
|
|
|
@ -1,8 +1,34 @@
|
||||||
% if episode_list != None:
|
<%doc>
|
||||||
% if episode_list['episode_count'] > 0:
|
USAGE DOCUMENTATION :: PLEASE LEAVE THIS AT THE TOP OF THIS FILE
|
||||||
|
|
||||||
|
For Mako templating syntax documentation please visit: http://docs.makotemplates.org/en/latest/
|
||||||
|
|
||||||
|
Filename: info_episode_list.html
|
||||||
|
Version: 0.1
|
||||||
|
Variable names: data [list]
|
||||||
|
|
||||||
|
data :: Usable parameters
|
||||||
|
|
||||||
|
== Global keys ==
|
||||||
|
episode_count Returns the number of episodes in the array.
|
||||||
|
episode_list Returns an array of episodes.
|
||||||
|
|
||||||
|
data['episode_list'] :: Usable paramaters
|
||||||
|
|
||||||
|
== Global keys ==
|
||||||
|
ratingKey Returns the unique identifier for the media item.
|
||||||
|
thumb Returns the location of the item's thumbnail. Use with pms_image_proxy.
|
||||||
|
title Returns the name of the episode.
|
||||||
|
index Returns the episode number.
|
||||||
|
|
||||||
|
DOCUMENTATION :: END
|
||||||
|
</%doc>
|
||||||
|
|
||||||
|
% if data != None:
|
||||||
|
% if data['episode_count'] > 0:
|
||||||
<div class="season-episodes-wrapper">
|
<div class="season-episodes-wrapper">
|
||||||
<ul class="season-episodes-instance">
|
<ul class="season-episodes-instance">
|
||||||
% for a in episode_list['episode_list']:
|
% for a in data['episode_list']:
|
||||||
<li>
|
<li>
|
||||||
<div class="season-episodes-poster">
|
<div class="season-episodes-poster">
|
||||||
<div class="season-episodes-poster-face">
|
<div class="season-episodes-poster-face">
|
||||||
|
|
|
@ -11,11 +11,6 @@
|
||||||
</%def>
|
</%def>
|
||||||
|
|
||||||
<%def name="headerIncludes()">
|
<%def name="headerIncludes()">
|
||||||
<!--<div id="subhead_container">
|
|
||||||
<div id="subhead_menu">
|
|
||||||
<a class="menu_link_edit" href="clearLogs"><i class="fa fa-trash-o"></i> Clear log</a>
|
|
||||||
</div>
|
|
||||||
</div>-->
|
|
||||||
</%def>
|
</%def>
|
||||||
|
|
||||||
<%def name="body()">
|
<%def name="body()">
|
||||||
|
@ -91,5 +86,6 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
</%def>
|
</%def>
|
||||||
|
|
|
@ -1,7 +1,31 @@
|
||||||
% if recently_added != None:
|
<%doc>
|
||||||
|
USAGE DOCUMENTATION :: PLEASE LEAVE THIS AT THE TOP OF THIS FILE
|
||||||
|
|
||||||
|
For Mako templating syntax documentation please visit: http://docs.makotemplates.org/en/latest/
|
||||||
|
|
||||||
|
Filename: recently_added.html
|
||||||
|
Version: 0.1
|
||||||
|
Variable names: data [array]
|
||||||
|
|
||||||
|
data[array_index] :: Usable parameters
|
||||||
|
|
||||||
|
== Global keys ==
|
||||||
|
ratingKey Returns the unique identifier for the media item.
|
||||||
|
type Returns the type of media. Either 'movie' or 'season'.
|
||||||
|
thumb Returns the location of the item's thumbnail. Use with pms_image_proxy.
|
||||||
|
addedAt Returns the time when the media was added to the library.
|
||||||
|
title Returns the name of the movie or season.
|
||||||
|
|
||||||
|
== Only if 'type' is 'movie' ==
|
||||||
|
year Returns the movie release year.
|
||||||
|
|
||||||
|
DOCUMENTATION :: END
|
||||||
|
</%doc>
|
||||||
|
|
||||||
|
% if data != None:
|
||||||
<div class="dashboard-recent-media-row">
|
<div class="dashboard-recent-media-row">
|
||||||
<ul class="dashboard-recent-media">
|
<ul class="dashboard-recent-media">
|
||||||
% for item in recently_added:
|
% for item in data:
|
||||||
<div class="dashboard-recent-media-instance">
|
<div class="dashboard-recent-media-instance">
|
||||||
<li>
|
<li>
|
||||||
<div class="poster">
|
<div class="poster">
|
||||||
|
@ -27,10 +51,14 @@
|
||||||
</div>
|
</div>
|
||||||
<script>
|
<script>
|
||||||
$('#addedAt-${item['ratingKey']}').html('Added ' + moment(${item['addedAt']}, "X").fromNow())
|
$('#addedAt-${item['ratingKey']}').html('Added ' + moment(${item['addedAt']}, "X").fromNow())
|
||||||
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
% endfor
|
% endfor
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
% else:
|
% else:
|
||||||
<div class="muted">There was an error communicating with your Plex Server. Please check your <a href="config">settings</a>.</div><br>
|
<div class="muted">There was an error communicating with your Plex Server. Please check your <a
|
||||||
|
href="config">settings</a>.
|
||||||
|
</div><br>
|
||||||
% endif
|
% endif
|
|
@ -1,3 +1,41 @@
|
||||||
|
<%doc>
|
||||||
|
USAGE DOCUMENTATION :: PLEASE LEAVE THIS AT THE TOP OF THIS FILE
|
||||||
|
|
||||||
|
For Mako templating syntax documentation please visit: http://docs.makotemplates.org/en/latest/
|
||||||
|
|
||||||
|
Filename: stream_data.html
|
||||||
|
Version: 0.1
|
||||||
|
Variable names: data [list]
|
||||||
|
|
||||||
|
data :: Usable parameters
|
||||||
|
|
||||||
|
== Global keys ==
|
||||||
|
media_type Returns the type of session. Either 'episode' or 'movie'.
|
||||||
|
title Returns the name of the episode or movie.
|
||||||
|
user Returns the name of the user.
|
||||||
|
transcode_video_dec Returns the video transcode decision. Either 'transcode', 'copy' or 'direct play'.
|
||||||
|
transcode_video_codec Returns the name of the video codec for the stream.
|
||||||
|
transcode_height Returns the value of the video height for the stream.
|
||||||
|
transcode_width Returns the value of the video width for the stream.
|
||||||
|
transcode_audio_dec Returns the audio transcode decision. Either 'transcode', 'copy' or 'direct play'.
|
||||||
|
transcode_audio_codec Returns the name of the audio codec for the stream.
|
||||||
|
transcode_audio_channels Returns the number of audio channels for the stream.
|
||||||
|
container Returns the type of container for the original media.
|
||||||
|
height Returns the value of the video height for the original media.
|
||||||
|
bitrate Returns the value of the video bitrate for the original media.
|
||||||
|
width Returns the value of the video width for the original media.
|
||||||
|
aspect_ratio Returns the value of the video aspect ratio for the original media.
|
||||||
|
video_framerate Returns the value of the video framerate for the original media.
|
||||||
|
video_codec Returns the name of the video codec for the original media.
|
||||||
|
audio_codec Returns the name of the audio codec for the original media.
|
||||||
|
audio_channels Returns the number of audio channels for the original media.
|
||||||
|
|
||||||
|
== Only if 'media_type' is 'episode' ==
|
||||||
|
grandparent_title Returns the name of the TV Show.
|
||||||
|
|
||||||
|
DOCUMENTATION :: END
|
||||||
|
</%doc>
|
||||||
|
|
||||||
% if data is not None:
|
% if data is not None:
|
||||||
<div class="modal-header">
|
<div class="modal-header">
|
||||||
<button type="button" class="close" data-dismiss="modal" aria-hidden="true"><i class="fa fa-remove"></i></button>
|
<button type="button" class="close" data-dismiss="modal" aria-hidden="true"><i class="fa fa-remove"></i></button>
|
||||||
|
|
|
@ -1,3 +1,20 @@
|
||||||
|
<%doc>
|
||||||
|
USAGE DOCUMENTATION :: PLEASE LEAVE THIS AT THE TOP OF THIS FILE
|
||||||
|
|
||||||
|
For Mako templating syntax documentation please visit: http://docs.makotemplates.org/en/latest/
|
||||||
|
|
||||||
|
Filename: user.html
|
||||||
|
Version: 0.1
|
||||||
|
Variable names: user [string]
|
||||||
|
|
||||||
|
user :: Usable parameters
|
||||||
|
|
||||||
|
user Returns the name of the user.
|
||||||
|
|
||||||
|
DOCUMENTATION :: END
|
||||||
|
|
||||||
|
</%doc>
|
||||||
|
|
||||||
<%inherit file="base.html"/>
|
<%inherit file="base.html"/>
|
||||||
<%!
|
<%!
|
||||||
from plexpy import helpers
|
from plexpy import helpers
|
||||||
|
@ -42,7 +59,8 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div id="user-time-stats" class="user-overview-stats-wrapper">
|
<div id="user-time-stats" class="user-overview-stats-wrapper">
|
||||||
<div class='muted'><i class="fa fa-refresh fa-spin"></i> Loading data...</div><br>
|
<div class='muted'><i class="fa fa-refresh fa-spin"></i> Loading data...</div>
|
||||||
|
<br>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -58,7 +76,8 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div id="user-platform-stats" class="user-platforms">
|
<div id="user-platform-stats" class="user-platforms">
|
||||||
<div class='muted'><i class="fa fa-refresh fa-spin"></i> Loading data...</div><br>
|
<div class='muted'><i class="fa fa-refresh fa-spin"></i> Loading data...</div>
|
||||||
|
<br>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -74,7 +93,8 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div id="user-recently-watched">
|
<div id="user-recently-watched">
|
||||||
<div class='muted'><i class="fa fa-refresh fa-spin"></i> Loading data...</div><br>
|
<div class='muted'><i class="fa fa-refresh fa-spin"></i> Loading data...</div>
|
||||||
|
<br>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -104,9 +124,11 @@
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
</table>
|
</table>
|
||||||
<div id="ip-info-modal" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="ip-info-modal" aria-hidden="true">
|
<div id="ip-info-modal" class="modal hide fade" tabindex="-1" role="dialog"
|
||||||
|
aria-labelledby="ip-info-modal" aria-hidden="true">
|
||||||
<div class="modal-header">
|
<div class="modal-header">
|
||||||
<button type="button" class="close" data-dismiss="modal" aria-hidden="true"><i class="fa fa-remove"></i></button>
|
<button type="button" class="close" data-dismiss="modal" aria-hidden="true"><i
|
||||||
|
class="fa fa-remove"></i></button>
|
||||||
<h3 id="myModalLabel">IP Address: <strong><span id="ip_address"></span></strong></h3>
|
<h3 id="myModalLabel">IP Address: <strong><span id="ip_address"></span></strong></h3>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-body" id="modal-text">
|
<div class="modal-body" id="modal-text">
|
||||||
|
@ -170,7 +192,8 @@
|
||||||
<tbody>
|
<tbody>
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
<div id="info-modal" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="info-modal" aria-hidden="true">
|
<div id="info-modal" class="modal hide fade" tabindex="-1" role="dialog"
|
||||||
|
aria-labelledby="info-modal" aria-hidden="true">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -252,6 +275,8 @@
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
</%def>
|
</%def>
|
||||||
% else:
|
% else:
|
||||||
|
|
|
@ -1,22 +1,47 @@
|
||||||
% if platform_stats != None:
|
<%doc>
|
||||||
% for a in platform_stats:
|
USAGE DOCUMENTATION :: PLEASE LEAVE THIS AT THE TOP OF THIS FILE
|
||||||
|
|
||||||
|
For Mako templating syntax documentation please visit: http://docs.makotemplates.org/en/latest/
|
||||||
|
|
||||||
|
Filename: user_platform_stats.html
|
||||||
|
Version: 0.1
|
||||||
|
Variable names: data [array]
|
||||||
|
|
||||||
|
data[array_index] :: Usable parameters
|
||||||
|
|
||||||
|
== Global keys ==
|
||||||
|
result_id Returns a unique identifier for the result.
|
||||||
|
platform_name Returns the name of the platform.
|
||||||
|
total_plays Returns the play count for the platform.
|
||||||
|
|
||||||
|
DOCUMENTATION :: END
|
||||||
|
</%doc>
|
||||||
|
|
||||||
|
% if data != None:
|
||||||
|
% for a in data:
|
||||||
<ul>
|
<ul>
|
||||||
<div class="user-platforms-instance">
|
<div class="user-platforms-instance">
|
||||||
<li>
|
<li>
|
||||||
<span id="user-platform-image-${a['result_id']}"></span>
|
<span id="user-platform-image-${a['result_id']}"></span>
|
||||||
|
|
||||||
<div class="user-platforms-instance-name">
|
<div class="user-platforms-instance-name">
|
||||||
${a['platform_name']}
|
${a['platform_name']}
|
||||||
</div>
|
</div>
|
||||||
<div class="user-platforms-instance-playcount">
|
<div class="user-platforms-instance-playcount">
|
||||||
<h3>${a['total_plays']}</h3><p> plays</p>
|
<h3>${a['total_plays']}</h3>
|
||||||
|
|
||||||
|
<p> plays</p>
|
||||||
</div>
|
</div>
|
||||||
</li>
|
</li>
|
||||||
</div>
|
</div>
|
||||||
</ul>
|
</ul>
|
||||||
<script>
|
<script>
|
||||||
$("#user-platform-image-${a['result_id']}").html("<img class='user-platforms-instance-poster' src='" + getPlatformImagePath('${a['platform_type']}') + "'>");
|
$("#user-platform-image-${a['result_id']}").html("<img class='user-platforms-instance-poster' src='" + getPlatformImagePath('${a['platform_type']}') + "'>");
|
||||||
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
% endfor
|
% endfor
|
||||||
% else:
|
% else:
|
||||||
<div class="muted">There was an error loading your PlexWatch data. Please check your <a href="config">settings</a>.</div><br>
|
<div class="muted">There was an error loading your PlexWatch data. Please check your <a href="config">settings</a>.
|
||||||
|
</div><br>
|
||||||
% endif
|
% endif
|
|
@ -1,7 +1,35 @@
|
||||||
% if recently_watched != None:
|
<%doc>
|
||||||
|
USAGE DOCUMENTATION :: PLEASE LEAVE THIS AT THE TOP OF THIS FILE
|
||||||
|
|
||||||
|
For Mako templating syntax documentation please visit: http://docs.makotemplates.org/en/latest/
|
||||||
|
|
||||||
|
Filename: user_recently_watched.html
|
||||||
|
Version: 0.1
|
||||||
|
Variable names: data [array]
|
||||||
|
|
||||||
|
data[array_index] :: Usable parameters
|
||||||
|
|
||||||
|
== Global keys ==
|
||||||
|
rating_key Returns the unique identifier for the media item.
|
||||||
|
type Returns the type of media. Either 'movie' or 'episode'.
|
||||||
|
thumb Returns the location of the item's thumbnail. Use with pms_image_proxy.
|
||||||
|
time Returns the last watched time of the media.
|
||||||
|
title Returns the name of the movie or episode.
|
||||||
|
|
||||||
|
== Only if 'type' is 'episode ==
|
||||||
|
parent_index Returns the season number.
|
||||||
|
index Returns the episode number.
|
||||||
|
|
||||||
|
== Only if 'type' is 'movie' ==
|
||||||
|
year Returns the movie release year.
|
||||||
|
|
||||||
|
DOCUMENTATION :: END
|
||||||
|
</%doc>
|
||||||
|
|
||||||
|
% if data != None:
|
||||||
<div class="dashboard-recent-media-row">
|
<div class="dashboard-recent-media-row">
|
||||||
<ul class="dashboard-recent-media">
|
<ul class="dashboard-recent-media">
|
||||||
% for item in recently_watched:
|
% for item in data:
|
||||||
<div class="dashboard-recent-media-instance">
|
<div class="dashboard-recent-media-instance">
|
||||||
<li>
|
<li>
|
||||||
<div class="poster">
|
<div class="poster">
|
||||||
|
@ -27,10 +55,12 @@
|
||||||
</div>
|
</div>
|
||||||
<script>
|
<script>
|
||||||
$('#time-${item['time']}').html('Watched ' + moment(${item['time']}, "X").fromNow())
|
$('#time-${item['time']}').html('Watched ' + moment(${item['time']}, "X").fromNow())
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
% endfor
|
% endfor
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
% else:
|
% else:
|
||||||
<div class="muted">There was an error loading your PlexWatch data. Please check your <a href="config">settings</a>.</div><br>
|
<div class="muted">There was an error loading your PlexWatch data. Please check your <a href="config">settings</a>.
|
||||||
|
</div><br>
|
||||||
% endif
|
% endif
|
|
@ -1,6 +1,24 @@
|
||||||
% if watch_stats != None:
|
<%doc>
|
||||||
|
USAGE DOCUMENTATION :: PLEASE LEAVE THIS AT THE TOP OF THIS FILE
|
||||||
|
|
||||||
|
For Mako templating syntax documentation please visit: http://docs.makotemplates.org/en/latest/
|
||||||
|
|
||||||
|
Filename: user_watch_time_stats.html
|
||||||
|
Version: 0.1
|
||||||
|
Variable names: data [array]
|
||||||
|
|
||||||
|
data[array_index] :: Usable parameters
|
||||||
|
|
||||||
|
== Global keys ==
|
||||||
|
query_days Returns the duration for the watch stats period.
|
||||||
|
total_plays Returns the play count for the watch stat period..
|
||||||
|
|
||||||
|
DOCUMENTATION :: END
|
||||||
|
</%doc>
|
||||||
|
|
||||||
|
% if data != None:
|
||||||
<ul>
|
<ul>
|
||||||
% for a in watch_stats:
|
% for a in data:
|
||||||
<div class='user-overview-stats-instance'>
|
<div class='user-overview-stats-instance'>
|
||||||
<li>
|
<li>
|
||||||
<div class='user-overview-stats-instance-text'>
|
<div class='user-overview-stats-instance-text'>
|
||||||
|
@ -11,16 +29,21 @@
|
||||||
% else:
|
% else:
|
||||||
<h4>Last ${a['query_days']} days</h4>
|
<h4>Last ${a['query_days']} days</h4>
|
||||||
% endif
|
% endif
|
||||||
<h3>${a['total_plays']}</h3><p>plays</p>
|
<h3>${a['total_plays']}</h3>
|
||||||
|
|
||||||
|
<p>plays</p>
|
||||||
<span id="total-time-${a['query_days']}"></span>
|
<span id="total-time-${a['query_days']}"></span>
|
||||||
</div>
|
</div>
|
||||||
</li>
|
</li>
|
||||||
</div>
|
</div>
|
||||||
<script>
|
<script>
|
||||||
$('#total-time-${a['query_days']}').html(humanTime(${a['total_time']}));
|
$('#total-time-${a['query_days']}').html(humanTime(${a['total_time']}));
|
||||||
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
% endfor
|
% endfor
|
||||||
</ul>
|
</ul>
|
||||||
% else:
|
% else:
|
||||||
<div class="muted">There was an error loading your PlexWatch data. Please check your <a href="config">settings</a>.</div><br>
|
<div class="muted">There was an error loading your PlexWatch data. Please check your <a href="config">settings</a>.
|
||||||
|
</div><br>
|
||||||
% endif
|
% endif
|
|
@ -51,5 +51,7 @@
|
||||||
<script src="interfaces/default/js/tables/users.js"></script>
|
<script src="interfaces/default/js/tables/users.js"></script>
|
||||||
<script>
|
<script>
|
||||||
var users_list_table = $('#users_list_table').DataTable(users_list_table_options);
|
var users_list_table = $('#users_list_table').DataTable(users_list_table_options);
|
||||||
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
</%def>
|
</%def>
|
||||||
|
|
|
@ -80,7 +80,7 @@ class WebInterface(object):
|
||||||
plex_watch = plexwatch.PlexWatch()
|
plex_watch = plexwatch.PlexWatch()
|
||||||
stats_data = plex_watch.get_home_stats(time_range)
|
stats_data = plex_watch.get_home_stats(time_range)
|
||||||
|
|
||||||
return serve_template(templatename="home_stats.html", title="Stats", stats=stats_data)
|
return serve_template(templatename="home_stats.html", title="Stats", data=stats_data)
|
||||||
|
|
||||||
@cherrypy.expose
|
@cherrypy.expose
|
||||||
def history(self):
|
def history(self):
|
||||||
|
@ -377,7 +377,6 @@ class WebInterface(object):
|
||||||
cherrypy.response.headers['Content-type'] = 'application/json'
|
cherrypy.response.headers['Content-type'] = 'application/json'
|
||||||
return json.dumps(stream_details)
|
return json.dumps(stream_details)
|
||||||
|
|
||||||
|
|
||||||
@cherrypy.expose
|
@cherrypy.expose
|
||||||
def shutdown(self):
|
def shutdown(self):
|
||||||
return self.do_state_change('shutdown', 'Shutting Down', 15)
|
return self.do_state_change('shutdown', 'Shutting Down', 15)
|
||||||
|
@ -472,12 +471,12 @@ class WebInterface(object):
|
||||||
pms_connect = pmsconnect.PmsConnect()
|
pms_connect = pmsconnect.PmsConnect()
|
||||||
result = pms_connect.get_current_activity()
|
result = pms_connect.get_current_activity()
|
||||||
except:
|
except:
|
||||||
return serve_template(templatename="current_activity.html", activity=None)
|
return serve_template(templatename="current_activity.html", data=None)
|
||||||
|
|
||||||
if result:
|
if result:
|
||||||
return serve_template(templatename="current_activity.html", activity=result)
|
return serve_template(templatename="current_activity.html", data=result)
|
||||||
else:
|
else:
|
||||||
return serve_template(templatename="current_activity.html", activity=None)
|
return serve_template(templatename="current_activity.html", data=None)
|
||||||
logger.warn('Unable to retrieve data.')
|
logger.warn('Unable to retrieve data.')
|
||||||
|
|
||||||
@cherrypy.expose
|
@cherrypy.expose
|
||||||
|
@ -487,12 +486,12 @@ class WebInterface(object):
|
||||||
pms_connect = pmsconnect.PmsConnect()
|
pms_connect = pmsconnect.PmsConnect()
|
||||||
result = pms_connect.get_current_activity()
|
result = pms_connect.get_current_activity()
|
||||||
except IOError, e:
|
except IOError, e:
|
||||||
return serve_template(templatename="current_activity_header.html", activity=None)
|
return serve_template(templatename="current_activity_header.html", data=None)
|
||||||
|
|
||||||
if result:
|
if result:
|
||||||
return serve_template(templatename="current_activity_header.html", activity=result['stream_count'])
|
return serve_template(templatename="current_activity_header.html", data=result['stream_count'])
|
||||||
else:
|
else:
|
||||||
return serve_template(templatename="current_activity_header.html", activity=None)
|
return serve_template(templatename="current_activity_header.html", data=None)
|
||||||
logger.warn('Unable to retrieve data.')
|
logger.warn('Unable to retrieve data.')
|
||||||
|
|
||||||
@cherrypy.expose
|
@cherrypy.expose
|
||||||
|
@ -502,12 +501,12 @@ class WebInterface(object):
|
||||||
pms_connect = pmsconnect.PmsConnect()
|
pms_connect = pmsconnect.PmsConnect()
|
||||||
result = pms_connect.get_recently_added_details(count)
|
result = pms_connect.get_recently_added_details(count)
|
||||||
except IOError, e:
|
except IOError, e:
|
||||||
return serve_template(templatename="recently_added.html", recently_added=None)
|
return serve_template(templatename="recently_added.html", data=None)
|
||||||
|
|
||||||
if result:
|
if result:
|
||||||
return serve_template(templatename="recently_added.html", recently_added=result['recently_added'])
|
return serve_template(templatename="recently_added.html", data=result['recently_added'])
|
||||||
else:
|
else:
|
||||||
return serve_template(templatename="recently_added.html", recently_added=None)
|
return serve_template(templatename="recently_added.html", data=None)
|
||||||
logger.warn('Unable to retrieve data.')
|
logger.warn('Unable to retrieve data.')
|
||||||
|
|
||||||
@cherrypy.expose
|
@cherrypy.expose
|
||||||
|
@ -532,9 +531,9 @@ class WebInterface(object):
|
||||||
result = pms_connect.get_metadata_details(rating_key)
|
result = pms_connect.get_metadata_details(rating_key)
|
||||||
|
|
||||||
if result:
|
if result:
|
||||||
return serve_template(templatename="info.html", metadata=result['metadata'], title="Info")
|
return serve_template(templatename="info.html", data=result['metadata'], title="Info")
|
||||||
else:
|
else:
|
||||||
return serve_template(templatename="info.html", metadata='', title="Info")
|
return serve_template(templatename="info.html", data=None, title="Info")
|
||||||
logger.warn('Unable to retrieve data.')
|
logger.warn('Unable to retrieve data.')
|
||||||
|
|
||||||
@cherrypy.expose
|
@cherrypy.expose
|
||||||
|
@ -544,9 +543,11 @@ class WebInterface(object):
|
||||||
result = plex_watch.get_recently_watched(user, limit)
|
result = plex_watch.get_recently_watched(user, limit)
|
||||||
|
|
||||||
if result:
|
if result:
|
||||||
return serve_template(templatename="user_recently_watched.html", recently_watched=result, title="Recently Watched")
|
return serve_template(templatename="user_recently_watched.html", data=result,
|
||||||
|
title="Recently Watched")
|
||||||
else:
|
else:
|
||||||
return serve_template(templatename="user_recently_watched.html", recently_watched=None, title="Recently Watched")
|
return serve_template(templatename="user_recently_watched.html", data=None,
|
||||||
|
title="Recently Watched")
|
||||||
logger.warn('Unable to retrieve data.')
|
logger.warn('Unable to retrieve data.')
|
||||||
|
|
||||||
@cherrypy.expose
|
@cherrypy.expose
|
||||||
|
@ -556,9 +557,9 @@ class WebInterface(object):
|
||||||
result = plex_watch.get_user_watch_time_stats(user)
|
result = plex_watch.get_user_watch_time_stats(user)
|
||||||
|
|
||||||
if result:
|
if result:
|
||||||
return serve_template(templatename="user_watch_time_stats.html", watch_stats=result, title="Watch Stats")
|
return serve_template(templatename="user_watch_time_stats.html", data=result, title="Watch Stats")
|
||||||
else:
|
else:
|
||||||
return serve_template(templatename="user_watch_time_stats.html", watch_stats=None, title="Watch Stats")
|
return serve_template(templatename="user_watch_time_stats.html", data=None, title="Watch Stats")
|
||||||
logger.warn('Unable to retrieve data.')
|
logger.warn('Unable to retrieve data.')
|
||||||
|
|
||||||
@cherrypy.expose
|
@cherrypy.expose
|
||||||
|
@ -568,9 +569,10 @@ class WebInterface(object):
|
||||||
result = plex_watch.get_user_platform_stats(user)
|
result = plex_watch.get_user_platform_stats(user)
|
||||||
|
|
||||||
if result:
|
if result:
|
||||||
return serve_template(templatename="user_platform_stats.html", platform_stats=result, title="Platform Stats")
|
return serve_template(templatename="user_platform_stats.html", data=result,
|
||||||
|
title="Platform Stats")
|
||||||
else:
|
else:
|
||||||
return serve_template(templatename="user_platform_stats.html", platform_stats=None, title="Platform Stats")
|
return serve_template(templatename="user_platform_stats.html", data=None, title="Platform Stats")
|
||||||
logger.warn('Unable to retrieve data.')
|
logger.warn('Unable to retrieve data.')
|
||||||
|
|
||||||
@cherrypy.expose
|
@cherrypy.expose
|
||||||
|
@ -580,9 +582,9 @@ class WebInterface(object):
|
||||||
result = pms_connect.get_season_children(rating_key)
|
result = pms_connect.get_season_children(rating_key)
|
||||||
|
|
||||||
if result:
|
if result:
|
||||||
return serve_template(templatename="info_episode_list.html", episode_list=result, title="Episode List")
|
return serve_template(templatename="info_episode_list.html", data=result, title="Episode List")
|
||||||
else:
|
else:
|
||||||
return serve_template(templatename="info_episode_list.html", episode_list=None, title="Episode List")
|
return serve_template(templatename="info_episode_list.html", data=None, title="Episode List")
|
||||||
logger.warn('Unable to retrieve data.')
|
logger.warn('Unable to retrieve data.')
|
||||||
|
|
||||||
@cherrypy.expose
|
@cherrypy.expose
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue