Skip to content

AdminAudit Repository#8

Merged
hayesZach merged 14 commits intomasterfrom
feature/adminaudit-repository
Jan 14, 2026
Merged

AdminAudit Repository#8
hayesZach merged 14 commits intomasterfrom
feature/adminaudit-repository

Conversation

@hayesZach
Copy link
Copy Markdown
Collaborator

@hayesZach hayesZach commented Jan 13, 2026

This PR implements the AdminAuditRepository interface and adds unit tests.


Note

Introduces a working admin audit persistence layer and updates related domain types.

  • Implement AdminAuditRepository with Create, Read, Delete, and List (filterable by target_action, target_resource_type, target_resource) in internal/repository/private/adminaudit.go
  • Update models:
    • Add TargetResourceType enum and TargetActionUnknown
    • Reshape AdminAudit to use target_resource_type and string target_resource; switch details to RawJsonb
    • Add helpers: NewMarketplaceAdminAudit, NewKeyAdminAudit, NewReversalAdminAudit
    • Replace Jsonb with RawJsonb type and ToRawJsonb conversion
  • Enhance dto:
    • Extend AdminAuditListOptions (resource type and string resource)
    • Add MarketplaceUpdateOptions.AuditDetails() returning RawJsonb
  • Wire repository in private.go and include AdminAudit in migrations
  • Add extensive unit tests for repository CRUD and listing filters; add testutil.MustRawJsonb

Written by Cursor Bugbot for commit 00b7bd4. This will update automatically on new commits. Configure here.

@hayesZach hayesZach self-assigned this Jan 13, 2026
@hayesZach hayesZach added the Enhancement New feature or request label Jan 13, 2026
@hayesZach hayesZach marked this pull request as ready for review January 13, 2026 21:32
@hayesZach hayesZach requested a review from Step7750 January 13, 2026 23:10
@hayesZach hayesZach merged commit 017def4 into master Jan 14, 2026
2 checks passed
@hayesZach hayesZach deleted the feature/adminaudit-repository branch January 14, 2026 20:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants