2012-09-13 15:27:34 +00:00
< %inherit file="base.html"/>
< %!
2013-02-17 10:31:18 +00:00
import os
2012-09-13 15:27:34 +00:00
from mylar import db
import mylar
%>
< %def name="headerIncludes()">
< div id = "subhead_container" >
< div id = "subhead_menu" >
< a id = "menu_link_refresh" onclick = "doAjaxCall('refreshArtist?ComicID=${comic['ComicID']}', $(this)),'table'" href = "#" data-success = "'${comic['ComicName']}' is being refreshed" > Refresh Comic< / a >
< a id = "menu_link_delete" href = "deleteArtist?ComicID=${comic['ComicID']}" > Delete Comic< / a >
2013-03-08 03:07:14 +00:00
%if mylar.RENAME_FILES:
< a id = "menu_link_refresh" onclick = "doAjaxCall('manualRename?comicid=${comic['ComicID']}', $(this),'table')" data-success = "Renaming files." > Rename Files< / a >
%endif
2012-09-13 15:27:34 +00:00
< a id = "menu_link_refresh" onclick = "doAjaxCall('forceRescan?ComicID=${comic['ComicID']}', $(this)),'table'" href = "#" data-success = "'${comic['ComicName']}' is being refreshed" > Recheck Files< / a >
%if comic['Status'] == 'Paused':
< a id = "menu_link_resume" href = "#" onclick = "doAjaxCall('resumeArtist?ComicID=${comic['ComicID']}',$(this),true)" data-success = "${comic['ComicName']} resumed" > Resume Comic< / a >
%else:
< a id = "menu_link_pauze" href = "#" onclick = "doAjaxCall('pauseArtist?ComicID=${comic['ComicID']}',$(this),true)" data-success = "${comic['ComicName']} paused" > Pause Comic< / a >
%endif
< / div >
< / div >
< /%def>
< %def name="body()">
< div id = "paddingheader" >
< h1 >
%if comic['Status'] == 'Loading':
< img src = "interfaces/default/images/loader_black.gif" alt = "loading" style = "float:left; margin-right: 5px;" / >
%endif
< div class = "row" >
2013-03-13 01:41:45 +00:00
FIX:(#304) Index out of range on recheck, FIX:(#303) Comicvine link updated on details page, FIX:(#302) Query rate (Search Delay) Added as a configuration option, FIX:(#300) Version number error on searching when no version number, FIX:(#297) Manual Rename of Files working, FIX:(#294) 'AU' issue problems should be resolved now, FIX:(#290) V#(year) and Vol#(year) added to filechecking, IMP: ComicVine data use only now as a hidden option (cv_only = 1 in config.ini), IMP: added as options for file naming, IMP: Rough drafting of Annuals (annuals_on = 1 in config.ini), Other fixes..
2013-04-06 09:43:18 +00:00
< a href = "${comic['DetailURL']}" target = "_blank" > ${comic['ComicName']} (${comic['ComicYear']})< / a >
2013-03-13 01:41:45 +00:00
%if comic['Status'] == 'Loading':
< h3 > < i > (Comic information is currently being loaded)< / i > < / h3 >
%endif
2012-09-13 15:27:34 +00:00
< / div >
< / h1 >
2013-03-13 01:41:45 +00:00
< div style = "z-index:10; position: absolute; right: 0; top: 10;" >
< a href = "artistPage?ComicID=${series['Previous']}" > < img src = "interfaces/default/images/prev.gif" width = "16" height = "18" / > < / a >
< a href = "artistPage?ComicID=${series['Next']}" > < img src = "interfaces/default/images/next.gif" width = "16" height = "18" / > < / a >
< / div >
2012-09-13 15:27:34 +00:00
< / div >
< div id = "tabs" >
< ul >
< li > < a href = "#tabs-1" > Comic Details< / a > < / li >
< li > < a href = "#tabs-2" > Download settings< / a > < / li >
< li > < a href = "#tabs-3" > Edit Settings< / a > < / li >
< / ul >
< div id = "tabs-1" >
< table class = "comictable" summary = "Comic Details" >
< tr >
< td id = "mainimg" >
< fieldset >
< div id = "artistImg" >
2012-10-30 10:43:01 +00:00
< img src = "${comic['ComicImage']}" alt = "" height = "400" width = "263" / >
2012-09-13 15:27:34 +00:00
< / div >
< / fieldset >
2013-07-02 05:50:14 +00:00
< / td >
2012-10-25 06:46:24 +00:00
< td width = "100%" padding = "10" >
2012-09-13 15:27:34 +00:00
%if comic['ComicPublisher'] == 'DC Comics':
2013-04-22 03:11:12 +00:00
< img src = "interfaces/default/images/publisherlogos/logo-dccomics.png" align = "right" alt = "DC" height = "50" width = "50" / >
2012-09-13 15:27:34 +00:00
%elif comic['ComicPublisher'] == 'Marvel':
2013-04-22 03:11:12 +00:00
< img src = "interfaces/default/images/publisherlogos/logo-marvel.jpg" align = "right" alt = "Marvel" height = "50" width = "100" / >
2012-09-13 15:27:34 +00:00
%elif comic['ComicPublisher'] == 'Image':
2013-04-22 03:11:12 +00:00
< img src = "interfaces/default/images/publisherlogos/logo-imagecomics.png" align = "right" alt = "Image" height = "100" width = "50" / >
%elif comic['ComicPublisher'] == 'Dark Horse Comics' or comic['ComicPublisher'] == 'Dark Horse':
< img src = "interfaces/default/images/publisherlogos/logo-darkhorse.png" align = "right" alt = "Darkhorse" height = "100" width = "75" / >
2012-09-13 15:27:34 +00:00
%elif comic['ComicPublisher'] == 'IDW Publishing':
2013-04-22 03:11:12 +00:00
< img src = "interfaces/default/images/publisherlogos/logo-idwpublish.png" align = "right" alt = "IDW" height = "50" width = "100" / >
%elif comic['ComicPublisher'] == 'Icon':
< img src = "interfaces/default/images/publisherlogos/logo-iconcomics.png" align = "right" alt = "Icon" height = "50" width = "100" / >
%elif comic['ComicPublisher'] == 'Red5':
< img src = "interfaces/default/images/publisherlogos/logo-red5comics.png" align = "right" alt = "Red5" height = "50" width = "100" / >
%elif comic['ComicPublisher'] == 'Vertigo':
< img src = "interfaces/default/images/publisherlogos/logo-vertigo.jpg" align = "right" alt = "Vertigo" height = "50" width = "100" / >
%elif comic['ComicPublisher'] == 'ShadowLine':
< img src = "interfaces/default/images/publisherlogos/logo-shadowline.png" align = "right" alt = "Shadowline" height = "75" width = "100" / >
%elif comic['ComicPublisher'] == 'Archie Comics':
< img src = "interfaces/default/images/publisherlogos/logo-archiecomics.jpg" align = "right" alt = "Archie" height = "50" width = "100" / >
%elif comic['ComicPublisher'] == 'Oni Press':
< img src = "interfaces/default/images/publisherlogos/logo-onipress.png" align = "right" alt = "Oni Press" height = "50" width = "100" / >
%elif comic['ComicPublisher'] == 'Tokyopop':
< img src = "interfaces/default/images/publisherlogos/logo-tokyopop.jpg" align = "right" alt = "Tokyopop" height = "50" width = "100" / >
%elif comic['ComicPublisher'] == 'Midtown Comics':
< img src = "interfaces/default/images/publisherlogos/logo-midtowncomics.jpg" align = "right" alt = "Midtown" height = "50" width = "100" / >
%elif comic['ComicPublisher'] == 'Boom! Studios':
< img src = "interfaces/default/images/publisherlogos/logo-boom.jpg" align = "right" alt = "Boom!" height = "50" width = "100" / >
%elif comic['ComicPublisher'] == 'Skybound':
< img src = "interfaces/default/images/publisherlogos/logo-skybound.jpg" align = "right" alt = "Skybound" height = "50" width = "100" / >
%elif comic['ComicPublisher'] == 'Vertigo':
< img src = "interfaces/default/images/publisherlogos/logo-dynamite.jpg" align = "right" alt = "Dynamite" height = "50" width = "100" / >
%elif comic['ComicPublisher'] == 'Top Cow':
< img src = "interfaces/default/images/publisherlogos/logo-topcow.gif" align = "right" alt = "Top Cow" height = "75" width = "100" / >
%elif comic['ComicPublisher'] == 'Dynamite Entertainment':
< img src = "interfaces/default/images/publisherlogos/logo-dynamite.png" align = "right" alt = "Dynamite" height = "50" width = "100" / >
%elif comic['ComicPublisher'] == 'Cartoon Books':
< img src = "interfaces/default/images/publisherlogos/logo-cartoonbooks.jpg" align = "right" alt = "Cartoon Books" height = "75" width = "90" / >
2012-09-13 15:27:34 +00:00
%endif
< fieldset >
< div >
< label > < big > Publication Date: < / big > < norm > ${comic['ComicPublished']}< / norm > < / label >
< / div >
< div >
< label > < big > Publisher: < / big > < norm > ${comic['ComicPublisher']}< / norm > < / label >
< / div >
< div >
< label > < big > Status: < / big > < norm > ${comic['Status']}< / norm > < / label >
< / div >
2012-10-07 16:20:06 +00:00
< div >
< label > < big > Last Updated: < / big >
%if comic['LastUpdated'] is None:
< norm > Never< / norm >
%else:
< norm > ${comic['LastUpdated']}< / norm >
%endif
< / label >
< / div >
2012-09-13 15:27:34 +00:00
< div >
2013-02-18 17:39:00 +00:00
< label > < big > Issues in Series: < / big > < norm > ${comic['Total']} issues
%if comic['not_updated_db'] > 0:
(${comic['not_updated_db']} issue not updated yet)
%endif
< / norm > < / label >
2012-09-13 15:27:34 +00:00
< / div >
< div >
< label > < big > Directory< / big > < br / > < norm > ${comic['ComicLocation']}< / norm > < / label >
2013-07-02 05:50:14 +00:00
< / div >
< div >
< label > < big > Description:< / big > < / label > < br / >
<!-- <norm>${comic['Description']}</norm> -->
< / div >
< / fieldset >
2012-09-13 15:27:34 +00:00
< / td >
< / tr >
< / table >
< / div >
< div id = "tabs-2" >
< table class = "comictable" summary = "Download Settings" >
< tr >
2012-09-24 05:51:05 +00:00
< td id = "mainimg" >
2012-09-13 15:27:34 +00:00
< fieldset >
< div id = "artistImg" >
2012-10-30 10:43:01 +00:00
< img src = "${comic['ComicImage']}" alt = "" height = "400" width = "263" / >
2012-09-13 15:27:34 +00:00
< / div >
< / fieldset >
< / td >
2012-10-25 06:46:24 +00:00
< td width = "100%" padding = "10" >
2012-09-13 15:27:34 +00:00
%if comic['ComicPublisher'] == 'DC Comics':
2013-04-22 03:11:12 +00:00
< img src = "interfaces/default/images/publisherlogos/logo-dccomics.png" align = "right" alt = "DC" height = "50" width = "50" >
2012-09-13 15:27:34 +00:00
%elif comic['ComicPublisher'] == 'Marvel':
2013-04-22 03:11:12 +00:00
< img src = "interfaces/default/images/publisherlogos/logo-marvel.jpg" align = "right" alt = "Marvel" height = "50" width = "100" >
2012-09-13 15:27:34 +00:00
%elif comic['ComicPublisher'] == 'Image':
2013-04-22 03:11:12 +00:00
< img src = "interfaces/default/images/publisherlogos/logo-imagecomics.png" align = "right" alt = "Image" height = "100" width = "50" / >
2012-09-18 20:01:59 +00:00
%elif comic['ComicPublisher'] == 'Dark Horse Comics':
2013-04-22 03:11:12 +00:00
< img src = "interfaces/default/images/publisherlogos/logo-darkhorse.png" align = "right" alt = "Darkhorse" height = "75" width = "50" / >
2012-09-13 15:27:34 +00:00
%elif comic['ComicPublisher'] == 'IDW Publishing':
2013-04-22 03:11:12 +00:00
< img src = "interfaces/default/images/publisherlogos/logo-idwpublish.png" align = "right" alt = "IDW" height = "50" width = "100" / >
2012-09-13 15:27:34 +00:00
%endif
< fieldset >
< div >
2013-03-08 03:07:14 +00:00
< label > < big > Alternate versions :< / big > < norm > ${comic['ComicVersion']}< / norm > < / label >
2012-09-13 15:27:34 +00:00
< / div >
< div >
< label > < big > Scanner :< / big > < norm > ${comic['QUALscanner']}< / norm > < / label >
< / div >
< div >
< label > < big > Type :< / big > < norm > ${comic['QUALtype']}< / norm > < / label >
< / div >
< div >
< label > < big > Quality :< / big > < norm > ${comic['QUALquality']}< / norm > < / label >
< / div >
2012-12-31 16:52:16 +00:00
< div >
< label > < big > Alternate Search Names :< / big > < norm > ${comic['AlternateSearch']}< / norm > < / label >
< / div >
2013-01-13 15:59:46 +00:00
< %
if comic['UseFuzzy'] == "0" or comic['UseFuzzy'] is None:
fuzzy = "None"
fuzzy_year = "0"
elif comic['UseFuzzy'] == "1":
fuzzy = "Remove Year"
fuzzy_year = "1"
elif comic['UseFuzzy'] == "2":
fuzzy = "Fuzzy Year"
fuzzy_year = "2"
2012-12-31 16:52:16 +00:00
2013-01-13 15:59:46 +00:00
%>
< div >
< label > < big > Fuzzy Year logic : < / big > < norm > ${fuzzy} < / norm > < / label >
< / div >
2012-12-31 16:52:16 +00:00
2012-09-13 15:27:34 +00:00
< / fieldset >
< / td >
< / tr >
< / table >
< / div >
2012-09-24 05:17:29 +00:00
< div id = "tabs-3" >
2012-09-13 15:27:34 +00:00
< table class = "comictable" summary = "Edit Settings" >
< tr >
2012-09-24 05:51:05 +00:00
< td id = "mainimg" >
2012-09-13 15:27:34 +00:00
< fieldset >
< div class = "row" id = "artistImg" >
2012-10-30 10:43:01 +00:00
< img src = "${comic['ComicImage']}" alt = "" height = "400" width = "263" / >
2012-09-13 15:27:34 +00:00
< / div >
< / fieldset >
< / td >
2012-10-25 06:46:24 +00:00
< td width = "100%" padding = "10" >
2012-09-28 15:39:44 +00:00
%if comic['ComicPublisher'] == 'DC Comics':
2013-04-22 03:11:12 +00:00
< img src = "interfaces/default/images/publisherlogos/logo-dccomics.png" align = "right" alt = "DC" height = "50" width = "50" / >
2012-09-28 15:39:44 +00:00
%elif comic['ComicPublisher'] == 'Marvel':
2013-04-22 03:11:12 +00:00
< img src = "interfaces/default/images/publisherlogos/logo-marvel.jpg" align = "right" alt = "Marvel" height = "50" width = "100" / >
2012-09-28 15:39:44 +00:00
%elif comic['ComicPublisher'] == 'Image':
2013-04-22 03:11:12 +00:00
< img src = "interfaces/default/images/publisherlogos/logo-imagecomics.png" align = "right" alt = "Image" height = "100" width = "50" / >
2012-09-28 15:39:44 +00:00
%elif comic['ComicPublisher'] == 'Dark Horse Comics':
2013-04-22 03:11:12 +00:00
< img src = "interfaces/default/images/publisherlogos/logo-darkhorse.png" align = "right" alt = "Darkhorse" height = "75" width = "50" / >
2012-09-28 15:39:44 +00:00
%elif comic['ComicPublisher'] == 'IDW Publishing':
2013-04-22 03:11:12 +00:00
< img src = "interfaces/default/images/publisherlogos/logo-idwpublish.png" align = "right" alt = "IDW" height = "50" width = "100" / >
2012-09-28 15:39:44 +00:00
%endif
< form action = "comic_config" method = "GET" >
< input type = "hidden" name = "ComicID" value = ${comic['ComicID']} >
2013-01-13 15:59:46 +00:00
< br / > < br / > < br / >
2012-09-13 15:27:34 +00:00
< fieldset >
2012-10-25 06:46:24 +00:00
< div >
2012-09-28 15:39:44 +00:00
< label > Directory Location< / label >
2012-10-30 10:43:01 +00:00
< input type = "text" name = "com_location" value = "${comic['ComicLocation']}" size = "60" > < br / >
2012-10-25 06:46:24 +00:00
< div class = "row" > < small > the directory where all the comics are located for this particular comic< / small > < / div >
2012-09-28 15:39:44 +00:00
< / div >
2012-12-31 16:52:16 +00:00
< div >
< label > Alternate Search Names< / label >
< input type = "text" name = "alt_search" value = "${comic['AlternateSearch']}" size = "60" > < br / >
2013-01-13 15:59:46 +00:00
< div class = "row" > < small > Alternate comic names to be searched in case naming is different (ie. Hack/Slash = hack-slash)< / small > < / div >
2013-03-08 03:07:14 +00:00
< div >
< label > Version Number< / label >
< input type = "text" name = "comic_version" value = "${comic['ComicVersion']}" size = "20" > < br / >
< / div >
2013-01-13 15:59:46 +00:00
< / div >
< label > Year Options< / label >
< div class = "row radio left clearfix" >
2013-01-15 22:41:00 +00:00
< input type = "radio" style = "vertical-align: middle; margin: 3px; margin-top: -1px;" name = "fuzzy_year" value = "0" $ { comicConfig [ ' fuzzy_year0 ' ] } / > < label > Keep the Year as is< small > Default< / small > < / label >
< input type = "radio" style = "vertical-align: middle; margin: 3px; margin-top: -1px;" name = "fuzzy_year" value = "1" $ { comicConfig [ ' fuzzy_year1 ' ] } / > < label > Year Removal< small > Remove issue publication year from searches (dangerous)< / small > < / label >
< input type = "radio" style = "vertical-align: middle; margin: 3px; margin-top: -1px;" name = "fuzzy_year" value = "2" $ { comicConfig [ ' fuzzy_year2 ' ] } / > < label > Fuzzy the Year< small > Increase & Decrease the issue publication year by one< / small > < / label >
2012-12-31 16:52:16 +00:00
< / div >
2012-09-28 15:39:44 +00:00
< input type = "submit" value = "Update" / >
< / div >
< / fieldset >
< / form >
< / td >
< / tr >
2012-09-13 15:27:34 +00:00
< / table >
< / div >
< / div >
2013-07-02 05:50:14 +00:00
%if annuals:
< div id = "itabs" >
< ul >
< li > < a href = "#itabs-1" > I< / a > < / li >
< li > < a href = "#itabs-2" > A< / a > < / li >
< li > < a href = "#itabs-3" > S< / a > < / li >
< / ul >
%endif
2013-02-25 15:36:43 +00:00
< div id = "checkboxControls" style = "float: right; vertical-align: middle; margin: 3px; margin-top: -1px;" >
< div style = "padding-bottom: 5px;" >
< label for = "Wanted" class = "checkbox inline Wanted" > < input type = "checkbox" id = "Wanted" checked = "checked" / > Wanted: < b > ${isCounts['Wanted']}< / b > < / label >
< label for = "Archived" class = "checkbox inline Archived" > < input type = "checkbox" id = "Archived" checked = "checked" / > Archived: < b > ${isCounts['Archived']}< / b > < / label >
< label for = "Downloaded" class = "checkbox inline Downloaded" > < input type = "checkbox" id = "Downloaded" checked = "checked" / > Downloaded: < b > ${isCounts['Downloaded']}< / b > < / label >
< label for = "Skipped" class = "checkbox inline Skipped" > < input type = "checkbox" id = "Skipped" checked = "checked" / > Skipped: < b > ${isCounts['Skipped']}< / b > < / label >
< / div >
< / div >
2012-09-13 15:27:34 +00:00
2013-07-02 05:50:14 +00:00
%if annuals:
< div id = "itabs-1" >
%endif
< div class = "table_wrapper" >
2012-09-13 15:27:34 +00:00
< form action = "markissues" method = "get" id = "markissues" >
< div id = "markissue" > Mark selected issues as
2012-10-16 15:53:46 +00:00
< select name = "action" onChange = "doAjaxCall('markissues',$(this),'table',true);" data-success = "selected issues marked" >
2012-09-13 15:27:34 +00:00
< option disabled = "disabled" selected = "selected" > Choose...< / option >
< option value = "Wanted" > Wanted< / option >
< option value = "Skipped" > Skipped< / option >
< option value = "Downloaded" > Downloaded< / option >
2012-10-30 10:43:01 +00:00
< option value = "Archived" > Archived< / option >
2012-09-13 15:27:34 +00:00
< / select >
2012-10-16 08:16:29 +00:00
selected issues
2012-09-13 15:27:34 +00:00
< input type = "hidden" value = "Go" >
2013-01-23 07:34:50 +00:00
< input type = "checkbox" name = "skipped2wanted" onclick = "doAjaxCall('skipped2wanted?comicid=${comic['ComicID']}',$(this),'table')" value = "1" data-success = "Skipped Issues Changed to Wanted" style = "float: right; vertical-align: middle; margin: 3px; margin-top: -1px;" / > < label style = "float: right; vertical-align: middle; margin: 3px; margin-top: -1px;" > Change All Skipped to Wanted < / label >
2012-09-13 15:27:34 +00:00
< / div >
2013-02-17 10:31:18 +00:00
< table class = "display" id = "issue_table" >
2012-09-13 15:27:34 +00:00
< thead >
< tr >
2013-01-23 07:34:50 +00:00
< th id = "select" align = "left" > < input type = "checkbox" onClick = "toggle(this)" class = "checkbox" / > < / th >
2013-07-02 05:50:14 +00:00
< th id = "int_issuenumber" > IntIssNum< / th >
2012-09-13 15:27:34 +00:00
< th id = "issuenumber" > Number< / th >
< th id = "issuename" > Name< / th >
< th id = "reldate" > Date< / th >
< th id = "status" > Status< / th >
2013-02-17 10:31:18 +00:00
< th id = "options" > Options< / th >
2012-09-13 15:27:34 +00:00
< / tr >
< / thead >
< tbody >
%for issue in issues:
< %
if issue['Status'] == 'Skipped':
grade = 'Z'
elif issue['Status'] == 'Wanted':
grade = 'X'
elif issue['Status'] == 'Snatched':
grade = 'C'
2013-02-25 15:36:43 +00:00
elif issue['Status'] == 'Downloaded':
grade = 'A'
elif issue['Status'] == 'Archived':
grade = 'A'
2012-09-13 15:27:34 +00:00
else:
grade = 'A'
%>
2013-02-25 15:36:43 +00:00
< tr class = "${issue['Status']} grade${grade}" >
2013-02-09 03:34:02 +00:00
< td id = "select" > < input type = "checkbox" name = "${issue['IssueID']}" class = "checkbox" value = "${issue['IssueID']}" / > < / td >
2013-07-02 05:50:14 +00:00
< td id = "int_issuenumber" > ${issue['Int_IssueNumber']}< / td >
2012-09-13 15:27:34 +00:00
< td id = "issuenumber" > ${issue['Issue_Number']}< / td >
2013-01-27 10:08:32 +00:00
< td id = "issuename" > ${issue['IssueName']}< / td >
2012-09-13 15:27:34 +00:00
< td id = "reldate" > ${issue['IssueDate']}< / td >
2013-02-27 08:28:40 +00:00
< td id = "status" > ${issue['Status']}
%if issue['Status'] == 'Downloaded' or issue['Status'] == 'Archived':
< %Csize = mylar.helpers.human_size(issue['ComicSize'])%>
< a href = "#" title = "${issue['Location']} (${Csize})" > < img src = "interfaces/default/images/info32.png" height = "16" alt = "" / > < / a >
%endif
< / td >
2013-02-17 10:31:18 +00:00
< td id = "options" >
2012-09-13 15:27:34 +00:00
%if issue['Status'] == 'Skipped':
2013-02-17 10:31:18 +00:00
< a href = "#" title = "Mark issue as Wanted" onclick = "doAjaxCall('queueissue?ComicID=${issue['ComicID']}&IssueID=${issue['IssueID']}&ComicIssue=${issue['Issue_Number']}&ComicYear=${issue['IssueDate']}&mode=want',$(this),'table')" > < img src = "interfaces/default/images/wanted_icon.png" height = "25" width = "25" / > < / a >
2012-09-13 15:27:34 +00:00
%elif (issue['Status'] == 'Wanted'):
2013-02-18 17:39:00 +00:00
< a href = "#" title = "Mark issue as Skipped" onclick = "doAjaxCall('unqueueissue?IssueID=${issue['IssueID']}&ComicID=${issue['ComicID']}',$(this),'table')" data-success = "'${issue['Issue_Number']}' has been marked as skipped" > < img src = "interfaces/default/images/skipped_icon.png" height = "25" width = "25" / > < / a >
2013-02-17 10:31:18 +00:00
%elif (issue['Status'] == 'Snatched'):
< a href = "#" onclick = "doAjaxCall('queueissue?ComicID=${issue['ComicID']}&IssueID=${issue['IssueID']}&ComicIssue=${issue['Issue_Number']}&mode=want', $(this),'table')" data-success = "Retrying the same version of '${issue['ComicName']}' '${issue['Issue_Number']}'" title = "Retry the same download again" > < img src = "interfaces/default/images/retry_icon.png" height = "25" width = "25" / > < / a >
2013-02-18 17:39:00 +00:00
< a href = "#" title = "Mark issue as Skipped" onclick = "doAjaxCall('unqueueissue?IssueID=${issue['IssueID']}&ComicID=${issue['ComicID']}',$(this),'table')" data-success = "'${issue['Issue_Number']}' has been marked as skipped" > < img src = "interfaces/default/images/skipped_icon.png" height = "25" width = "25" / > < / a >
2013-03-08 03:07:14 +00:00
%elif (issue['Status'] == 'Downloaded'):
2013-03-14 08:55:38 +00:00
%if issue['inCacheDIR']:
< %
try:
with open(os.path.join(mylar.CACHE_DIR,issue['Location'])) as f:
linky = issue['Location']
except IOError as e:
linky = None
%>
%if linky:
< a href = "cache/${linky}" > < img src = "interfaces/default/images/download_icon.png" height = "25" width = "25" title = "Download the Issue" / > < / a >
2013-05-04 01:57:19 +00:00
%else:
< a href = "#" onclick = "doAjaxCall('downloadLocal?IssueID=${issue['IssueID']}', $(this), 'table')" > < img src = "interfaces/default/images/copy_icon.png" height = "25" width = "25" title = "Copy issue to local cache (ready for download)" / > < / a >
2013-03-14 08:55:38 +00:00
%endif
%else:
2013-05-04 01:57:19 +00:00
< a href = "#" onclick = "doAjaxCall('downloadLocal?IssueID=${issue['IssueID']}', $(this), 'table')" > < img src = "interfaces/default/images/copy_icon.png" height = "25" width = "25" title = "Copy issue to local cache (ready for download)" / > < / a >
2013-03-14 08:55:38 +00:00
%endif
2013-03-08 03:07:14 +00:00
< a href = "#" title = "Add to Reading List" onclick = "doAjaxCall('addtoreadlist?IssueID=${issue['IssueID']}',$(this),'table')" data-success = "${issue['Issue_Number']} added to Reading List" > < img src = "interfaces/default/images/glasses-icon.png" height = "25" width = "25" / > < / a >
2012-09-13 15:27:34 +00:00
%else:
2013-02-17 10:31:18 +00:00
< a href = "#" onclick = "doAjaxCall('queueissue?ComicID=${issue['ComicID']}&IssueID=${issue['IssueID']}&ComicIssue=${issue['Issue_Number']}&mode=want', $(this),'table')" data-success = "Retrying the same version of '${issue['ComicName']}' '${issue['Issue_Number']}'" title = "Retry the same download again" > < img src = "interfaces/default/images/retry_icon.png" height = "25" width = "25" / > < / a >
2013-02-18 17:39:00 +00:00
< a href = "#" title = "Mark issue as Skipped" onclick = "doAjaxCall('unqueueissue?IssueID=${issue['IssueID']}&ComicID=${issue['ComicID']}',$(this),'table')" data-success = "'${issue['Issue_Number']}' has been marked as skipped" > < img src = "interfaces/default/images/skipped_icon.png" height = "25" width = "25" / > < / a >
2012-09-13 15:27:34 +00:00
%endif
2013-02-17 10:31:18 +00:00
< a href = "#" onclick = "doAjaxCall('archiveissue?IssueID=${issue['IssueID']}',$(this),'table')" > < img src = "interfaces/default/images/archive_icon.png" height = "25" width = "25" title = "Mark issue as Archived" > < / a >
2012-09-13 15:27:34 +00:00
< / td >
< / tr >
%endfor
< / tbody >
2013-07-02 05:50:14 +00:00
< / table >
< / form >
< / div >
%if annuals:
< / div >
< div id = "itabs-2" >
< table id = "annual_table" class = "display" >
<!-- <div class="ui - widget">
< label for = "annseries" > Series: < / label >
< input id = "annseries" / >
< / div >
< div class = "ui-widget" style = "margin-top: 2em; font-family: Arial;" >
Result:
< div id = "log" style = "height: 200px; width: 300px; overflow: auto;" class = "ui-widget-content" > < / div >
< / div >
-->
2013-03-21 17:09:10 +00:00
< thead >
< tr >
< th id = "select" align = "left" > < input type = "checkbox" onClick = "toggle(this)" class = "checkbox" / > < / th >
< th id = "issuenumber" > Number< / th >
< th id = "issuename" > Name< / th >
< th id = "reldate" > Date< / th >
< th id = "status" > Status< / th >
< th id = "options" > Options< / th >
< / tr >
< / thead >
< tbody >
%for annual in annuals:
2013-07-02 05:50:14 +00:00
< %
if annual['Status'] == 'Skipped':
grade = 'Z'
elif annual['Status'] == 'Wanted':
grade = 'X'
elif annual['Status'] == 'Snatched':
grade = 'C'
elif annual['Status'] == 'Downloaded':
grade = 'A'
elif annual['Status'] == 'Archived':
grade = 'A'
else:
grade = 'A'
%>
< tr class = "${annual['Status']} grade${grade}" >
2013-03-21 17:09:10 +00:00
< tr >
< td id = "select" > < input type = "checkbox" name = "${annual['IssueID']}" class = "checkbox" value = "${annual['IssueID']}" / > < / td >
< td id = "issuenumber" > ${annual['Issue_Number']}< / td >
< td id = "issuename" > ${annual['IssueName']}< / td >
< td id = "reldate" > ${annual['IssueDate']}< / td >
2013-07-02 05:50:14 +00:00
< td id = "status" > ${annual['Status']}
FIX:(#304) Index out of range on recheck, FIX:(#303) Comicvine link updated on details page, FIX:(#302) Query rate (Search Delay) Added as a configuration option, FIX:(#300) Version number error on searching when no version number, FIX:(#297) Manual Rename of Files working, FIX:(#294) 'AU' issue problems should be resolved now, FIX:(#290) V#(year) and Vol#(year) added to filechecking, IMP: ComicVine data use only now as a hidden option (cv_only = 1 in config.ini), IMP: added as options for file naming, IMP: Rough drafting of Annuals (annuals_on = 1 in config.ini), Other fixes..
2013-04-06 09:43:18 +00:00
%if annual['Status'] == 'Downloaded' or annual['Status'] == 'Archived':
< %Csize = mylar.helpers.human_size(annual['ComicSize'])%>
< a href = "#" title = "${annual['Location']} (${Csize})" > < img src = "interfaces/default/images/info32.png" height = "16" alt = "" / > < / a >
%endif
< / td >
< td id = "options" >
%if annual['Status'] == 'Skipped':
2013-07-02 05:50:14 +00:00
< a href = "#" title = "Mark issue as Wanted" onclick = "doAjaxCall('queueissue?ComicID=${annual['ComicID']}&IssueID=${annual['IssueID']}&ComicIssue=${annual['Issue_Number']}&ComicYear=${annual['IssueDate']}&mode=want_ann',$(this),'table')" > < img src = "interfaces/default/images/wanted_icon.png" height = "25" width = "25" / > < / a >
FIX:(#304) Index out of range on recheck, FIX:(#303) Comicvine link updated on details page, FIX:(#302) Query rate (Search Delay) Added as a configuration option, FIX:(#300) Version number error on searching when no version number, FIX:(#297) Manual Rename of Files working, FIX:(#294) 'AU' issue problems should be resolved now, FIX:(#290) V#(year) and Vol#(year) added to filechecking, IMP: ComicVine data use only now as a hidden option (cv_only = 1 in config.ini), IMP: added as options for file naming, IMP: Rough drafting of Annuals (annuals_on = 1 in config.ini), Other fixes..
2013-04-06 09:43:18 +00:00
%elif (annual['Status'] == 'Wanted'):
< a href = "#" title = "Mark issue as Skipped" onclick = "doAjaxCall('unqueueissue?IssueID=${annual['IssueID']}&ComicID=${annual['ComicID']}',$(this),'table')" data-success = "'${annual['Issue_Number']}' has been marked as skipped" > < img src = "interfaces/default/images/skipped_icon.png" height = "25" width = "25" / > < / a >
%elif (annual['Status'] == 'Snatched'):
< a href = "#" title = "Mark issue as Skipped" onclick = "doAjaxCall('unqueueissue?IsssueID=${annual['IssueID']}&ComicID=${annual['ComicID']}',$(this),'table')" data-success = "'${annual['Issue_Number']}' has been marked as skipped" > < img src = "interfaces/default/images/skipped_icon.png" height = "25" width = "25" / > < / a >
%elif (annual['Status'] == 'Read'):
< a href = "#" title = "Add to Reading List" > < img src = "interfaces/default/images/glasses-icon.png" height = "25" width = "25" / > < / a >
%else:
< a href = "#" title = "Retry" > < img src = "interfaces/default/images/retry_icon.png" height = "25" width = "25" / > < / a >
< a href = "#" title = "Mark issue as Skipped" > < img src = "interfaces/default/images/skipped_icon.png" height = "25" width = "25" / > < / a >
%endif
< a href = "#" > < img src = "interfaces/default/images/archive_icon.png" height = "25" width = "25" title = "Mark issue as Archived" / > < / a >
< / td >
2013-03-21 17:09:10 +00:00
< / tr >
%endfor
< / tbody >
< / table >
2013-07-02 05:50:14 +00:00
< / div >
< / div >
%endif
2012-09-13 15:27:34 +00:00
< /%def>
< %def name="headIncludes()">
< link rel = "stylesheet" href = "interfaces/default/css/data_table.css" >
2013-02-27 08:28:40 +00:00
2012-09-13 15:27:34 +00:00
%if comic['Status'] == 'Loading':
< meta http-equiv = "refresh" content = "60" >
%endif
< /%def>
< %def name="javascriptIncludes()">
< script src = "js/libs/jquery.dataTables.min.js" > < / script >
2013-07-02 05:50:14 +00:00
< style >
.ui-autocomplete-loading {
background: white url('interfaces/default/images/loader_black.gif') right center no-repeat;
}
#annseries{ width: 25em; }
< / style >
2013-02-06 19:55:23 +00:00
< script >
2013-07-02 05:50:14 +00:00
$(function() {
function log( message ) {
$( "< div > " ).text( message ).prependTo( "#log" );
$( "#log" ).scrollTop( 0 );
}
2013-02-27 08:28:40 +00:00
2013-07-02 05:50:14 +00:00
$( "#annseries" ).autocomplete({
source: function( request, response ) {
$.ajax({
url: "http://api.comicvine.com/search?",
contentType: "application/json; charset=utf-8",
dataType: "json",
data: {
resources: "volume",
format: "json",
api_key: "583939a3df0a25fc4e8b7a29934a13078002dc27",
query: request.term
},
success: function( data ) {
alert("success");
response( $.map( data.results, function( item ) {
return {
label: item.name + (item.id),
value: item.name
}
}));
},
error: function( data ) {
alert("error");
}
});
},
minLength: 2,
select: function( event, ui ) {
log( ui.item ?
"Selected: " + ui.item.label :
"Nothing selected, input was " + this.value);
},
open: function() {
$( this ).removeClass( "ui-corner-all" ).addClass( "ui-corner-top" );
},
close: function() {
$( this ).removeClass( "ui-corner-top" ).addClass( "ui-corner-all" );
}
});
});
< / script >
< script >
2013-02-25 15:36:43 +00:00
// show/hide different types of rows when the checkboxes are changed
$("#checkboxControls input").change(function(e){
var whichClass = $(this).attr('id')
$(this).showHideRows(whichClass)
return
$('tr.'+whichClass).each(function(i){
$(this).toggle();
});
});
// initially show/hide all the rows according to the checkboxes
$("#checkboxControls input").each(function(e){
var status = this.checked;
$("tr."+$(this).attr('id')).each(function(e){
if (status) {
$(this).show();
} else {
$(this).hide();
}
});
});
$.fn.showHideRows = function(whichClass){
var status = $('#checkboxControls > input, #'+whichClass).prop('checked')
$("tr."+whichClass).each(function(e){
if (status) {
$(this).show();
} else {
$(this).hide();
}
});
}
2013-02-06 19:55:23 +00:00
2012-09-13 15:27:34 +00:00
hideServerDivs = function () {
$("#customoptions").slideUp();
$("#hpserveroptions").slideUp();
};
handleNewSelection = function () {
hideServerDivs();
switch ($(this).val()) {
case 'custom':
$("#customoptions").slideDown();
break;
case 'mylar':
$("#hpserveroptions").slideDown();
break;
}
};
2013-01-23 09:43:21 +00:00
function initThisPage(){
2012-09-13 15:27:34 +00:00
$(function() {
$( "#tabs" ).tabs();
2013-07-02 05:50:14 +00:00
$( "#itabs" ).tabs();
2012-09-13 15:27:34 +00:00
});
initActions();
2013-01-23 09:43:21 +00:00
$('#issue_table').dataTable(
{
"bDestroy": true,
"aoColumnDefs": [
2013-07-02 05:50:14 +00:00
{ 'bSortable': false, 'aTargets': [ 0, 3 ] },
{ 'bVisible': false, 'aTargets': [1] },
{ 'sType': 'numeric', 'aTargets': [1] },
{ 'iDataSort': [1], 'aTargets': [2] }
2013-01-23 09:43:21 +00:00
],
2013-04-14 02:55:00 +00:00
"aLengthMenu": [[10, 25, 50, -1], [10, 25, 50, 'All' ]],
2013-01-23 09:43:21 +00:00
"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": ""},
2013-04-14 02:55:00 +00:00
"bStateSave": true,
2013-01-23 09:43:21 +00:00
"iDisplayLength": 25,
2013-07-02 05:50:14 +00:00
<!-- "sDom": '<"top"lf<"clear">p>rt<"clear"<"F"ip>>', -->
<!-- "sDom": '<"H"lfr>t<"F"ip>', -->
2013-01-23 09:43:21 +00:00
"sPaginationType": "full_numbers",
2013-07-02 05:50:14 +00:00
"aaSorting": [[2, 'desc'],[4,'desc']]
2013-01-23 09:43:21 +00:00
});
2013-07-02 05:50:14 +00:00
resetFilters("issue");
2013-01-23 09:43:21 +00:00
setTimeout(function(){
initFancybox();
2013-07-02 05:50:14 +00:00
},1500);
2012-09-13 15:27:34 +00:00
}
$(document).ready(function() {
initThisPage();
2013-02-06 19:55:23 +00:00
});
2012-09-13 15:27:34 +00:00
< / script >
< /%def>