mirror of
https://github.com/evilhero/mylar
synced 2024-12-23 16:22:45 +00:00
171 lines
8.9 KiB
HTML
171 lines
8.9 KiB
HTML
|
<%inherit file="base.html"/>
|
||
|
<%!
|
||
|
from mylar import db
|
||
|
import mylar
|
||
|
%>
|
||
|
|
||
|
<%def name="headerIncludes()">
|
||
|
<div id="subhead_container">
|
||
|
<div id="subhead_menu">
|
||
|
<a id="menu_link_refresh" href="manualpull">Refresh Pull-list</a>
|
||
|
%if pullfilter is False:
|
||
|
<a id="menu_link_delete" href="filterpull">Filter Non-Comics</a>
|
||
|
%else:
|
||
|
<a id="menu_link_delete" href="pullist">Show All Comics</a>
|
||
|
%endif
|
||
|
</div>
|
||
|
</div>
|
||
|
<a href="home" class="back">« Back to overview</a>
|
||
|
</%def>
|
||
|
|
||
|
<%def name="body()">
|
||
|
<div id="artistheader" class="clearfix">
|
||
|
<h1>Weekly Pull list for : ${pulldate}</h1>
|
||
|
</div>
|
||
|
|
||
|
<form action="markissues" method="get" id="markissues">
|
||
|
<input type="hidden" name="DATE" value="August 2012">
|
||
|
<div id="markissue">Mark selected issues as
|
||
|
<select name="action" onChange="doAjaxCall('markissues',$(this),'table',true);" data-error="You didn't select any issues">
|
||
|
<option disabled="disabled" selected="selected">Choose...</option>
|
||
|
<option value="Wanted">Wanted</option>
|
||
|
<option value="WantedNew">Wanted (new only)</option>
|
||
|
<option value="Skipped">Skipped</option>
|
||
|
<option value="Downloaded">Downloaded</option>
|
||
|
</select>
|
||
|
<input type="hidden" value="Go">
|
||
|
</div>
|
||
|
<table class="display" id="pull_table">
|
||
|
<thead>
|
||
|
<tr>
|
||
|
<th id="select"><input type="checkbox" onClick="toggle(this)" /></th>
|
||
|
<th id="publisher">Publisher</th>
|
||
|
<th id="comicname">COMIC</th>
|
||
|
<th id="comicnumber">Number</th>
|
||
|
%if pullfilter is False:
|
||
|
<th id="type">Type</th>
|
||
|
%endif
|
||
|
<th id="status">Status</th>
|
||
|
<th id="series">Series</th>
|
||
|
</tr>
|
||
|
</thead>
|
||
|
<tbody>
|
||
|
%for weekly in weeklyresults:
|
||
|
<%
|
||
|
if weekly['STATUS'] == 'Skipped':
|
||
|
grade = 'X'
|
||
|
elif weekly['STATUS'] == 'Wanted':
|
||
|
grade = 'A'
|
||
|
elif weekly['STATUS'] == 'Snatched':
|
||
|
grade = 'C'
|
||
|
else:
|
||
|
grade = 'Z'
|
||
|
%>
|
||
|
<tr class="grade${grade}">
|
||
|
%if pullfilter is True:
|
||
|
%if str(weekly['ISSUE']).isdigit() > 0:
|
||
|
<td id="select"><input type="checkbox" name="${weekly['COMIC']}" class="checkbox" /></td>
|
||
|
<td id="publisher">${weekly['PUBLISHER']}</td>
|
||
|
<td id="comicname">${weekly['COMIC']}
|
||
|
</td>
|
||
|
<td id="comicnumber">${weekly['ISSUE']}</td>
|
||
|
<td id="status">${weekly['STATUS']}
|
||
|
%if weekly['STATUS'] == 'Skipped':
|
||
|
[<a href="#" onclick="doAjaxCall('queueissue?ComicName=${weekly['COMIC']}&ComicIssue=${weekly['ISSUE']}&mode=want',$(this),'table')" data-success="'${weekly['COMIC']}' #'${weekly['ISSUE']}' marked as wanted">want</a>]
|
||
|
<td id="add"><a href="searchit?name=${weekly['COMIC']}&issue=${weekly['ISSUE']}&mode=pullseries"><span class="ui-icon ui-icon-plus"></span>add series</a></td>
|
||
|
%elif (weekly['STATUS'] == 'Wanted'):
|
||
|
[<a href="#" onclick="doAjaxCall('unqueueissue?IssueID=${weekly['COMIC']}&ComicID=${weekly['ISSUE']}',$(this),'table')" data-success="'${weekly['COMIC']}' skipped">skip</a>]
|
||
|
%else:
|
||
|
[<a href="#" onclick="doAjaxCall('queueissue?IssueID=${weekly['COMIC']}&ComicID=${weekly['ISSUE']}', $(this),'table')" data-success="Retrying the same version of '${weekly['COMIC']}'" title="Retry the same download again">retry</a>][<a href="#" onclick="doAjaxCall('queueissue?issueID=${weekly['COMIC']}&ComicID=${weekly['ISSUE']}&new=True', $(this),'table')" title="Try a new download, skipping all previously tried nzbs" data-success="Downloading new version for '${weekly['NAME']}'" data-success="Looking for a new version of '${weekly['NAME']}'">new</a>]
|
||
|
%endif
|
||
|
</td>
|
||
|
%endif
|
||
|
%elif pullfilter is False:
|
||
|
<td id="select"><input type="checkbox" name="${weekly['COMIC']}" class="checkbox" /></td>
|
||
|
<td id="publisher">${weekly['PUBLISHER']}</td>
|
||
|
<td id="comicname">${weekly['COMIC']}</a></td>
|
||
|
%if str(weekly['ISSUE']).isdigit() > 0:
|
||
|
<td id="comicnumber">${weekly['ISSUE']}</td>
|
||
|
%else:
|
||
|
<td id="comicnumber"> </td>
|
||
|
%endif
|
||
|
%if str(weekly['ISSUE']).isdigit() > 0:
|
||
|
<td id="type"> </td>
|
||
|
%else:
|
||
|
<td id="type">${weekly['ISSUE']}</td>
|
||
|
%endif
|
||
|
%if str(weekly['ISSUE']).isdigit() > 0:
|
||
|
<td id="status">${weekly['STATUS']}
|
||
|
%if weekly['STATUS'] == 'Skipped':
|
||
|
[<a href="#" onclick="doAjaxCall('queueissue?ComicName=${weekly['COMIC']}&ComicIssue=${weekly['ISSUE']}&mode=want',$(this),'table')" data-success="'${weekly['COMIC']}' #'${weekly['ISSUE']}' marked as wanted">want</a>]
|
||
|
<td id="add"><a href="searchit?name=${weekly['COMIC']}&issue=${weekly['ISSUE']}&mode=pullseries"><span class="ui-icon ui-icon-plus"></span>add series</a></td>
|
||
|
%elif (weekly['STATUS'] == 'Wanted'):
|
||
|
[<a href="#" onclick="doAjaxCall('unqueueissue?IssueID=${weekly['COMIC']}&ComicID=${weekly['ISSUE']}',$(this),'table')" data-success="'${weekly['COMIC']}' skipped">skip</a>]
|
||
|
%else:
|
||
|
[<a href="#" onclick="doAjaxCall('queueissue?IssueID=${weekly['COMIC']}&ComicID=${weekly['ISSUE']}', $(this),'table')" data-success="Retrying the same version of '${weekly['COMIC']}'" title="Retry the same download again">retry</a>][<a href="#" onclick="doAjaxCall('queueissue?issueID=${weekly['COMIC']}&ComicID=${weekly['ISSUE']}&new=True', $(this),'table')" title="Try a new download, skipping all previously tried nzbs" data-success="Downloading new version for '${weekly['NAME']}'" data-success="Looking for a new version of '${weekly['NAME']}'">new</a>]
|
||
|
%endif
|
||
|
%else:
|
||
|
<td id ="status">${weekly['STATUS']}
|
||
|
%if weekly['STATUS'] == 'Skipped':
|
||
|
[<a href="#" onclick="doAjaxCall('queueissue?ComicName=${weekly['COMIC']}&ComicIssue=${weekly['ISSUE']}&mode=want',$(this),'table')" data-success="'${weekly['COMIC']}' #'${weekly['ISSUE']}' marked as wanted">want</a>]
|
||
|
%elif (weekly['STATUS'] == 'Wanted'):
|
||
|
[<a href="#" onclick="doAjaxCall('unqueueissue?IssueID=${weekly['COMIC']}&ComicID=${weekly['ISSUE']}',$(this),'table')" data-success="'${weekly['COMIC']}' skipped">skip</a>]
|
||
|
%endif
|
||
|
%endif
|
||
|
%endif
|
||
|
</tr>
|
||
|
%endfor
|
||
|
</tbody>
|
||
|
</table>
|
||
|
</form>
|
||
|
</%def>
|
||
|
|
||
|
<%def name="headIncludes()">
|
||
|
<link rel="stylesheet" href="interfaces/default/css/data_table.css">
|
||
|
</%def>
|
||
|
|
||
|
<%def name="javascriptIncludes()">
|
||
|
<script src="js/libs/jquery.dataTables.min.js"></script>
|
||
|
|
||
|
<script>
|
||
|
|
||
|
|
||
|
function initThisPage()
|
||
|
{
|
||
|
initActions();
|
||
|
$('#weekly_table').dataTable({
|
||
|
"bDestroy": true,
|
||
|
"aoColumns": [
|
||
|
null,
|
||
|
null,
|
||
|
null,
|
||
|
null,
|
||
|
null,
|
||
|
null
|
||
|
|
||
|
],
|
||
|
"aoColumnDefs": [
|
||
|
{ 'bSortable': false, 'aTargets': [ 0,1 ] }
|
||
|
],
|
||
|
"oLanguage": {
|
||
|
"sLengthMenu":"Show _MENU_ issues per page",
|
||
|
"sEmptyTable": "No issue information available",
|
||
|
"sInfo":"Showing _TOTAL_ issues",
|
||
|
"sInfoEmpty":"Showing 0 to 0 of 0 issues",
|
||
|
"sInfoFiltered":"(filtered from _MAX_ total issues)",
|
||
|
"sSearch": ""},
|
||
|
"bPaginate": false,
|
||
|
"aaSorting": [[1, 'desc'],[2,'desc']]
|
||
|
});
|
||
|
setTimeout(function(){
|
||
|
initFancybox();
|
||
|
},1500)
|
||
|
}
|
||
|
|
||
|
$(document).ready(function() {
|
||
|
initThisPage();
|
||
|
});
|
||
|
|
||
|
</script>
|
||
|
</%def>
|