Big upheaval of how the reports system works

* There are now Reports and ReportRecords.
* Reports coordinate to what moderators see, and ReportRecords
  coordinate with the reports that are created by individual users.
* Reports keep track of the report reason and the creating user.
* ReportRecords keep track of the total weight and whether this report
  requires urgent attention or not.
* ReportRecord keeps track of its own weight and urgency because then we
  can sort by weight and urgency in the admin view.

Signed-off-by: Alek Ratzloff <alekratz@gmail.com>
This commit is contained in:
2022-06-19 22:03:01 -07:00
parent 5742dc4dc2
commit 6bda7f4f2d
5 changed files with 85 additions and 13 deletions

View File

@@ -4,7 +4,7 @@ from django.shortcuts import render, get_object_or_404
from django.views.generic import DetailView
from django.views.generic.edit import CreateView
from django.urls import reverse, reverse_lazy
from board.models import Post, Board, Report
from board.models import Post, Board, Report, ReportRecord
from board.forms import PostForm, ReplyForm, ReportForm
__all__ = ("BoardView", "PostView", "ReportView")