Add user post wiping

If a user has spammed a lot of posts and made a mess of the board, this
will allow us to delete all posts by the offending user from the same
IP.

Signed-off-by: Alek Ratzloff <alekratz@gmail.com>
This commit is contained in:
2022-07-17 16:59:23 -07:00
parent 8ea95a927c
commit 1856adaf3b
6 changed files with 90 additions and 1 deletions

View File

@@ -42,6 +42,14 @@ urlpatterns = [
ActionSuccessView.as_view(window_timeout=settings.ACTION_SUCCESS_CLOSE_TIMEOUT),
name="post_delete_success",
),
path("post/wipe/<int:pk>/", PostWipeView.as_view(), name="post_wipe"),
path(
"post/wipe/success/",
ActionSuccessView.as_view(
window_timeout=settings.ACTION_SUCCESS_CLOSE_TIMEOUT, message="Posts wiped."
),
name="post_wipe_success",
),
# Board views
path("post/success/", PostSuccessView.as_view(), name="post_success"),
path("<slug:url>/page/<int:page>/", BoardView.as_view(), name="board_detail"),