mirror of
https://koodu.h-i.works/projects/thebadspace
synced 2025-06-25 16:04:37 -05:00
Added Front listings and member editing
Added the template for to display locations on the front end. Still need to add template for individual locations. Also added member editing. Still need to wire up the avatar uploading but adding and editing member information is possible. Still need to fine tune it according to roles
This commit is contained in:
@ -4,9 +4,30 @@
|
||||
{% endblock %}
|
||||
|
||||
{% block main %}
|
||||
<section role="intro">
|
||||
This is the screendoor member page
|
||||
<section role="members-index">
|
||||
|
||||
{{ include("forms/add-member-form.twig") }}
|
||||
</section>
|
||||
{% endblock %}
|
||||
{% if options.mode == "index" %}
|
||||
<h1>Members</h1>
|
||||
<h2>Manage member accounts</h2>
|
||||
<a href="/den/members/edit/{{ options.you }}">Edit Profile</a>
|
||||
|
|
||||
<a href="/den/members/add">Add Members</a>
|
||||
<h3>Current Members</h3>
|
||||
{% for member in options.list.members %}
|
||||
{% if member.role != 1 %}
|
||||
<a href="/den/members/edit/{{ member.id }}">{{ member.handle }}</a>
|
||||
<br>
|
||||
{% endif %}
|
||||
|
||||
{% endfor %}
|
||||
{% elseif options.mode == "add" %}
|
||||
<h1>Add Member</h1>
|
||||
{{ include("forms/add-member-form.twig") }}
|
||||
|
||||
{% elseif options.mode == "edit" %}
|
||||
<h1>Edit Member</h1>
|
||||
{{ include("forms/edit-member.twig") }}
|
||||
{% endif %}
|
||||
|
||||
</section>
|
||||
{% endblock %}
|
||||
|
@ -30,7 +30,7 @@
|
||||
<a href="/den" title="den index" role="nav-links">
|
||||
<i class="ti ti-door" title="den index"></i>
|
||||
</a>
|
||||
<a href="/den/members" title="members" role="nav-links">
|
||||
<a href="/den/members/page/1" title="members" role="nav-links">
|
||||
<i class="ti ti-users" title="members"></i>
|
||||
</a>
|
||||
<a href="/den/locations/page/1" title="locations" role="nav-links">
|
||||
|
@ -1,4 +1,4 @@
|
||||
<form action="{{ path('members-add') }}" method="post" enctype="multipart/form-data">
|
||||
<form action="{{ path('den-members') }}" method="post" enctype="multipart/form-data">
|
||||
<div>
|
||||
<label>Handle</label><br/>
|
||||
<input type="text" name="handle" value=""/>
|
||||
@ -33,4 +33,5 @@
|
||||
</select>
|
||||
</div>
|
||||
<input type="hidden" name="token" value="{{ csrf_token('upload') }}"/>
|
||||
<input type="hidden" name="mode" value="add"/>
|
||||
<input type="submit" value="Add Member" name="submit_button"></form>
|
||||
|
80
templates/forms/edit-member.twig
Normal file
80
templates/forms/edit-member.twig
Normal file
@ -0,0 +1,80 @@
|
||||
<form action="{{ path('den-members') }}" method="post" enctype="multipart/form-data">
|
||||
<div>
|
||||
<label>Handle</label><br/>
|
||||
<input type="text" name="handle" value="{{ options.currentMember.handle }}"/>
|
||||
<br/>
|
||||
<label>Email</label><br/>
|
||||
<input type="text" name="email" value="{{ options.currentMember.email }}"/>
|
||||
<br/>
|
||||
<label>New Password</label><br/>
|
||||
<input type="password" name="new_pass" value=""/>
|
||||
<br/>
|
||||
<label>New Password Confirm</label><br/>
|
||||
<input type="password" name="new_pass_confirm" value=""/>
|
||||
<br/>
|
||||
<label>Gender</label><br/>
|
||||
<select name="gender">
|
||||
{% if options.currentMember.gender is same as ("non_binary") %}
|
||||
<option value="man">Man</option>
|
||||
<option value="woman">Woman</option>
|
||||
<option value="non_binary" selected>Non-Binary</option>
|
||||
{% elseif options.currentMember.gender is same as ("woman") %}
|
||||
<option value="man">Man</option>
|
||||
<option value="woman" selected>Woman</option>
|
||||
<option value="non_binary">Non-Binary</option>
|
||||
{% elseif options.currentMember.gender is same as ("man") %}
|
||||
<option value="man" selected>Man</option>
|
||||
<option value="woman">Woman</option>
|
||||
<option value="non_binary">Non-Binary</option>
|
||||
{% endif %}
|
||||
</select>
|
||||
<br/>
|
||||
<label>Pronoun</label><br/>
|
||||
<select name="pronoun">
|
||||
{% if options.currentMember.pronoun is same as ("they/them") %}
|
||||
<option value="they/them" selected>They/Them</option>
|
||||
<option value="she/her">She/Her</option>
|
||||
<option value="he/him">He/Him</option>
|
||||
{% elseif options.currentMember.pronoun is same as ("she/her") %}
|
||||
<option value="they/them">They/Them</option>
|
||||
<option value="she/her" selected>She/Her</option>
|
||||
<option value="he/him">He/Him</option>
|
||||
{% elseif options.currentMember.pronoun is same as ("he/him") %}
|
||||
<option value="they/them">They/Them</option>
|
||||
<option value="she/her">She/Her</option>
|
||||
<option value="he/him" selected>He/Him</option>
|
||||
{% endif %}
|
||||
|
||||
</select>
|
||||
<br/>
|
||||
<label>Active?</label><br/>
|
||||
<select name="active">
|
||||
{% if options.currentMember.active %}
|
||||
<option value="false">No</option>
|
||||
<option value="true" selected>Yes</option>
|
||||
{% else %}
|
||||
<option value="false" selected>No</option>
|
||||
<option value="true">Yes</option>
|
||||
{% endif %}
|
||||
</select><br/>
|
||||
<label>Role</label><br/>
|
||||
<select name="role">
|
||||
{% if options.currentMember.role is same as (1) %}
|
||||
<option value="1" selected>Admin</option>
|
||||
<option value="2">Editor</option>
|
||||
<option value="3">Contributer</option>
|
||||
{% elseif options.currentMember.role is same as (2) %}
|
||||
<option value="1">Admin</option>
|
||||
<option value="2" selected>Editor</option>
|
||||
<option value="3">Contributer</option>
|
||||
{% elseif options.currentMember.role is same as (3) %}
|
||||
<option value="1">Admin</option>
|
||||
<option value="2">Editor</option>
|
||||
<option value="3" selected>Contributer</option>
|
||||
{% endif %}
|
||||
</select>
|
||||
</div>
|
||||
<input type="hidden" name="token" value="{{ csrf_token('upload') }}"/>
|
||||
<input type="hidden" name="member_id" value="{{ options.currentMember.id }}"/>
|
||||
<input type="hidden" name="mode" value="edit"/>
|
||||
<input type="submit" value="Edit Member" name="submit_button"></form>
|
@ -5,14 +5,20 @@
|
||||
|
||||
{% block main %}
|
||||
<section role="about">
|
||||
<h1>About The Bad Space</h1>
|
||||
<p>The Bad Space project was born from a need to effectively identify instances that house bad actors and are poorly moderated, which puts marginalized communities at risk. It is an extension of the
|
||||
<strong>#fediblock</strong>
|
||||
hashtag created
|
||||
<a href="https://www.artistmarciax.com/">by Arist Maricia X
|
||||
</a>with additional support from
|
||||
<a href="https://digital.rooting.garden">Ginger</a>
|
||||
to provide a catolog of instances seek to cause harm and reduce the quality of experience in the fediverse.
|
||||
<h1>About</h1>
|
||||
|
||||
<h2>What is The Bad Space?</h2>
|
||||
<p>The Bad Space project was born from a need to effectively identify instances that house bad actors and are poorly moderated, which puts marginalized communities at risk.
|
||||
<p>
|
||||
It is an extension of the
|
||||
<strong>#fediblock</strong>
|
||||
hashtag created by
|
||||
<a href="https://www.artistmarciax.com/">Artist Marcia X</a>
|
||||
with additional support from
|
||||
<a href="https://digital.rooting.garden">Ginger</a>
|
||||
to provide a catolog of instances seek to cause harm and reduce the quality of experience in the fediverse.
|
||||
</p>
|
||||
|
||||
</p>
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user