Files
JellyPy/data/interfaces/default/recently_added.html
Tim 7d9934e4b6 Allow info pages to be pulled from the db instead of the Plex Server, useful for media that has been deleted.
Fix home stats user link if user has no id.
Fix bug in PlexWatch import script which switched around the episode and show titles.
2015-07-25 12:40:38 +02:00

66 lines
2.5 KiB
HTML

<%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 ==
rating_key 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.
added_at 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">
<ul class="dashboard-recent-media">
% for item in data:
<div class="dashboard-recent-media-instance">
<li>
<div class="poster">
% if item['type'] == 'season' or item['type'] == 'movie':
<div class="poster-face">
<a href="info?item_id=${item['rating_key']}">
<img src="pms_image_proxy?img=${item['thumb']}&width=153&height=225&fallback=poster" class="poster-face">
</a>
</div>
% elif item['type'] == 'album':
<div class="cover-face">
<img src="pms_image_proxy?img=${item['thumb']}&width=153&height=153&fallback=cover" class="cover-face">
</div>
% endif
</div>
<div class="dashboard-recent-media-metacontainer">
% if item['type'] == 'season' or item['type'] == 'album':
<h3>${item['title']}</h3>
% elif item['type'] == 'movie':
<h3>${item['title']} (${item['year']})</h3>
% endif
<div class="muted" id="added_at-${item['rating_key']}">${item['added_at']}</div>
</div>
</li>
</div>
<script>
$('#added_at-${item['rating_key']}').html('Added ' + moment(${item['added_at']}, "X").fromNow())
</script>
% endfor
</ul>
</div>
% else:
<div class="muted">There was an error communicating with your Plex Server. Please check your <a
href="config">settings</a>.
</div><br>
% endif