All checks were successful
Build and Push Docker Image / build-and-push (push) Successful in 3m37s
35 lines
728 B
Go
35 lines
728 B
Go
package users
|
|
|
|
import (
|
|
usersdb "git.kanopo.dev/rhythm/rhythm-backend/internal/db/users"
|
|
"go.uber.org/zap"
|
|
)
|
|
|
|
type Service struct {
|
|
repo usersdb.Querier
|
|
log *zap.SugaredLogger
|
|
}
|
|
|
|
func NewService(repo usersdb.Querier, log *zap.SugaredLogger) *Service {
|
|
return &Service{
|
|
repo: repo,
|
|
log: log,
|
|
}
|
|
}
|
|
|
|
// type LoginReq struct {
|
|
// Email string `json:"email" binding:"required"`
|
|
// Password string `json:"password" binding:"required"`
|
|
// }
|
|
// type AuthRes struct {
|
|
// AccessToken string `json:"accessToken"`
|
|
// RefreshToken string // not parset to json, set with cookies
|
|
// }
|
|
//
|
|
// func (s *Service) Login(req LoginReq) AuthRes {
|
|
// return AuthRes{
|
|
// AccessToken: "ciao",
|
|
// RefreshToken: "ciao",
|
|
// }
|
|
// }
|