Finish /login/oauth/authorize

This commit is contained in:
Yang Luo
2021-03-20 22:34:22 +08:00
parent f89f454e0e
commit 808e6c6283
9 changed files with 22 additions and 26 deletions

View File

@ -69,14 +69,6 @@ func (c *ApiController) DeleteToken() {
c.ServeJSON()
}
func codeToResponse(code *object.Code) *Response {
if code.Code == "" {
return &Response{Status: "error", Msg: code.Message, Data: code.Code}
} else {
return &Response{Status: "ok", Msg: "", Data: code.Code}
}
}
func (c *ApiController) GetOAuthToken() {
grantType := c.Input().Get("grant_type")
clientId := c.Input().Get("client_id")