Draft: Handle moderation privileges #441

Closed
ilja wants to merge 106 commits from gitlab-mr-iid-209 into release/2.5.0
Member

Fix https://git.pleroma.social/pleroma/admin-fe/-/issues/206
For BE MR pleroma/pleroma#7053

  • Make admin-fe aware of privileges
  • Make sure a privileged non-admin can log in
  • Only show menu/options to those who are privileged
    • Sidebar
    • Make sure you're redirected to a privileged route after login
    • Only show privileged options in the pages themselves
      • Users
        • "Moderate multiple users" dropdown
          • Bug: Changing tags wont show if the user can't fetch the config (i.e. is non-admin)
        • "Moderation" dropdown
        • "Create new account"
        • Click a user > "Moderate user"
      • Statuses
        • "Change scope" dropdown
      • Reports
        • "Moderate user" dropdown
      • Moderation Log
        • Link to users and to specific reports
    • Don't do unprivileged calls (e.g. after login /api/pleroma/admin/config is called)
  • Make sure error messages are correct (e.g. when not logged in, you now get message about needing to be admin, but not only admins are able to log in)
  • What if I have privileges, but none to give me a menu? What happens then, is that acceptable, and how to handle it properly? => You're now redirected to the /401 page.
  • Check if https://git.pleroma.social/pleroma/admin-fe/-/issues/213 could/should be done here
Fix https://git.pleroma.social/pleroma/admin-fe/-/issues/206 For BE MR https://git.pleroma.social/pleroma/pleroma/pulls/7053 * [x] Make admin-fe aware of privileges * [x] Make sure a privileged non-admin can log in * [ ] Only show menu/options to those who are privileged * [x] Sidebar * [x] Make sure you're redirected to a privileged route after login * [ ] Only show privileged options in the pages themselves * [ ] Users * [x] "Moderate multiple users" dropdown * [ ] Bug: Changing tags wont show if the user can't fetch the config (i.e. is non-admin) * [x] "Moderation" dropdown * [x] "Create new account" * [x] Click a user > "Moderate user" * [x] Statuses * [x] "Change scope" dropdown * [ ] Reports * [ ] "Moderate user" dropdown * [ ] Moderation Log * [ ] Link to users and to specific reports * [ ] Don't do unprivileged calls (e.g. after login `/api/pleroma/admin/config` is called) * [ ] Make sure error messages are correct (e.g. when not logged in, you now get message about needing to be admin, but not only admins are able to log in) * [x] What if I have privileges, but none to give me a menu? What happens then, is that acceptable, and how to handle it properly? => You're now redirected to the /401 page. * [ ] Check if https://git.pleroma.social/pleroma/admin-fe/-/issues/213 could/should be done here
Member

Is this meant to fix the issue for GitHub or is there other sites that have the same issue as GitHub currently? If the earlier, that was fixed in #440.

Is this meant to fix the issue for GitHub or is there other sites that have the same issue as GitHub currently? If the earlier, that was fixed in #440.
Author
Member

uh, yes. Seems things have been merged in master, but not develop. Which is why I didn't see it..

uh, yes. Seems things have been merged in master, but not develop. Which is why I didn't see it..
Author
Member

probably because master is the default branch, so MR are to there by default

probably because master is the default branch, so MR are to there by default
Member

@lanodan just changed up things. You should be good to go for pulling updates.

@lanodan just changed up things. You should be good to go for pulling updates.

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
blocked
stale
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
pleroma/admin-fe!441
No description provided.