feat: Add basic modqueue view

This commit is contained in:
moanos [he/him] 2024-04-07 09:03:20 +02:00
parent 6da21a2786
commit 3faf7d58ac
3 changed files with 18 additions and 1 deletions

View File

@ -0,0 +1,10 @@
{% extends "fellchensammlung/base_generic.html" %}
{% load i18n %}
{% block content %}
<h1>{% translate "Modqueue" %}</h1>
<p>{% translate "Erlaube oder blockiere Vermittlungsanzeigen die bisher noch zurückgehaltemn werden " %}</p>
{% for report in reports %}
{% include "fellchensammlung/partials/partial-report.html" %}
{% endfor %}
{% endblock %}

View File

@ -27,6 +27,7 @@ urlpatterns = [
path("melden/<int:adoption_notice_id>/", views.report_adoption, name="report-adoption-notice"),
path("meldung/<uuid:report_id>/", views.report_detail, name="report-detail"),
path("meldung/<uuid:report_id>/sucess", views.report_detail_success, name="report-detail-success"),
path("modqueue/", views.modqueue, name="modqueue"),
###########
## USERS ##

View File

@ -125,3 +125,9 @@ def member_detail(request, user):
member = Member.objects.get(user=user)
context = {"member": member}
return render(request, 'fellchensammlung/details/detail-member.html', context=context)
def modqueue(request):
open_reports = Report.objects.filter(status=Report.WAITING)
context = {"reports": open_reports}
return render(request, 'fellchensammlung/modqueue.html', context=context)