This commit is contained in:
2025-05-17 04:36:06 +07:00
parent 8643af86ee
commit 4bd18ee756
13 changed files with 188 additions and 7 deletions
+27
View File
@@ -0,0 +1,27 @@
package services
import (
"evening_detective/internal/models"
"evening_detective/proto"
)
func mapTeamsToTeamAdvanced(team *models.Team) *proto.TeamAdvanced {
return &proto.TeamAdvanced{
Id: team.ID,
Name: team.Name,
}
}
func mapTeamsToTeamFull(team *models.Team) *proto.TeamFull {
return &proto.TeamFull{
Id: team.ID,
Name: team.Name,
Password: team.Password,
}
}
func mapProtoTeamsToTeam(team *proto.Team) *models.Team {
return &models.Team{
Name: team.Name,
}
}