2023-02-24 06:31:06 +00:00
{% extends "default.html" %}
{% block pagetitle %}Ping Groups{% endblock %}
{% block content %}
2023-10-29 12:51:00 +00:00
< div class = "px-3" >
< h3 class = "mt-3" > Create Ping Group< / h3 >
< form class = "mt-3" action = "/create_group" method = "post" data-nonce = "{{g.nonce}}" data-onsubmit = "sendFormXHRReload(this)" >
< div class = "container pb-0" style = "background-color: transparent !important" >
< div class = "row" >
2024-02-15 18:48:51 +00:00
< div class = "col col-md-6 px-0 pt-3 py-md-0" >
2023-10-29 12:51:00 +00:00
< div class = "body" >
< input hidden name = "formkey" value = "{{v|formkey}}" >
2024-02-23 21:08:26 +00:00
< label for = "group-name" > Group Name< / label >
< input id = "group-name" minlength = "3" maxlength = "25" pattern = '[a-zA-Z0-9_\-]*' class = "form-control" type = "text" name = "name" required >
2023-10-29 12:51:00 +00:00
< small class = "form-text text-muted" > 3-25 characters, including letters, numbers, _ , and -< / small >
< div class = "footer" >
< div class = "d-flex" >
< button type = "submit" class = "btn btn-primary ml-auto" { % if v . marseybux + v . coins < cost % } disabled { % endif % } > Create Group< / button >
< / div >
2024-02-12 13:01:54 +00:00
< p class = "mt-2 mr-1 ml-3" style = "float: right" > < b > Cost< / b > : {{cost}} coins or marseybux< / p >
2023-09-15 10:51:39 +00:00
< / div >
< / div >
2024-02-14 14:24:14 +00:00
2023-09-15 10:51:39 +00:00
< / div >
< / div >
< / div >
2023-10-29 12:51:00 +00:00
< / form >
2023-09-15 10:51:39 +00:00
2024-02-15 18:48:51 +00:00
< p id = "group-warning" class = "text-danger" >
2024-02-14 15:04:17 +00:00
Warning: ping groups can get usurped from their owners if they spend more than a month not reviewing membership applications.
< / p >
2024-02-14 14:24:14 +00:00
2024-02-14 15:04:17 +00:00
< h3 class = "mt-5 mb-3" > Ping Groups< / h3 >
2023-10-29 12:51:00 +00:00
< div class = "overflow-x-auto" >
2024-02-12 14:21:51 +00:00
< table class = "ping-groups" >
2024-02-12 14:18:13 +00:00
< thead >
2023-10-29 12:51:00 +00:00
< tr >
< th > #< / th >
< th > Name< / th >
< th class = "members" > Members< / th >
2024-02-13 13:00:58 +00:00
< th > Description< / th >
2023-10-29 12:51:00 +00:00
< th > Created on< / th >
< / tr >
< / thead >
2023-02-24 06:31:06 +00:00
2023-10-29 12:51:00 +00:00
< tbody >
{% for group in groups %}
< tr >
< td > {{loop.index}}< / td >
< td > {{group.name}}< / td >
< td class = "unbreakable" >
< a href = "/!{{group}}" > {{group.member_ids | length}}< / a >
2024-02-11 11:00:37 +00:00
{% if v.id != group.owner_id %}
2023-10-29 12:51:00 +00:00
< button id = "leave-{{group}}" type = "button" class = "ml-3 ml-md-5 btn btn-primary {% if v.id not in group.membership_user_ids %}d-none{% endif %}" data-nonce = "{{g.nonce}}" data-onclick = "postToastSwitch(this,'/!{{group}}/leave','leave-{{group}}','apply-{{group}}','d-none')" >
{%- if v.id in group.member_ids or group.name == 'verifiedrich' -%}
Leave
{%- else -%}
Cancel Application
{%- endif -%}
< / button >
2023-05-05 21:45:25 +00:00
2023-10-29 12:51:00 +00:00
< button id = "apply-{{group}}" type = "button" class = "ml-3 ml-md-5 {% if v.id in group.membership_user_ids %}d-none{% endif %} btn btn-primary" data-nonce = "{{g.nonce}}" data-onclick = "postToastSwitch(this,'/!{{group}}/apply','leave-{{group}}','apply-{{group}}','d-none')" > {% if group.name != 'verifiedrich' %}Apply to {% endif %}Join< / button >
{% endif %}
< / td >
2024-02-13 13:00:58 +00:00
< td >
2024-02-15 18:48:36 +00:00
{% if group.description_html %}
{{group.description_html | safe}}
2024-02-13 13:00:58 +00:00
{% endif %}
< / td >
2023-10-29 12:51:00 +00:00
< td data-time = "{{group.created_utc}}" > < / td >
< / tr >
{% endfor %}
< / tbody >
< / table >
< / div >
2023-02-24 06:31:06 +00:00
< / div >
{% endblock %}