forked from rDrama/rDrama
sdfdsf
parent
951afa7987
commit
dbc08a2579
|
@ -218,7 +218,13 @@ def frontlist(v=None, sort="hot", page=1, t="all", ids_only=True, filter_words='
|
||||||
|
|
||||||
posts = posts[:size]
|
posts = posts[:size]
|
||||||
|
|
||||||
if page == 1: posts = g.db.query(Submission.id).options(lazyload('*')).filter(Submission.stickied != None).all() + posts
|
pins = g.db.query(Submission.id).options(lazyload('*')).filter(Submission.stickied != None)
|
||||||
|
if v and v.admin_level == 0:
|
||||||
|
blocking = [x[0] for x in g.db.query(UserBlock.target_id).filter_by(user_id=v.id).all()]
|
||||||
|
blocked = [x[0] for x in g.db.query(UserBlock.user_id).filter_by(target_id=v.id).all()]
|
||||||
|
pins = pins.filter(Submission.author_id.notin_(blocking), Submission.author_id.notin_(blocked))
|
||||||
|
|
||||||
|
if page == 1: posts = pins + posts
|
||||||
|
|
||||||
if ids_only: posts = [x[0] for x in posts]
|
if ids_only: posts = [x[0] for x in posts]
|
||||||
|
|
||||||
|
|
|
@ -15,11 +15,11 @@
|
||||||
|
|
||||||
{% if v %}
|
{% if v %}
|
||||||
<style>:root{--primary:#{{v.themecolor}}}</style>
|
<style>:root{--primary:#{{v.themecolor}}}</style>
|
||||||
<link rel="stylesheet" href="/assets/css/main.css?v=74"><link rel="stylesheet" href="/assets/css/{{v.theme}}.css?v=74">
|
<link rel="stylesheet" href="/assets/css/main.css?v=75"><link rel="stylesheet" href="/assets/css/{{v.theme}}.css?v=75">
|
||||||
{% if v.agendaposter %}<link rel="stylesheet" href="/assets/css/agendaposter.css?v=74">{% elif v.css %}<link rel="stylesheet" href="/@{{v.username}}/css">{% endif %}
|
{% if v.agendaposter %}<link rel="stylesheet" href="/assets/css/agendaposter.css?v=75">{% elif v.css %}<link rel="stylesheet" href="/@{{v.username}}/css">{% endif %}
|
||||||
{% else %}
|
{% else %}
|
||||||
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
|
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
|
||||||
<link rel="stylesheet" href="/assets/css/main.css?v=72"><link rel="stylesheet" href="/assets/css/{{'DEFAULT_THEME' | app_config}}.css?v=72">
|
<link rel="stylesheet" href="/assets/css/main.css?v=75"><link rel="stylesheet" href="/assets/css/{{'DEFAULT_THEME' | app_config}}.css?v=75">
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
</head>
|
</head>
|
||||||
|
|
|
@ -250,12 +250,12 @@
|
||||||
|
|
||||||
{% if v %}
|
{% if v %}
|
||||||
<style>:root{--primary:#{{v.themecolor}}}</style>
|
<style>:root{--primary:#{{v.themecolor}}}</style>
|
||||||
<link rel="stylesheet" href="/assets/css/main.css?v=74">
|
<link rel="stylesheet" href="/assets/css/main.css?v=75">
|
||||||
<link rel="stylesheet" href="/assets/css/{{v.theme}}.css?v=74">
|
<link rel="stylesheet" href="/assets/css/{{v.theme}}.css?v=75">
|
||||||
{% if v.agendaposter %}<link rel="stylesheet" href="/assets/css/agendaposter.css?v=74">{% elif v.css %}<link rel="stylesheet" href="/@{{v.username}}/css">{% endif %}
|
{% if v.agendaposter %}<link rel="stylesheet" href="/assets/css/agendaposter.css?v=75">{% elif v.css %}<link rel="stylesheet" href="/@{{v.username}}/css">{% endif %}
|
||||||
{% else %}
|
{% else %}
|
||||||
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
|
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
|
||||||
<link rel="stylesheet" href="/assets/css/main.css?v=74"><link rel="stylesheet" href="/assets/css/{{'DEFAULT_THEME' | app_config}}.css?v=74">
|
<link rel="stylesheet" href="/assets/css/main.css?v=75"><link rel="stylesheet" href="/assets/css/{{'DEFAULT_THEME' | app_config}}.css?v=75">
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
<script src="/assets/js/emoji_modal.js?v=54"></script>
|
<script src="/assets/js/emoji_modal.js?v=55"></script>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
a.emojitab {
|
a.emojitab {
|
||||||
|
|
|
@ -17,11 +17,11 @@
|
||||||
|
|
||||||
{% if v %}
|
{% if v %}
|
||||||
<style>:root{--primary:#{{v.themecolor}}}</style>
|
<style>:root{--primary:#{{v.themecolor}}}</style>
|
||||||
<link rel="stylesheet" href="/assets/css/main.css?v=74"><link rel="stylesheet" href="/assets/css/{{v.theme}}.css?v=74">
|
<link rel="stylesheet" href="/assets/css/main.css?v=75"><link rel="stylesheet" href="/assets/css/{{v.theme}}.css?v=75">
|
||||||
{% if v.agendaposter %}<link rel="stylesheet" href="/assets/css/agendaposter.css?v=74">{% elif v.css %}<link rel="stylesheet" href="/@{{v.username}}/css">{% endif %}
|
{% if v.agendaposter %}<link rel="stylesheet" href="/assets/css/agendaposter.css?v=75">{% elif v.css %}<link rel="stylesheet" href="/@{{v.username}}/css">{% endif %}
|
||||||
{% else %}
|
{% else %}
|
||||||
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
|
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
|
||||||
<link rel="stylesheet" href="/assets/css/main.css?v=74"><link rel="stylesheet" href="/assets/css/{{'DEFAULT_THEME' | app_config}}.css?v=74">
|
<link rel="stylesheet" href="/assets/css/main.css?v=75"><link rel="stylesheet" href="/assets/css/{{'DEFAULT_THEME' | app_config}}.css?v=75">
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
<div class="row justify-content-around">
|
<div class="row justify-content-around">
|
||||||
|
|
|
@ -12,7 +12,7 @@
|
||||||
<title>2-Step Login - {{'SITE_NAME' | app_config}}</title>
|
<title>2-Step Login - {{'SITE_NAME' | app_config}}</title>
|
||||||
|
|
||||||
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
|
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
|
||||||
<link rel="stylesheet" href="/assets/css/main.css?v=74"><link rel="stylesheet" href="/assets/css/{{'DEFAULT_THEME' | app_config}}.css?v=74">
|
<link rel="stylesheet" href="/assets/css/main.css?v=75"><link rel="stylesheet" href="/assets/css/{{'DEFAULT_THEME' | app_config}}.css?v=75">
|
||||||
|
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
|
|
|
@ -55,8 +55,8 @@
|
||||||
|
|
||||||
|
|
||||||
<style>:root{--primary:#{{v.themecolor}}}</style>
|
<style>:root{--primary:#{{v.themecolor}}}</style>
|
||||||
<link rel="stylesheet" href="/assets/css/main.css?v=74"><link rel="stylesheet" href="/assets/css/{{v.theme}}.css?v=74">
|
<link rel="stylesheet" href="/assets/css/main.css?v=75"><link rel="stylesheet" href="/assets/css/{{v.theme}}.css?v=75">
|
||||||
{% if v.agendaposter %}<link rel="stylesheet" href="/assets/css/agendaposter.css?v=74">{% elif v.css %}<link rel="stylesheet" href="/@{{v.username}}/css">{% endif %}
|
{% if v.agendaposter %}<link rel="stylesheet" href="/assets/css/agendaposter.css?v=75">{% elif v.css %}<link rel="stylesheet" href="/@{{v.username}}/css">{% endif %}
|
||||||
|
|
||||||
<link href="/assets/css/fa.css?v=52" rel="stylesheet">
|
<link href="/assets/css/fa.css?v=52" rel="stylesheet">
|
||||||
</head>
|
</head>
|
||||||
|
|
|
@ -40,10 +40,10 @@
|
||||||
|
|
||||||
{% if v %}
|
{% if v %}
|
||||||
<style>:root{--primary:#{{v.themecolor}}}</style>
|
<style>:root{--primary:#{{v.themecolor}}}</style>
|
||||||
<link rel="stylesheet" href="/assets/css/main.css?v=74"><link rel="stylesheet" href="/assets/css/{{v.theme}}.css?v=74">
|
<link rel="stylesheet" href="/assets/css/main.css?v=75"><link rel="stylesheet" href="/assets/css/{{v.theme}}.css?v=75">
|
||||||
{% else %}
|
{% else %}
|
||||||
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
|
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
|
||||||
<link rel="stylesheet" href="/assets/css/main.css?v=74"><link rel="stylesheet" href="/assets/css/{{'DEFAULT_THEME' | app_config}}.css?v=74">
|
<link rel="stylesheet" href="/assets/css/main.css?v=75"><link rel="stylesheet" href="/assets/css/{{'DEFAULT_THEME' | app_config}}.css?v=75">
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
<link href="/assets/css/fa.css?v=52" rel="stylesheet">
|
<link href="/assets/css/fa.css?v=52" rel="stylesheet">
|
||||||
|
|
|
@ -36,7 +36,7 @@
|
||||||
<link href="https://fonts.googleapis.com/css?family=Open+Sans:400,600&display=swap" rel="stylesheet">
|
<link href="https://fonts.googleapis.com/css?family=Open+Sans:400,600&display=swap" rel="stylesheet">
|
||||||
|
|
||||||
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
|
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
|
||||||
<link rel="stylesheet" href="/assets/css/main.css?v=74"><link rel="stylesheet" href="/assets/css/{{'DEFAULT_THEME' | app_config}}.css?v=74">
|
<link rel="stylesheet" href="/assets/css/main.css?v=75"><link rel="stylesheet" href="/assets/css/{{'DEFAULT_THEME' | app_config}}.css?v=75">
|
||||||
|
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
|
|
|
@ -31,7 +31,7 @@
|
||||||
<link href="https://fonts.googleapis.com/css?family=Open+Sans:400,600&display=swap" rel="stylesheet">
|
<link href="https://fonts.googleapis.com/css?family=Open+Sans:400,600&display=swap" rel="stylesheet">
|
||||||
|
|
||||||
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
|
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
|
||||||
<link rel="stylesheet" href="/assets/css/main.css?v=74"><link rel="stylesheet" href="/assets/css/{{'DEFAULT_THEME' | app_config}}.css?v=74">
|
<link rel="stylesheet" href="/assets/css/main.css?v=75"><link rel="stylesheet" href="/assets/css/{{'DEFAULT_THEME' | app_config}}.css?v=75">
|
||||||
|
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
|
|
|
@ -25,12 +25,12 @@
|
||||||
{% block stylesheets %}
|
{% block stylesheets %}
|
||||||
{% if v %}
|
{% if v %}
|
||||||
<style>:root{--primary:#{{v.themecolor}}}</style>
|
<style>:root{--primary:#{{v.themecolor}}}</style>
|
||||||
<link rel="stylesheet" href="/assets/css/main.css?v=74"><link rel="stylesheet" href="/assets/css/{{v.theme}}.css?v=74">
|
<link rel="stylesheet" href="/assets/css/main.css?v=75"><link rel="stylesheet" href="/assets/css/{{v.theme}}.css?v=75">
|
||||||
{% if v.agendaposter %}<link rel="stylesheet" href="/assets/css/agendaposter.css?v=74">{% elif v.css %}<link rel="stylesheet" href="/@{{v.username}}/css">{% endif %}
|
{% if v.agendaposter %}<link rel="stylesheet" href="/assets/css/agendaposter.css?v=75">{% elif v.css %}<link rel="stylesheet" href="/@{{v.username}}/css">{% endif %}
|
||||||
{% else %}
|
{% else %}
|
||||||
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
|
<style>:root{--primary:#{{'DEFAULT_COLOR' | app_config}}</style>
|
||||||
<link rel="stylesheet" href="/assets/css/main.css?v=74">
|
<link rel="stylesheet" href="/assets/css/main.css?v=75">
|
||||||
<link rel="stylesheet" href="/assets/css/{{'DEFAULT_THEME' | app_config}}.css?v=74">
|
<link rel="stylesheet" href="/assets/css/{{'DEFAULT_THEME' | app_config}}.css?v=75">
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue