get / list implemented

This commit is contained in:
adlerhurst
2025-07-17 15:32:50 +02:00
parent 65cd4ec668
commit bb2d0aff3f
8 changed files with 168 additions and 53 deletions

View File

@@ -56,6 +56,14 @@ type OrganizationDomainRepository interface {
organizationDomainConditions
organizationDomainChanges
// Get returns a single domain based on the criteria.
// If no domain is found, it returns an error of type [database.ErrNotFound].
// If multiple domains are found, it returns an error of type [database.ErrMultipleRows].
Get(ctx context.Context, opts ...database.QueryOption) (*OrganizationDomain, error)
// List returns a list of domains based on the criteria.
// If no domains are found, it returns an empty slice.
List(ctx context.Context, opts ...database.QueryOption) ([]*OrganizationDomain, error)
// Add adds a new domain to the organization.
Add(ctx context.Context, domain *AddOrganizationDomain) error
// Update updates an existing domain in the organization.