Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

predefined report reasons & improved reporter UI #2842

Merged
merged 9 commits into from
Jun 22, 2020

Conversation

rigelk
Copy link
Collaborator

@rigelk rigelk commented Jun 8, 2020

As mentioned in #1781, predefined reasons might help triage reports. I also plan to add timestamps as potential additions to a report, to help pin down the relevant parts of a video, as well as a player within the report modal.

TODO:

  • UI for predefined reasons within modal
  • UI for video playback within modal
  • client service
  • backend API POST parameters
  • backend API GET attributes
  • backend API GET filtering
  • UI for admin abuse list display
  • UI for admin abuse list filtering
  • models
  • migration
  • federation
  • tests

closes #1781

@rigelk rigelk added UI non-trivial UI changes, that might need discussion Component: Moderation :godmode: Component: Federation 🎡 labels Jun 8, 2020
@tcitworld
Copy link
Collaborator

Funkwhale uses hashtags to give a reason for the report IIRC.

@rigelk rigelk force-pushed the report-reasons branch 2 times, most recently from fb8005c to 7333edd Compare June 13, 2020 14:54
@rigelk
Copy link
Collaborator Author

rigelk commented Jun 13, 2020

For reference, the abuse representation in Funkwhale is https://dev.funkwhale.audio/funkwhale/funkwhale/-/blob/develop/api/funkwhale_api/federation/serializers.py#L1728-1740, with a tag representation as follows:

{"type": "Hashtag", "name": "#{}".format(tag_name)}

In my current implementation I use name to store the predefinedReasonId, but maybe we could use another field for this.

@rigelk rigelk requested a review from Chocobozzz June 13, 2020 19:57
@rigelk rigelk marked this pull request as ready for review June 13, 2020 20:54
@rigelk rigelk force-pushed the report-reasons branch 3 times, most recently from f91674e to b65ff55 Compare June 18, 2020 16:45
@rigelk rigelk requested a review from Chocobozzz June 18, 2020 16:45
Copy link
Owner

@Chocobozzz Chocobozzz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add tests

shared/models/videos/abuse/video-abuse-reason.model.ts Outdated Show resolved Hide resolved
shared/models/videos/abuse/video-abuse-reason.model.ts Outdated Show resolved Hide resolved
server/middlewares/validators/videos/video-abuses.ts Outdated Show resolved Hide resolved
server/middlewares/validators/videos/video-abuses.ts Outdated Show resolved Hide resolved
server/models/video/video-abuse.ts Outdated Show resolved Hide resolved
server/models/video/video-abuse.ts Outdated Show resolved Hide resolved
server/models/video/video-abuse.ts Outdated Show resolved Hide resolved
@rigelk rigelk requested a review from Chocobozzz June 20, 2020 21:34
@rigelk rigelk force-pushed the report-reasons branch 3 times, most recently from 0a218b4 to c080143 Compare June 21, 2020 10:13
Copy link
Owner

@Chocobozzz Chocobozzz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add check-params tests to test predefinedReasons, startAt and endAt params.

After that, ready to merge 👍

shared/models/videos/abuse/video-abuse-reason.model.ts Outdated Show resolved Hide resolved
server/models/video/video-abuse.ts Outdated Show resolved Hide resolved
support/doc/api/openapi.yaml Show resolved Hide resolved
@rigelk rigelk changed the title Predefined report reasons & improved reporter UI predefined report reasons & improved reporter UI Jun 22, 2020
@rigelk rigelk merged commit 1ebddad into Chocobozzz:develop Jun 22, 2020
@rigelk rigelk deleted the report-reasons branch June 22, 2020 11:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: Federation 🎡 Component: Moderation :godmode: UI non-trivial UI changes, that might need discussion
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add a list of predefined report reasons
3 participants