first commit
This commit is contained in:
17
app/main/api/internal/handler/user/gettokenhandler.go
Normal file
17
app/main/api/internal/handler/user/gettokenhandler.go
Normal file
@@ -0,0 +1,17 @@
|
||||
package user
|
||||
|
||||
import (
|
||||
"net/http"
|
||||
|
||||
"znc-server/app/main/api/internal/logic/user"
|
||||
"znc-server/app/main/api/internal/svc"
|
||||
"znc-server/common/result"
|
||||
)
|
||||
|
||||
func GetTokenHandler(svcCtx *svc.ServiceContext) http.HandlerFunc {
|
||||
return func(w http.ResponseWriter, r *http.Request) {
|
||||
l := user.NewGetTokenLogic(r.Context(), svcCtx)
|
||||
resp, err := l.GetToken()
|
||||
result.HttpResult(r, w, resp, err)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user