Skip to content

Role permissions stored in model_has_permissions instead of role_has_permissions #2900

@tegarkalam

Description

@tegarkalam

Issue:
When assigning permissions to roles using syncPermissions() or givePermissionTo(), the relationships are stored in model_has_permissions table instead of the dedicated role_has_permissions table.

Expected:

  • Role permissions → role_has_permissions
  • User permissions → model_has_permissions

Actual:
Both stored in model_has_permissions due to polymorphic relationship in HasPermissions trait.

Question:
Is this intentional design? The role_has_permissions table exists but remains unused.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions