Allow link to extra notes page, sort comments by chapter if applicable
This commit is contained in:
parent
a66d108921
commit
761bfe0672
2 changed files with 17 additions and 0 deletions
16
new.py
16
new.py
|
@ -107,6 +107,10 @@ while ficcount > 0:
|
||||||
ficdict["summary"] = fileread.summary
|
ficdict["summary"] = fileread.summary
|
||||||
except:
|
except:
|
||||||
pass
|
pass
|
||||||
|
try:
|
||||||
|
ficdict["extralink"] = fileread.extralink
|
||||||
|
except:
|
||||||
|
pass
|
||||||
try:
|
try:
|
||||||
if fileread.eventname == "bethefirst":
|
if fileread.eventname == "bethefirst":
|
||||||
ficdict["event"] = "Be The First"
|
ficdict["event"] = "Be The First"
|
||||||
|
@ -254,6 +258,10 @@ while ficcount > 0:
|
||||||
ficdict["comments"] = False
|
ficdict["comments"] = False
|
||||||
except:
|
except:
|
||||||
ficdict["comments"] = False
|
ficdict["comments"] = False
|
||||||
|
try:
|
||||||
|
ficdict["comments"] = sorted(ficdict["comments"],key=lambda d: d["chapter"])
|
||||||
|
except:
|
||||||
|
pass
|
||||||
try:
|
try:
|
||||||
ficdict["cssoverride"] = fileread.cssoverride
|
ficdict["cssoverride"] = fileread.cssoverride
|
||||||
except:
|
except:
|
||||||
|
@ -615,6 +623,10 @@ for fic in ficlist:
|
||||||
ficpage.write(" version: <a href=\"/fic/" + stringno(fic["transid"]) + "\">" + stringno(fic["transid"]) + "</a></li>")
|
ficpage.write(" version: <a href=\"/fic/" + stringno(fic["transid"]) + "\">" + stringno(fic["transid"]) + "</a></li>")
|
||||||
except:
|
except:
|
||||||
pass
|
pass
|
||||||
|
try:
|
||||||
|
ficpage.write("\n<li>See <a href=\"" + fic["extralink"] + "\">here</a> for additional notes.</li>")
|
||||||
|
except:
|
||||||
|
pass
|
||||||
allowcomments = False
|
allowcomments = False
|
||||||
havecomments = False
|
havecomments = False
|
||||||
commentlink = False
|
commentlink = False
|
||||||
|
@ -824,6 +836,10 @@ for fic in ficlist:
|
||||||
elif fic["french"] == "translation":
|
elif fic["french"] == "translation":
|
||||||
transpage.write("English")
|
transpage.write("English")
|
||||||
transpage.write(" version: <a href=\"/fic/" + stringno(fic["id"]) + "\">" + stringno(fic["id"]) + "</a></li>")
|
transpage.write(" version: <a href=\"/fic/" + stringno(fic["id"]) + "\">" + stringno(fic["id"]) + "</a></li>")
|
||||||
|
try:
|
||||||
|
transpage.write("\n<li>See <a href=\"" + fic["extralink"] + "\">here</a> for additional notes.</li>")
|
||||||
|
except:
|
||||||
|
pass
|
||||||
allowcomments = False
|
allowcomments = False
|
||||||
havecomments = False
|
havecomments = False
|
||||||
commentlink = False
|
commentlink = False
|
||||||
|
|
|
@ -17,6 +17,7 @@ fandom = [""]
|
||||||
genre = [""] # ship category comes first, 1 more is displayed
|
genre = [""] # ship category comes first, 1 more is displayed
|
||||||
warnstring = 9000000000 # 9 is a dummy; then sex (0–3), death, mental health, bigotry, vomiting, consent, underage, incest, amputation (all others being 0–2)
|
warnstring = 9000000000 # 9 is a dummy; then sex (0–3), death, mental health, bigotry, vomiting, consent, underage, incest, amputation (all others being 0–2)
|
||||||
# summary = ""
|
# summary = ""
|
||||||
|
# extralink = ""
|
||||||
# event = "" # challenge (including fests; anything without a specific prompt), ao3exchange, exchange, prompt
|
# event = "" # challenge (including fests; anything without a specific prompt), ao3exchange, exchange, prompt
|
||||||
# eventname = ""
|
# eventname = ""
|
||||||
# prompt = ""
|
# prompt = ""
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue