Repository navigation
chore: remove store awareness from usermanager - #96
Merged
Merged
Conversation
Store and ownership belong to the store package and to ACL, not to this component. Replaces every storeId reference with a neutral one, so the component holds no store-scoped concepts of its own. - UserSchema: the details column comment becomes "Plugin extension data as JSON"; the column is unmapped by this component either way. - Entity/User: getOwnerId() and getResourceId() docblocks describe the ACL contract and its consumers without naming a store. - UserRepositoryInterface::findAll() no longer documents a store filter; the narrowing arguments it already accepts are the caller's. - Tests: no fixture is store-shaped. The repository join case uses a neutral profile table, and the details assertions use generic keys. - Docs and plans lose the storeId rows. - plan/plan-storeid-migration.md is deleted. Its code purge is already complete in src/ and test/, and the remaining phases are store-package work. The details JSON column stays: it is the extension point the contract documents, not store data. Closes #37 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
Store and ownership are store-package and ACL concerns. This component should hold no store-scoped concepts, and issue #37's acceptance bar is "webware-usermanager has zero references to storeId (grep confirms)".
What changed
src/Console/Schema/UserSchema.phpsrc/Entity/User.phpgetOwnerId()andgetResourceId()docblocks describe the ACL contract and its consumers without naming a storesrc/Repository/UserRepositoryInterface.phpfindAll()no longer documents a store filter; the narrowing arguments it already accepts are the caller'stest/unit/Console/Schema/UserSchemaTest.phptest/unit/Entity/UserTest.phptest/unit/Repository/UserRepositoryTest.phpprofiletable instead of thestorejoindocs/user-interface.mdplan/plan-admin-create-user.md,docs/plan-admin-create-user.mdplan/plan-admin-edit-user.mdplan/roleid-audit-results.mdplan/plan-storeid-migration.mdWhy the plan document is deleted
Its Phase 2 code purge is already complete in
src/andtest/, and phases 1, 3 and 4 are store-package work: the column migration, theparamsrendering, and the store registration flow. Every naming reference it carries (SaveUserCommand,SaveUserHandler) points at classes this component no longer has.Why the
detailsJSON column staysdetailsis not store data. It is the unmapped-row extension point in theWebware\Core\UserInterfacecontract, and the store package already reads and writes it throughgetDetail()andwithDetail(). Removing the column would remove a contract surface, not store awareness.Verification
grep -i storeidover the tracked tree: 0 matchesphpunit --testsuite "unit test": OK (432 tests, 1320 assertions)mago fmt --check: all files already formattedmago lint: no issuesmago analyze: no issuesmago guard: no issuesCloses #37
Co-authored-by: Copilot 223556219+Copilot@users.noreply.github.com