Two digit season and episode numbers for notifications.

This commit is contained in:
JonnyWong16 2015-08-16 23:24:52 -07:00
parent bbcf3bf7da
commit b5ad88ae5a
2 changed files with 10 additions and 0 deletions

View file

@ -810,10 +810,18 @@ available_notification_agents = notifiers.available_notification_agents()
<td width="150"><strong>{season_num}</strong></td>
<td>The season number for the media item if item is episode.</td>
</tr>
<tr>
<td width="150"><strong>{season_num00}</strong></td>
<td>The two digit season number.</td>
</tr>
<tr>
<td width="150"><strong>{episode_num}</strong></td>
<td>The episode number for the media item if item is episode.</td>
</tr>
<tr>
<td width="150"><strong>{episode_num00}</strong></td>
<td>The two digit episode number.</td>
</tr>
<tr>
<td width="150"><strong>{rating}</strong></td>
<td>The rating (out of 10) for the item.</td>

View file

@ -317,7 +317,9 @@ def build_notify_text(session, state):
'content_rating': item_metadata['content_rating'],
'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'],
'duration': duration,