]> cat aescling's git repositories - mastodon.git/commit
Add appeals (#17364)
authorEugen Rochko <eugen@zeonfederated.com>
Mon, 14 Feb 2022 20:27:53 +0000 (21:27 +0100)
committerGitHub <noreply@github.com>
Mon, 14 Feb 2022 20:27:53 +0000 (21:27 +0100)
commit564efd06515edc524a8a1cdf7a3d8a7d9a376c04
treea0d0a8ec693e06ef67ef25ec22128da291c318d1
parent5be705e1e0e3c05486c6069a7c8387c123a6d405
Add appeals (#17364)

* Add appeals

* Add ability to reject appeals and ability to browse pending appeals in admin UI

* Add strikes to account page in settings

* Various fixes and improvements

- Add separate notification setting for appeals, separate from reports
- Fix style of links in report/strike header
- Change approving an appeal to not restore statuses (due to federation complexities)
- Change style of successfully appealed strikes on account settings page
- Change account settings page to only show unappealed or recently appealed strikes

* Change appealed_at to overruled_at

* Fix missing method error
60 files changed:
app/controllers/admin/accounts_controller.rb
app/controllers/admin/dashboard_controller.rb
app/controllers/admin/disputes/appeals_controller.rb [new file with mode: 0644]
app/controllers/auth/registrations_controller.rb
app/controllers/disputes/appeals_controller.rb [new file with mode: 0644]
app/controllers/disputes/base_controller.rb [new file with mode: 0644]
app/controllers/disputes/strikes_controller.rb [new file with mode: 0644]
app/helpers/admin/account_moderation_notes_helper.rb
app/helpers/admin/action_logs_helper.rb
app/helpers/admin/trends/statuses_helper.rb [new file with mode: 0644]
app/javascript/styles/mastodon/admin.scss
app/mailers/admin_mailer.rb
app/mailers/user_mailer.rb
app/models/account.rb
app/models/account_filter.rb
app/models/account_warning.rb
app/models/admin/action_log_filter.rb
app/models/admin/appeal_filter.rb [new file with mode: 0644]
app/models/appeal.rb [new file with mode: 0644]
app/models/user.rb
app/policies/account_warning_policy.rb [new file with mode: 0644]
app/policies/appeal_policy.rb [new file with mode: 0644]
app/services/appeal_service.rb [new file with mode: 0644]
app/services/approve_appeal_service.rb [new file with mode: 0644]
app/views/admin/account_moderation_notes/_account_moderation_note.html.haml [deleted file]
app/views/admin/account_warnings/_account_warning.html.haml
app/views/admin/accounts/show.html.haml
app/views/admin/dashboard/index.html.haml
app/views/admin/disputes/appeals/_appeal.html.haml [new file with mode: 0644]
app/views/admin/disputes/appeals/index.html.haml [new file with mode: 0644]
app/views/admin/report_notes/_report_note.html.haml
app/views/admin/reports/show.html.haml
app/views/admin_mailer/new_appeal.text.erb [new file with mode: 0644]
app/views/auth/registrations/_account_warning.html.haml [new file with mode: 0644]
app/views/auth/registrations/_status.html.haml
app/views/disputes/strikes/show.html.haml [new file with mode: 0644]
app/views/settings/preferences/notifications/show.html.haml
app/views/statuses/_detailed_status.html.haml
app/views/user_mailer/appeal_approved.html.haml [new file with mode: 0644]
app/views/user_mailer/appeal_approved.text.erb [new file with mode: 0644]
app/views/user_mailer/appeal_rejected.html.haml [new file with mode: 0644]
app/views/user_mailer/appeal_rejected.text.erb [new file with mode: 0644]
app/views/user_mailer/warning.html.haml
config/brakeman.ignore
config/locales/en.yml
config/locales/simple_form.en.yml
config/navigation.rb
config/routes.rb
config/settings.yml
db/migrate/20220124141035_create_appeals.rb [new file with mode: 0644]
db/migrate/20220210153119_add_overruled_at_to_account_warnings.rb [new file with mode: 0644]
db/schema.rb
spec/controllers/admin/disputes/appeals_controller_spec.rb [new file with mode: 0644]
spec/controllers/disputes/appeals_controller_spec.rb [new file with mode: 0644]
spec/controllers/disputes/strikes_controller_spec.rb [new file with mode: 0644]
spec/fabricators/account_warning_fabricator.rb
spec/fabricators/appeal_fabricator.rb [new file with mode: 0644]
spec/mailers/previews/admin_mailer_preview.rb
spec/mailers/previews/user_mailer_preview.rb
spec/models/appeal_spec.rb [new file with mode: 0644]