🎨 update project structure

This commit is contained in:
landaiqing
2024-09-29 15:46:35 +08:00
parent 2769467ce2
commit 87f1ff6961
85 changed files with 693 additions and 431 deletions

View File

@@ -0,0 +1,19 @@
package oauth_controller
import "encoding/json"
// ResponseData 返回数据
type ResponseData struct {
AccessToken string `json:"access_token"`
RefreshToken string `json:"refresh_token"`
ExpiresAt int64 `json:"expires_at"`
UID *string `json:"uid"`
}
func (res ResponseData) MarshalBinary() ([]byte, error) {
return json.Marshal(res)
}
func (res ResponseData) UnmarshalBinary(data []byte) error {
return json.Unmarshal(data, &res)
}