Skip to content

Metadata#4

Merged
4rthem merged 4 commits into
mainfrom
metadata
May 4, 2026
Merged

Metadata#4
4rthem merged 4 commits into
mainfrom
metadata

Conversation

@4rthem

@4rthem 4rthem commented May 4, 2026

Copy link
Copy Markdown
Member

No description provided.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

This PR extends the ACL bundle to support arbitrary per-ACE metadata persisted in the database and exposed via the API/serializer, along with a few related API and type tweaks in the permission layer.

Changes:

  • Add metadata to AccessControlEntry (entity + interface), persist it via the Doctrine repository, accept it via PermissionController, and return it via AceSerializer.
  • Extend PermissionManager::isGranted() with an $ownershipGrants flag and add a resetCache() helper.
  • Introduce a new CHILD_VIEW permission constant (but with shifted bitmask values for existing child permissions).

Reviewed changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
src/Serializer/AceSerializer.php Includes ACE metadata in serialized payloads.
src/Security/Voter/SetPermissionVoter.php Adds typed constant declarations for voter attributes.
src/Security/PermissionManager.php Adds cache reset, ownership bypass flag, and threads metadata through ACE upsert.
src/Security/PermissionInterface.php Adds CHILD_VIEW and updates permission bitmask constants/mapping.
src/Repository/PermissionRepositoryInterface.php Extends repository upsert API to accept metadata.
src/Repository/DoctrinePermissionRepository.php Persists metadata to ACE rows on upsert.
src/Model/AccessControlEntryInterface.php Adds metadata getters/setters to the ACE contract.
src/Entity/AccessControlEntry.php Adds metadata JSON column + accessor methods; updates some Doctrine type declarations.
src/Controller/PermissionController.php Accepts metadata in PUT /ace requests and passes it to the manager.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/Security/PermissionInterface.php
Comment thread src/Controller/PermissionController.php
Comment thread src/Repository/DoctrinePermissionRepository.php
Comment thread src/Security/PermissionManager.php
Comment thread src/Security/PermissionManager.php
Comment thread src/Repository/PermissionRepositoryInterface.php
@4rthem 4rthem merged commit ef31d7c into main May 4, 2026
5 checks passed
@4rthem 4rthem deleted the metadata branch May 4, 2026 18:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants