add personal address

This commit is contained in:
fabien committed 2026-08-18 23:57:08 +02:00
1 parent 50d1ba630e
commit d2a153536f
17 files changed
+239 -50

No files matched your search

@@ -31,8 +31,10 @@ type Session struct {
}
const ContextUserIDKey = "userID"
const ContextEmailKey = "userEmail"
const ContextNameKey = "userName"
const ContextUserAdminKey = "userAdmin"
//const ContextEmailKey = "userEmail"
//const ContextNameKey = "userName"
// Interface définie ici car c'est un port propre au cas d'usage "auth"
type Authenticator interface {
+4 -1
View File
@@ -4,6 +4,7 @@ import (
"context"
"errors"
"fmt"
"time"
"trankilou.fr/lassistanoque/backend/internal/domain"
)
@@ -53,8 +54,10 @@ func (s *Service) Register(registration Registration) (*Session, error) {
if err != nil {
return nil, err
}
now := time.Now()
_, err = s.userRepository.CreateTeam(session.User.ID, &domain.Team{
Label: "Espace personnel",
Label: "Espace personnel",
DateCreated: now,
})
if err != nil {
return nil, err