diff --git a/files/__main__.py b/files/__main__.py index df1558a8b..40d009216 100644 --- a/files/__main__.py +++ b/files/__main__.py @@ -102,8 +102,8 @@ def before_request(): if '; wv) ' in ua: g.webview = True else: g.webview = False - if 'iphone' in ua or 'ipad' in ua or 'ipod' in ua or 'mac os' in ua or ' firefox/' in ua: g.seal = True - else: g.seal = False + if 'iphone' in ua or 'ipad' in ua or 'ipod' in ua or 'mac os' in ua or ' firefox/' in ua: g.inferior_browser = True + else: g.inferior_browser = False @app.teardown_appcontext diff --git a/files/helpers/const.py b/files/helpers/const.py index 350384c42..5c738b2a9 100644 --- a/files/helpers/const.py +++ b/files/helpers/const.py @@ -555,6 +555,35 @@ AWARDS = { }, } +if SITE == 'PCM': + PCM_AWARDS = { + "croag": { + "kind": "croag", + "title": "Croag", + "description": "Summons Croag on the post.", + "icon": "fas fa-head-side", + "color": "text-gold", + "price": 300 + }, + "toe": { + "kind": "toe", + "title": "Toe Hype", + "description": "Summons Blade's toe on the post.", + "icon": "fas fa-socks", + "color": "text-gold", + "price": 300 + }, + "crab": { + "kind": "crab", + "title": "crab", + "description": "Rave time!", + "icon": "fas fa-glass-cheers", + "color": "text-gold", + "price": 300 + } + } + AWARDS = {**PCM_AWARDS, **AWARDS} + AWARDS2 = deepcopy(AWARDS) for k, val in AWARDS.items(): if val['description'] == '???': AWARDS2.pop(k) diff --git a/files/templates/authforms.html b/files/templates/authforms.html index 063a4ff82..6708f1ee2 100644 --- a/files/templates/authforms.html +++ b/files/templates/authforms.html @@ -15,7 +15,7 @@ {% if v %} - + {% if v.agendaposter %} - + {% endif %} diff --git a/files/templates/default.html b/files/templates/default.html index df1d53a65..3867cbae9 100644 --- a/files/templates/default.html +++ b/files/templates/default.html @@ -2,12 +2,12 @@ - + {% if v %} - + {% if v.agendaposter %} - + {% endif %} {% if sub and sub.css and not request.path.endswith('settings') %} diff --git a/files/templates/home.html b/files/templates/home.html index 2cfd60677..f5f7c15f1 100644 --- a/files/templates/home.html +++ b/files/templates/home.html @@ -171,7 +171,7 @@ {% endif %} -{% if PUSHER_ID and v %} +{% if PUSHER_ID != '3435tdfsdudebussylmaoxxt43' and v %}
{{request.host}}{{v.id}}
{{PUSHER_ID}}
diff --git a/files/templates/log.html b/files/templates/log.html index a9d988f75..63741990d 100644 --- a/files/templates/log.html +++ b/files/templates/log.html @@ -6,7 +6,7 @@ {% block content %} {% if v %} - + {% if v.agendaposter %} - + {% endif %}
diff --git a/files/templates/login.html b/files/templates/login.html index 229bd46b9..cdb34ebde 100644 --- a/files/templates/login.html +++ b/files/templates/login.html @@ -18,7 +18,7 @@ {% endblock %} - + diff --git a/files/templates/login_2fa.html b/files/templates/login_2fa.html index 3b51a3971..723497b84 100644 --- a/files/templates/login_2fa.html +++ b/files/templates/login_2fa.html @@ -14,7 +14,7 @@ 2-Step Login - {{SITE_NAME}} - + diff --git a/files/templates/settings.html b/files/templates/settings.html index 1d2d1f76b..b48978e15 100644 --- a/files/templates/settings.html +++ b/files/templates/settings.html @@ -34,7 +34,7 @@ - + {% if v.agendaposter %} - + {% else %} - + {% endif %} diff --git a/files/templates/sign_up.html b/files/templates/sign_up.html index 19a6fc7ee..7c477a69d 100644 --- a/files/templates/sign_up.html +++ b/files/templates/sign_up.html @@ -31,7 +31,7 @@ {% if ref_user %}{{ref_user.username}} invites you to {{SITE_NAME}}{% else %}Sign up - {{SITE_NAME}}{% endif %} - + diff --git a/files/templates/sign_up_failed_ref.html b/files/templates/sign_up_failed_ref.html index 6a6f80acb..2671f19e8 100644 --- a/files/templates/sign_up_failed_ref.html +++ b/files/templates/sign_up_failed_ref.html @@ -32,7 +32,7 @@ {% if ref_user %}{{ref_user.username}} invites you to {{SITE_NAME}}{% else %}{{SITE_NAME}}{% endif %} - + diff --git a/files/templates/submission.html b/files/templates/submission.html index aa327a0b9..b6e10c660 100644 --- a/files/templates/submission.html +++ b/files/templates/submission.html @@ -22,8 +22,11 @@ {% endif %} +{% if p.award_count("crab") %} + +{% endif %} -{% if g.seal %} +{% if g.inferior_browser %} {% if p.award_count("wholesome") %} +
+ Blade's toe +
+ {% endif %} + + {% if p.award_count("toe") > 1 %} + +
+ Blade's toe +
+ {% endif %} + + {% if p.award_count("toe") > 2 %} + +
+ Blade's toe +
+ {% endif %} + + {% if p.award_count("toe") > 3 %} + +
+ Blade's toe +
+ {% endif %} {% else %} {% if p.award_count("wholesome") %} +
+ + + Blade's toe + + +
+ {% endif %} + + {% if p.award_count("toe") > 1 %} + + + Blade's toe + + + {% endif %} + + {% if p.award_count("toe") > 2 %} + + + Blade's toe + + + {% endif %} + + {% if p.award_count("toe") > 3 %} + + + Blade's toe + + + {% endif %} {% endif %} + + + + {% if p.award_count("train") or p.award_count("scooter") %} + + + croag + +{% endif %} + +{% if p.award_count("croag") > 1 %} + + croag + +{% endif %} + +{% if p.award_count("croag") > 2 %} + + croag + +{% endif %} + +{% if p.award_count("croag") > 3 %} + + croag + +{% endif %} + + + {% if p.award_count("scooter") %} - + {% if v.agendaposter %} - + {% endif %} {% endblock %}