diff --git a/bookwyrm/activitypub/note.py b/bookwyrm/activitypub/note.py index 263ddb2a..b478c96d 100644 --- a/bookwyrm/activitypub/note.py +++ b/bookwyrm/activitypub/note.py @@ -54,7 +54,7 @@ class Comment(Note): class Review(Comment): ''' a full book review ''' name: str - rating: int + rating: int = None type: str = 'Review' diff --git a/bookwyrm/forms.py b/bookwyrm/forms.py index a2c3e24b..454836bb 100644 --- a/bookwyrm/forms.py +++ b/bookwyrm/forms.py @@ -60,25 +60,29 @@ class RatingForm(CustomForm): class ReviewForm(CustomForm): class Meta: model = models.Review - fields = ['user', 'book', 'name', 'content', 'rating', 'privacy'] + fields = [ + 'user', 'book', 'name', 'content', 'content_warning', 'rating', + 'privacy'] class CommentForm(CustomForm): class Meta: model = models.Comment - fields = ['user', 'book', 'content', 'privacy'] + fields = ['user', 'book', 'content', 'content_warning', 'privacy'] class QuotationForm(CustomForm): class Meta: model = models.Quotation - fields = ['user', 'book', 'quote', 'content', 'privacy'] + fields = [ + 'user', 'book', 'quote', 'content', 'content_warning', 'privacy'] class ReplyForm(CustomForm): class Meta: model = models.Status - fields = ['user', 'content', 'reply_parent', 'privacy'] + fields = [ + 'user', 'content', 'content_warning', 'reply_parent', 'privacy'] class EditUserForm(CustomForm): diff --git a/bookwyrm/templates/snippets/create_status_form.html b/bookwyrm/templates/snippets/create_status_form.html index d6aa3fb3..70062db4 100644 --- a/bookwyrm/templates/snippets/create_status_form.html +++ b/bookwyrm/templates/snippets/create_status_form.html @@ -26,6 +26,16 @@ {% endif %} + +
{% include 'snippets/stars.html' with rating=status.rating %}
+{{ status.content_warning }}
@@ -16,13 +25,6 @@ {% endif %} - {% if status.status_type == 'Review' %} -{{ status.quote }}