From 5b8ce60d58f8ac5262c443302ab1c1e2c2645150 Mon Sep 17 00:00:00 2001 From: briskt <3172830+briskt@users.noreply.github.com> Date: Thu, 16 Nov 2023 22:01:50 -0700 Subject: [PATCH] create stubs for CreateTenantUser --- app/tenant.go | 8 ++++++++ db/tenant.go | 5 +++++ 2 files changed, 13 insertions(+) diff --git a/app/tenant.go b/app/tenant.go index 3b9581f..f581703 100644 --- a/app/tenant.go +++ b/app/tenant.go @@ -24,6 +24,9 @@ type TenantService interface { // DeleteTenant permanently deletes a tenant and all child objects DeleteTenant(ctx echo.Context, id string) error + + // CreateTenantUser creates a new tenant user + CreateTenantUser(ctx echo.Context, input TenantUserCreateInput) error } // Tenant is the full model that identifies an app Tenant @@ -76,3 +79,8 @@ func (tu *TenantUpdateInput) Validate() error { } return nil } + +// TenantUserCreateInput is a set of fields to define a new tenant user for CreateTenantUser() +type TenantUserCreateInput struct { + Name string +} diff --git a/db/tenant.go b/db/tenant.go index f54eeb5..ed9fbe3 100644 --- a/db/tenant.go +++ b/db/tenant.go @@ -110,6 +110,11 @@ func (s *TenantService) DeleteTenant(ctx echo.Context, id string) error { return nil } +// CreateTenantUser permanently deletes a tenant and all child objects +func (s *TenantService) CreateTenantUser(ctx echo.Context, input app.TenantUserCreateInput) error { + return nil +} + // findTenantByID is a helper function to fetch a tenant by ID. func findTenantByID(ctx echo.Context, id string) (Tenant, error) { var tenant Tenant