remotes/1693045480750635534/spooky-22
Aevann1 2021-12-31 19:38:11 +02:00
parent 67bb72ce6c
commit 5ed3a75786
12 changed files with 33 additions and 18 deletions

View File

@ -330,6 +330,7 @@ def api_comment(v):
level=level+1,
is_bot=True,
body_html=body_based_html,
top_comment_id=c.top_comment_id
)
g.db.add(c_based)
@ -361,6 +362,7 @@ def api_comment(v):
level=level+1,
is_bot=True,
body_html=body_jannied_html,
top_comment_id=c.top_comment_id
)
g.db.add(c_jannied)
@ -394,6 +396,7 @@ def api_comment(v):
level=level+1,
is_bot=True,
body_html=body_jannied_html,
top_comment_id=c.top_comment_id
)
g.db.add(c_jannied)
@ -425,6 +428,7 @@ def api_comment(v):
level=level+1,
is_bot=True,
body_html=body_html2,
top_comment_id=c.top_comment_id
)
g.db.add(c2)
@ -460,6 +464,7 @@ def api_comment(v):
level=level+1,
is_bot=True,
body_html=body_html2,
top_comment_id=c.top_comment_id
)
g.db.add(c2)
@ -483,6 +488,7 @@ def api_comment(v):
level=level+2,
is_bot=True,
body_html=body_html2,
top_comment_id=c.top_comment_id
)
g.db.add(c3)
@ -499,6 +505,7 @@ def api_comment(v):
level=level+3,
is_bot=True,
body_html=body_html2,
top_comment_id=c.top_comment_id
)
g.db.add(c4)
@ -728,6 +735,7 @@ def edit_comment(cid, v):
level=c.level+1,
is_bot=True,
body_html=body_jannied_html,
top_comment_id=c.top_comment_id
)
g.db.add(c_jannied)
@ -762,6 +770,7 @@ def edit_comment(cid, v):
level=c.level+1,
is_bot=True,
body_html=body_jannied_html,
top_comment_id=c.top_comment_id
)
g.db.add(c_jannied)

View File

@ -345,6 +345,8 @@ def viewmore(v, pid, sort, offset):
@limiter.limit("1/second")
@auth_desired
def morecomments(v, cid):
tcid = g.db.query(Comment.top_comment_id).filter_by(id=cid).one_or_none()[0]
if v:
votes = g.db.query(CommentVote).filter_by(user_id=v.id).subquery()
@ -357,7 +359,7 @@ def morecomments(v, cid):
votes.c.vote_type,
blocking.c.id,
blocked.c.id,
).filter_by(parent_comment_id=cid).join(
).filter(Comment.top_comment_id == tcid, Comment.level > 10).join(
votes,
votes.c.comment_id == Comment.id,
isouter=True
@ -377,7 +379,7 @@ def morecomments(v, cid):
comment.voted = c[1] or 0
comment.is_blocking = c[2] or 0
comment.is_blocked = c[3] or 0
output.append(comment)
if c[0].parent_comment_id == int(cid): output.append(comment)
comments = output
else:
c = g.db.query(Comment).filter_by(id=cid).first()
@ -511,6 +513,7 @@ def edit_post(pid, v):
is_pinned='AutoJanny',
distinguish_level=6,
body_html=body_jannied_html,
top_comment_id=c.top_comment_id
)
g.db.add(c_jannied)
@ -543,6 +546,7 @@ def edit_post(pid, v):
is_pinned='AutoJanny',
distinguish_level=6,
body_html=body_jannied_html,
top_comment_id=c.top_comment_id
)
g.db.add(c_jannied)
@ -1072,6 +1076,7 @@ def submit_post(v):
is_pinned='AutoJanny',
distinguish_level=6,
body_html=body_jannied_html,
top_comment_id=c.top_comment_id
)
g.db.add(c_jannied)
@ -1104,6 +1109,7 @@ def submit_post(v):
is_pinned='AutoJanny',
distinguish_level=6,
body_html=body_jannied_html,
top_comment_id=c.top_comment_id
)
g.db.add(c_jannied)
@ -1159,7 +1165,7 @@ def submit_post(v):
over_18=False,
is_bot=True,
app_id=None,
body_html=body_html,
body_html=body_html
)
g.db.add(c)

View File

@ -15,7 +15,7 @@
{% if v %}
<style>:root{--primary:#{{v.themecolor}}}</style>
<link rel="stylesheet" href="/static/assets/css/main.css?a=53"><link rel="stylesheet" href="/static/assets/css/{{v.theme}}.css?a=3">
<link rel="stylesheet" href="/static/assets/css/main.css?a=54"><link rel="stylesheet" href="/static/assets/css/{{v.theme}}.css?a=3">
{% if v.agendaposter %}
<style>
html {
@ -39,7 +39,7 @@
{% endif %}
{% else %}
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
<link rel="stylesheet" href="/static/assets/css/main.css?a=53"><link rel="stylesheet" href="/static/assets/css/{{'DEFAULT_THEME' | app_config}}.css?a=3">
<link rel="stylesheet" href="/static/assets/css/main.css?a=54"><link rel="stylesheet" href="/static/assets/css/{{'DEFAULT_THEME' | app_config}}.css?a=3">
{% endif %}
</head>

View File

@ -7,7 +7,7 @@
<script src="/static/assets/js/bootstrap.js?a=3"></script>
{% if v %}
<style>:root{--primary:#{{v.themecolor}}}</style>
<link rel="stylesheet" href="/static/assets/css/main.css?a=53">
<link rel="stylesheet" href="/static/assets/css/main.css?a=54">
<link rel="stylesheet" href="/static/assets/css/{{v.theme}}.css?a=3">
{% if v.agendaposter %}
<style>
@ -32,7 +32,7 @@
{% endif %}
{% else %}
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
<link rel="stylesheet" href="/static/assets/css/main.css?a=53"><link rel="stylesheet" href="/static/assets/css/{{'DEFAULT_THEME' | app_config}}.css?a=3">
<link rel="stylesheet" href="/static/assets/css/main.css?a=54"><link rel="stylesheet" href="/static/assets/css/{{'DEFAULT_THEME' | app_config}}.css?a=3">
{% endif %}
<meta charset="utf-8">

View File

@ -6,7 +6,7 @@
{% block content %}
{% if v %}
<style>:root{--primary:#{{v.themecolor}}}</style>
<link rel="stylesheet" href="/static/assets/css/main.css?a=53"><link rel="stylesheet" href="/static/assets/css/{{v.theme}}.css?a=3">
<link rel="stylesheet" href="/static/assets/css/main.css?a=54"><link rel="stylesheet" href="/static/assets/css/{{v.theme}}.css?a=3">
{% if v.agendaposter %}
<style>
html {
@ -30,7 +30,7 @@
{% endif %}
{% else %}
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
<link rel="stylesheet" href="/static/assets/css/main.css?a=53"><link rel="stylesheet" href="/static/assets/css/{{'DEFAULT_THEME' | app_config}}.css?a=3">
<link rel="stylesheet" href="/static/assets/css/main.css?a=54"><link rel="stylesheet" href="/static/assets/css/{{'DEFAULT_THEME' | app_config}}.css?a=3">
{% endif %}
<div class="row justify-content-around">

View File

@ -18,7 +18,7 @@
{% endblock %}
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
<link rel="stylesheet" href="/static/assets/css/main.css?a=53">
<link rel="stylesheet" href="/static/assets/css/main.css?a=54">
<link rel="stylesheet" href="/static/assets/css/{{'DEFAULT_THEME' | app_config}}.css?a=3">
</head>

View File

@ -14,7 +14,7 @@
<title>2-Step Login - {{'SITE_NAME' | app_config}}</title>
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
<link rel="stylesheet" href="/static/assets/css/main.css?a=53"><link rel="stylesheet" href="/static/assets/css/{{'DEFAULT_THEME' | app_config}}.css?a=3">
<link rel="stylesheet" href="/static/assets/css/main.css?a=54"><link rel="stylesheet" href="/static/assets/css/{{'DEFAULT_THEME' | app_config}}.css?a=3">
</head>

View File

@ -34,7 +34,7 @@
<style>:root{--primary:#{{v.themecolor}}}</style>
<link rel="stylesheet" href="/static/assets/css/main.css?a=53"><link rel="stylesheet" href="/static/assets/css/{{v.theme}}.css?a=3">
<link rel="stylesheet" href="/static/assets/css/main.css?a=54"><link rel="stylesheet" href="/static/assets/css/{{v.theme}}.css?a=3">
{% if v.agendaposter %}
<style>
html {

View File

@ -39,10 +39,10 @@
{% if v %}
<style>:root{--primary:#{{v.themecolor}}}</style>
<link rel="stylesheet" href="/static/assets/css/main.css?a=53"><link rel="stylesheet" href="/static/assets/css/{{v.theme}}.css?a=3">
<link rel="stylesheet" href="/static/assets/css/main.css?a=54"><link rel="stylesheet" href="/static/assets/css/{{v.theme}}.css?a=3">
{% else %}
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
<link rel="stylesheet" href="/static/assets/css/main.css?a=53"><link rel="stylesheet" href="/static/assets/css/{{'DEFAULT_THEME' | app_config}}.css?a=3">
<link rel="stylesheet" href="/static/assets/css/main.css?a=54"><link rel="stylesheet" href="/static/assets/css/{{'DEFAULT_THEME' | app_config}}.css?a=3">
{% endif %}
</head>

View File

@ -31,7 +31,7 @@
<title>{% if ref_user %}{{ref_user.username}} invites you to {{'SITE_NAME' | app_config}}{% else %}Sign up - {{'SITE_NAME' | app_config}}{% endif %}</title>
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
<link rel="stylesheet" href="/static/assets/css/main.css?a=53"><link rel="stylesheet" href="/static/assets/css/{{'DEFAULT_THEME' | app_config}}.css?a=3">
<link rel="stylesheet" href="/static/assets/css/main.css?a=54"><link rel="stylesheet" href="/static/assets/css/{{'DEFAULT_THEME' | app_config}}.css?a=3">
</head>

View File

@ -32,7 +32,7 @@
<title>{% if ref_user %}{{ref_user.username}} invites you to {{'SITE_NAME' | app_config}}{% else %}{{'SITE_NAME' | app_config}}{% endif %}</title>
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
<link rel="stylesheet" href="/static/assets/css/main.css?a=53"><link rel="stylesheet" href="/static/assets/css/{{'DEFAULT_THEME' | app_config}}.css?a=3">
<link rel="stylesheet" href="/static/assets/css/main.css?a=54"><link rel="stylesheet" href="/static/assets/css/{{'DEFAULT_THEME' | app_config}}.css?a=3">
</head>

View File

@ -26,7 +26,7 @@
{% block stylesheets %}
{% if v %}
<style>:root{--primary:#{{v.themecolor}}}</style>
<link rel="stylesheet" href="/static/assets/css/main.css?a=53"><link rel="stylesheet" href="/static/assets/css/{{v.theme}}.css?a=3">
<link rel="stylesheet" href="/static/assets/css/main.css?a=54"><link rel="stylesheet" href="/static/assets/css/{{v.theme}}.css?a=3">
{% if v.agendaposter %}
<style>
html {
@ -50,7 +50,7 @@
{% endif %}
{% else %}
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
<link rel="stylesheet" href="/static/assets/css/main.css?a=53">
<link rel="stylesheet" href="/static/assets/css/main.css?a=54">
<link rel="stylesheet" href="/static/assets/css/{{'DEFAULT_THEME' | app_config}}.css?a=3">
{% endif %}
{% endblock %}