Merge pull request #252 from JonnyWong16/miscellaneous-fixes

Miscellaneous fixes
This commit is contained in:
drzoidberg33 2015-10-16 16:40:23 +02:00
commit ddc9563de9
5 changed files with 113 additions and 98 deletions

View file

@ -1518,7 +1518,7 @@ a:hover .item-children-poster {
} }
.user-overview-stats-instance { .user-overview-stats-instance {
float: left; float: left;
width: 350px; width: 400px;
height: 80px; height: 80px;
margin-bottom: 25px; margin-bottom: 25px;
} }
@ -1531,7 +1531,7 @@ a:hover .item-children-poster {
.user-overview-stats-instance li { .user-overview-stats-instance li {
float: left; float: left;
list-style: none; list-style: none;
width: 340px; width: 100%;
height: 90px; height: 90px;
} }
.user-overview-stats-instance-text { .user-overview-stats-instance-text {

View file

@ -65,7 +65,7 @@ DOCUMENTATION :: END
%> %>
% if data: % if data:
% if data[0]['rows']: % if data[0]['stat_id']:
<ul class="list-unstyled"> <ul class="list-unstyled">
% for top_stat in data: % for top_stat in data:
% if top_stat['stat_id'] == 'top_tv' and top_stat['rows']: % if top_stat['stat_id'] == 'top_tv' and top_stat['rows']:

View file

@ -841,94 +841,106 @@ available_notification_agents = notifiers.available_notification_agents()
</p> </p>
<table> <table>
<tbody> <tbody>
<tr> <tr>
<td width="150"><strong>{user}</strong></td> <td width="150"><strong>{server_name}</strong></td>
<td>The username of the person streaming.</td> <td>The name of your Plex Server.</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{server_name}</strong></td> <td width="150"><strong>{user}</strong></td>
<td>The name of your Plex Server.</td> <td>The username of the person streaming.</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{player}</strong></td> <td width="150"><strong>{platform}</strong></td>
<td>The name of the device being used for playback.</td> <td>The type of client being used for playback.</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{platform}</strong></td> <td width="150"><strong>{player}</strong></td>
<td>The type of client being used for playback.</td> <td>The name of the device being used for playback.</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{title}</strong></td> <td width="150"><strong>{media_type}</strong></td>
<td>The title of the item being played back.</td> <td>The type of media being played (movie, episode, track).</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{show_name}</strong></td> <td width="150"><strong>{title}</strong></td>
<td>The title of the TV series being played back.</td> <td>The title of the item being played.</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{episode_name}</strong></td> <td width="150"><strong>{show_name}</strong></td>
<td>The title of the episode being played back.</td> <td>The title of the TV series being played.</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{album_name}</strong></td> <td width="150"><strong>{episode_name}</strong></td>
<td>The title of the album being played back if item is track.</td> <td>The title of the episode being played.</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{transcode_decision}</strong></td> <td width="150"><strong>{artist_name}</strong></td>
<td>The transcode decisions for the media item.</td> <td>The name of the artist being played.</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{year}</strong></td> <td width="150"><strong>{album_name}</strong></td>
<td>The release year for the media item.</td> <td>The title of the album being played.</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{studio}</strong></td> <td width="150"><strong>{season_num}</strong></td>
<td>The studio for the media item.</td> <td>The season number for the media item if item is episode.</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{content_rating}</strong></td> <td width="150"><strong>{season_num00}</strong></td>
<td>The content rating for the media item. E.g. TV-MA, TV-PG, etc.</td> <td>The two digit season number.</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{summary}</strong></td> <td width="150"><strong>{episode_num}</strong></td>
<td>A short plot summary for the media item.</td> <td>The episode number for the media item if item is episode.</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{season_num}</strong></td> <td width="150"><strong>{episode_num00}</strong></td>
<td>The season number for the media item if item is episode.</td> <td>The two digit episode number.</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{season_num00}</strong></td> <td width="150"><strong>{transcode_decision}</strong></td>
<td>The two digit season number.</td> <td>The transcode decisions for the media item.</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{episode_num}</strong></td> <td width="150"><strong>{year}</strong></td>
<td>The episode number for the media item if item is episode.</td> <td>The release year for the media item.</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{episode_num00}</strong></td> <td width="150"><strong>{studio}</strong></td>
<td>The two digit episode number.</td> <td>The studio for the media item.</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{rating}</strong></td> <td width="150"><strong>{content_rating}</strong></td>
<td>The rating (out of 10) for the item.</td> <td>The content rating for the media item. (e.g. TV-MA, TV-PG, etc.)</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{duration}</strong></td> <td width="150"><strong>{summary}</strong></td>
<td>The duration (in minutes) for the item.</td> <td>A short plot summary for the media item.</td>
</tr> </tr>
<tr>
<td width="150"><strong>{rating}</strong></td>
<td>The rating (out of 10) for the item.</td>
</tr>
<tr>
<td width="150"><strong>{duration}</strong></td>
<td>The duration (in minutes) for the item.</td>
</tr>
<tr> <tr>
<td width="150"><strong>{stream_duration}</strong></td> <td width="150"><strong>{stream_duration}</strong></td>
<td>The stream duration (in minutes) for the item.</td> <td>The stream duration (in minutes) for the item.</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{progress}</strong></td> <td width="150"><strong>{remaining_duration}</strong></td>
<td>The last reported offset (in minutes) for the item.</td> <td>The remaining duration (in minutes) for the item.</td>
</tr> </tr>
<tr> <tr>
<td width="150"><strong>{progress_percent}</strong></td> <td width="150"><strong>{progress}</strong></td>
<td>The last reported progress percent for the item.</td> <td>The last reported offset (in minutes) for the item.</td>
</tr> </tr>
<tr>
<td width="150"><strong>{progress_percent}</strong></td>
<td>The last reported progress percent for the item.</td>
</tr>
</tbody> </tbody>
</table> </table>
</div> </div>

View file

@ -32,13 +32,14 @@ DOCUMENTATION :: END
<h3>${a['total_plays']}</h3> <h3>${a['total_plays']}</h3>
<p>plays</p> <p>plays</p>
<h3><strong>/</strong></h3> <h3><strong>/</strong></h3>
<span id="total-time-${a['query_days']}"></span> <span id="total-time-${a['query_days']}">
<script>
$('#total-time-${a['query_days']}').html(humanTime(${a['total_time']}));
</script>
</span>
</div> </div>
</li> </li>
</div> </div>
<script>
$('#total-time-${a['query_days']}').html(humanTime(${a['total_time']}));
</script>
% endfor % endfor
</ul> </ul>
% else: % else:

View file

@ -320,25 +320,27 @@ def build_notify_text(session, state):
available_params = {'server_name': server_name, available_params = {'server_name': server_name,
'user': session['friendly_name'], 'user': session['friendly_name'],
'platform': session['platform'],
'player': session['player'], 'player': session['player'],
'media_type': session['media_type'],
'title': full_title, 'title': full_title,
'show_name': item_metadata['grandparent_title'], 'show_name': item_metadata['grandparent_title'],
'episode_name': item_metadata['title'], 'episode_name': item_metadata['title'],
'platform': session['platform'], 'artist_name': item_metadata['grandparent_title'],
'media_type': session['media_type'], 'album_name': item_metadata['parent_title'],
'season_num': item_metadata['parent_index'],
'season_num00': item_metadata['parent_index'].zfill(2),
'episode_num': item_metadata['index'],
'episode_num00': item_metadata['index'].zfill(2),
'transcode_decision': transcode_decision, 'transcode_decision': transcode_decision,
'year': item_metadata['year'], 'year': item_metadata['year'],
'studio': item_metadata['studio'], 'studio': item_metadata['studio'],
'content_rating': item_metadata['content_rating'], 'content_rating': item_metadata['content_rating'],
'summary': item_metadata['summary'], 'summary': item_metadata['summary'],
'season_num': item_metadata['parent_index'],
'season_num00': item_metadata['parent_index'].zfill(2),
'episode_num': item_metadata['index'],
'episode_num00': item_metadata['index'].zfill(2),
'album_name': item_metadata['parent_title'],
'rating': item_metadata['rating'], 'rating': item_metadata['rating'],
'duration': duration, 'duration': duration,
'stream_duration': stream_duration, 'stream_duration': stream_duration,
'remaining_duration': duration - view_offset,
'progress': view_offset, 'progress': view_offset,
'progress_percent': progress_percent 'progress_percent': progress_percent
} }