feat(API): user invitations and emails
This commit is contained in:
1 parent
7aae704d0a
commit
acdef18b37
17 files changed
+1687
-7
No files matched your search
@@ -0,0 +1,30 @@
|
||||
package mappers
|
||||
|
||||
import (
|
||||
"RenewCMS/internal/domain/invite"
|
||||
"RenewCMS/internal/infrastructure/persistence/models"
|
||||
)
|
||||
|
||||
func InviteToDomain(m models.Invite) invite.Invite {
|
||||
return invite.Invite{
|
||||
ID: m.ID,
|
||||
Email: m.Email,
|
||||
HashedCode: m.HashedCode,
|
||||
ExpiresAt: m.ExpiresAt,
|
||||
InvitedBy: m.InvitedBy,
|
||||
AcceptedAt: m.AcceptedAt,
|
||||
CreatedAt: m.CreatedAt,
|
||||
}
|
||||
}
|
||||
|
||||
func InviteToModel(i invite.Invite) models.Invite {
|
||||
return models.Invite{
|
||||
ID: i.ID,
|
||||
Email: i.Email,
|
||||
HashedCode: i.HashedCode,
|
||||
ExpiresAt: i.ExpiresAt,
|
||||
InvitedBy: i.InvitedBy,
|
||||
AcceptedAt: i.AcceptedAt,
|
||||
CreatedAt: i.CreatedAt,
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user