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

New permissions framework #1705

Merged
merged 106 commits into from Jan 4, 2024
Merged

New permissions framework #1705

merged 106 commits into from Jan 4, 2024

Conversation

rafalp
Copy link
Owner

@rafalp rafalp commented Dec 21, 2023

New permission system for Misago. Will exist in parallel to old one until all features are using it exclusively.

Fixes #1527

TODO

  • Datamodel
    • User model
    • Group model
  • Admin auth
    • Use misago.User.is_misago_admin for misago admin status
    • Use misago.User.is_misago_root for misago super-admin status
    • Update admin auth logic checking to ignore is_staff and is_superuser
    • Update admin auth tests
  • Groups admin
    • List groups
    • Reorder groups
    • Create group
    • Copy new group's permissions from other group
    • Edit group
    • Edit group category permissions
    • Copy existing group's permissions from other group
    • Make a default
    • Delete group
    • View members
    • Invalidate groups cache
  • Users admin
    • Create user with groups
    • Edit user groups
    • Display user main group on list
    • Search users with main group
    • Search users with any group
    • Show admin users by group
  • Categories admin
    • Copy category permissions
    • Change category permissions
  • Moderators admin
    • List moderators
    • Add moderator
    • Edit moderator
    • Delete moderator
  • Add "Deprecated" warnings to old admin pages
    • Ranks
    • Permissions
    • Category permissions
    • Users
  • Permissions factory
    • Get permissions
    • Cache permissions
    • Build permissions
    • Build category permissions
    • Lazy user permissions proxy
    • Debug Toolbar Tab
  • Auth (other)
    • Exclude user.is_misago_admin from ban checks
    • Replace user.is_staff in special conditions with user.is_misago_admin
  • Tests
    • Check staffuser fixture use in tests
    • Check superuser fixture use in tests
  • Update fake_category factory to set default permissions

@rafalp rafalp added area: frontend This issue involves JavaScript, React.js and Node area: docs area: backend This issue involves Python, Django or dependency (eg. database) area: theme This issue involves HTML and CSS feature: auth This issue involves auth feature: read tracker Tracks read and unread threads and posts feature: search Searching for content or users feature: extensions Extension points for 3rd party plugins and customizations feature: threads list Lists of threads feature: admin Affects admin control panel labels Dec 21, 2023
@rafalp rafalp added this to the Holidays push milestone Dec 21, 2023
@rafalp rafalp self-assigned this Dec 21, 2023
@rafalp rafalp changed the title New permissions New permissions framework Dec 21, 2023
@coveralls
Copy link

coveralls commented Dec 21, 2023

Coverage Status

coverage: 98.649% (+0.06%) from 98.587%
when pulling 91ce26b on fix-1527-new-permission-system
into 0c99ee3 on main.

@rafalp rafalp force-pushed the fix-1527-new-permission-system branch from 09287fe to 6aab883 Compare December 25, 2023 12:01
@rafalp rafalp merged commit 3315a1d into main Jan 4, 2024
2 checks passed
@rafalp rafalp deleted the fix-1527-new-permission-system branch January 4, 2024 19:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: backend This issue involves Python, Django or dependency (eg. database) area: docs area: frontend This issue involves JavaScript, React.js and Node area: theme This issue involves HTML and CSS feature: admin Affects admin control panel feature: auth This issue involves auth feature: extensions Extension points for 3rd party plugins and customizations feature: read tracker Tracks read and unread threads and posts feature: search Searching for content or users feature: threads list Lists of threads
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Simplify permissions system
2 participants