diff --git a/brutaldon/templates/requests/list.html b/brutaldon/templates/requests/list.html new file mode 100644 index 0000000..6f98d9b --- /dev/null +++ b/brutaldon/templates/requests/list.html @@ -0,0 +1,19 @@ +{% extends "base.html" %} +{% load widget_tweaks %} + +{% block content %} +
+

Follow requests

+ + {% if not requests %} +

No follow requests.

+ {% endif %} + + + {% for request in requests %} + {% include "requests/request_partial.html" %} + {% endfor %} + +
+ +{% endblock %} diff --git a/brutaldon/templates/requests/request_partial.html b/brutaldon/templates/requests/request_partial.html new file mode 100644 index 0000000..32a4ba1 --- /dev/null +++ b/brutaldon/templates/requests/request_partial.html @@ -0,0 +1,21 @@ +
+
+

+ {{ request.acct }} +

+
+
+ {{ request.display_name }} ({{ request.acct }}) +
+
+
+ {% csrf_token %} + + +
+
diff --git a/brutaldon/templates/setup/settings.html b/brutaldon/templates/setup/settings.html index 97363dd..a8f9e22 100644 --- a/brutaldon/templates/setup/settings.html +++ b/brutaldon/templates/setup/settings.html @@ -149,8 +149,9 @@ value="Save" class="button is-primary" > -

Filters and Lists

+

Filters and More

List filters

+

Follow requests

{% endblock %} diff --git a/brutaldon/urls.py b/brutaldon/urls.py index 37b4e97..a37f3ad 100644 --- a/brutaldon/urls.py +++ b/brutaldon/urls.py @@ -64,5 +64,7 @@ urlpatterns = [ path('filters/create', views.create_filter, name='create_filter'), path('filters/delete/', views.delete_filter, name='delete_filter'), path('filters/edit/', views.edit_filter, name='edit_filter'), + path('requests/', views.follow_requests, name='follow_requests'), + path('requests/', views.follow_requests, name='follow_requests'), path('', views.home, name=''), ] diff --git a/brutaldon/views.py b/brutaldon/views.py index f2ad51a..f285a52 100644 --- a/brutaldon/views.py +++ b/brutaldon/views.py @@ -1091,7 +1091,7 @@ def follow_requests(request, id=None): else: if request.POST.get("accept", None): mastodon.follow_request_authorize(id) - elif request.POST.get("rejest", None): + elif request.POST.get("reject", None): mastodon.follow_request_reject(id) return redirect(follow_requests)