shorter links
parent
6955d48e92
commit
d64699948d
|
@ -102,15 +102,13 @@ def approve_art(v, id):
|
||||||
move(old, filename)
|
move(old, filename)
|
||||||
process_image(filename, v, resize=entry.resize, trim=True)
|
process_image(filename, v, resize=entry.resize, trim=True)
|
||||||
|
|
||||||
entry_url = filename.replace('files', SITE_FULL_IMAGES)
|
|
||||||
|
|
||||||
|
|
||||||
author = request.values.get('author').strip()
|
author = request.values.get('author').strip()
|
||||||
author = get_user(author)
|
author = get_user(author)
|
||||||
entry.author_id = author.id
|
entry.author_id = author.id
|
||||||
g.db.add(entry)
|
g.db.add(entry)
|
||||||
badge_grant(author, entry.badge_id)
|
badge_grant(author, entry.badge_id)
|
||||||
|
|
||||||
|
entry_url = f"{SITE_FULL_IMAGES}/i/{SITE_NAME}/{entry.location_kind}/{entry.id}.webp"
|
||||||
|
|
||||||
if v.id != author.id:
|
if v.id != author.id:
|
||||||
msg = f"@{v.username} (a site admin) has approved a {entry.formatted_kind} you made:\n{entry_url}"
|
msg = f"@{v.username} (a site admin) has approved a {entry.formatted_kind} you made:\n{entry_url}"
|
||||||
|
|
|
@ -20,7 +20,7 @@
|
||||||
</a>
|
</a>
|
||||||
|
|
||||||
{% if not v %}
|
{% if not v %}
|
||||||
{% set image = SITE_FULL_IMAGES + "/assets/images/WPD/sidebar/1.webp?x=7" %}
|
{% set image = SITE_FULL_IMAGES + "/i/WPD/sidebar/1.webp?x=7" %}
|
||||||
{% elif IS_FISTMAS() %}
|
{% elif IS_FISTMAS() %}
|
||||||
{% set image = macros.random_image("assets/events/" ~ IS_EVENT() ~ "/images/sidebar/" ~ SITE_NAME ) %}
|
{% set image = macros.random_image("assets/events/" ~ IS_EVENT() ~ "/images/sidebar/" ~ SITE_NAME ) %}
|
||||||
{% elif IS_EVENT() %}
|
{% elif IS_EVENT() %}
|
||||||
|
|
|
@ -17,7 +17,7 @@
|
||||||
|
|
||||||
{# DELETE_ME_PLS #}
|
{# DELETE_ME_PLS #}
|
||||||
{% if not v %}
|
{% if not v %}
|
||||||
{% set image = SITE_FULL_IMAGES + "/assets/images/rDrama/sidebar/63.webp?x=7" %}
|
{% set image = SITE_FULL_IMAGES + "/i/rDrama/sidebar/63.webp?x=7" %}
|
||||||
{% elif hole and hole.sidebarurls %}
|
{% elif hole and hole.sidebarurls %}
|
||||||
{% set image = hole.random_sidebar %}
|
{% set image = hole.random_sidebar %}
|
||||||
{% elif IS_FISTMAS() %}
|
{% elif IS_FISTMAS() %}
|
||||||
|
|
Loading…
Reference in New Issue