Skip to content

Commit

Permalink
sunc
Browse files Browse the repository at this point in the history
  • Loading branch information
IgorPolyakov committed Aug 6, 2024
1 parent 53b283c commit 62ae706
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions docs/CONCEPT.md
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,7 @@
- Дата окончания
- Кто проводит

На текущий момент добавлять/изменять/удалять игры может только пользователи с ролью админ.

### TODO

Expand Down
2 changes: 2 additions & 0 deletions internal/app/handlers/teams.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import (
)

func (h *Handlers) CreateTeam(w http.ResponseWriter, r *http.Request) {
// fixme - создание команды через апрупы - нужен стейт
var team server.TeamRequest
var err error
if err := json.NewDecoder(r.Body).Decode(&team); err != nil {
Expand Down Expand Up @@ -140,6 +141,7 @@ func (h *Handlers) LeaveUserFromTeam(w http.ResponseWriter, r *http.Request, tea
}

func (h *Handlers) TeamMembers(w http.ResponseWriter, r *http.Request, teamId openapi_types.UUID) {
// нужно по парамтрам иметь возможноть получать pending user'ов для опрува
teamRepo := repository.NewTeamMemberRequestRepository(h.DB)
members, err := teamRepo.TeamMembers(r.Context(), teamId)
if err != nil {
Expand Down

0 comments on commit 62ae706

Please sign in to comment.