Documentation ¶
Index ¶
- type Dao
- func (d *Dao) AccountInfo(c context.Context, mid int64) (res *model.AsoAccount, err error)
- func (d *Dao) AddToken(c context.Context, t *model.Perm) (affected int64, err error)
- func (d *Dao) Apps(c context.Context) (res []*model.App, err error)
- func (d *Dao) AsoAccount(c context.Context, identify, identifyHash string) (res []*model.AsoAccount, err error)
- func (d *Dao) ByTel(c context.Context, tdoByTel model.TdoByTel) (byTel *model.ResByTel, err error)
- func (d *Dao) Captcha(c context.Context, ip string) (captchaData *model.CaptchaData, err error)
- func (d *Dao) Close() (err error)
- func (d *Dao) DelOriginMissMatchFlagCache(c context.Context, identify string) (err error)
- func (d *Dao) DelOriginTokenCache(c context.Context, accessToken string) (err error)
- func (d *Dao) DelTokenCache(c context.Context, accessToken string) (err error)
- func (d *Dao) InfoCache(c context.Context, mid int64) (info *model.Info, err error)
- func (d *Dao) InfoPBCache(c context.Context, key string) (res *model.Info, err error)
- func (d *Dao) Login(c context.Context, query, cookie string) (loginToken *model.LoginToken, err error)
- func (d *Dao) LoginOrigin(c context.Context, userid, rsaPwd string) (loginToken *model.LoginToken, err error)
- func (d *Dao) MemberInfo(c context.Context, mid int64) (res *model.Info, err error)
- func (d *Dao) MyInfo(c context.Context, accessKey string) (accountInfo *model.Info, err error)
- func (d *Dao) Oauth(c context.Context, uri, accessKey, from string) (token *model.Token, err error)
- func (d *Dao) OriginMissMatchFlagCache(c context.Context, identify string) (res []byte, err error)
- func (d *Dao) OriginTokenCache(c context.Context, accessToken string) (token *model.Token, err error)
- func (d *Dao) Ping(c context.Context) (err error)
- func (d *Dao) RSAKeyOrigin(c context.Context) (key *model.RSAKey, err error)
- func (d *Dao) Reg(c context.Context, tdoReg model.TdoReg) (reg *model.ResReg, err error)
- func (d *Dao) RegV2(c context.Context, tdoRegV2 model.TdoRegV2) (regV2 *model.ResRegV2, err error)
- func (d *Dao) RegV3(c context.Context, tdoRegV3 model.TdoRegV3) (regV3 *model.ResRegV3, err error)
- func (d *Dao) RenewToken(c context.Context, uri, ak, from string) (renewToken *model.RenewToken, err error)
- func (d *Dao) SendSms(c context.Context, tdoSendSms model.TdoSendSms) (err error)
- func (d *Dao) SetInfoCache(c context.Context, info *model.Info) (err error)
- func (d *Dao) SetOriginMissMatchFlagCache(c context.Context, identify string, flag []byte) (err error)
- func (d *Dao) SetOriginTokenCache(c context.Context, token *model.Token) (err error)
- func (d *Dao) SetTokenCache(c context.Context, token *model.Perm) (err error)
- func (d *Dao) Token(c context.Context, accessToken string) (res *model.Perm, err error)
- func (d *Dao) TokenCache(c context.Context, accessToken string) (token *model.Perm, err error)
- func (d *Dao) TokenFromOtherRegion(c context.Context, accessToken string) (res *model.Perm, err error)
- func (d *Dao) TokenPBCache(c context.Context, key string) (res *model.Perm, err error)
- func (d *Dao) UpdateToken(c context.Context, t *model.Perm) (affected int64, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Dao ¶
type Dao struct {
// contains filtered or unexported fields
}
Dao dao
func (*Dao) AccountInfo ¶
AccountInfo get account info.
func (*Dao) AsoAccount ¶
func (d *Dao) AsoAccount(c context.Context, identify, identifyHash string) (res []*model.AsoAccount, err error)
AsoAccount get aso account.
func (*Dao) DelOriginMissMatchFlagCache ¶
DelOriginMissMatchFlagCache delete origin miss match flag.
func (*Dao) DelOriginTokenCache ¶
DelOriginTokenCache delete passport token from cache.
func (*Dao) DelTokenCache ¶
DelTokenCache delete token from cache.
func (*Dao) InfoPBCache ¶
InfoPBCache get info pb cache.
func (*Dao) Login ¶
func (d *Dao) Login(c context.Context, query, cookie string) (loginToken *model.LoginToken, err error)
Login login via model api.
func (*Dao) LoginOrigin ¶
func (d *Dao) LoginOrigin(c context.Context, userid, rsaPwd string) (loginToken *model.LoginToken, err error)
LoginOrigin login via passport api.
func (*Dao) MemberInfo ¶
MemberInfo get member info.
func (*Dao) OriginMissMatchFlagCache ¶
OriginMissMatchFlagCache get origin miss match flag.
func (*Dao) OriginTokenCache ¶
func (d *Dao) OriginTokenCache(c context.Context, accessToken string) (token *model.Token, err error)
OriginTokenCache set passport token into cache.
func (*Dao) RSAKeyOrigin ¶
RSAKeyOrigin get rsa pub key and ts hash via passport api.
func (*Dao) RenewToken ¶
func (d *Dao) RenewToken(c context.Context, uri, ak, from string) (renewToken *model.RenewToken, err error)
RenewToken renew token via passport api.
func (*Dao) SetInfoCache ¶
SetInfoCache set info into cache.
func (*Dao) SetOriginMissMatchFlagCache ¶
func (d *Dao) SetOriginMissMatchFlagCache(c context.Context, identify string, flag []byte) (err error)
SetOriginMissMatchFlagCache set origin miss match flag cache.
func (*Dao) SetOriginTokenCache ¶
SetOriginTokenCache set passport token into cache.
func (*Dao) SetTokenCache ¶
SetTokenCache set token into cache.
func (*Dao) TokenCache ¶
TokenCache get token from cache.
func (*Dao) TokenFromOtherRegion ¶
func (d *Dao) TokenFromOtherRegion(c context.Context, accessToken string) (res *model.Perm, err error)
TokenFromOtherRegion get token from otherRegion.
func (*Dao) TokenPBCache ¶
TokenPBCache get token pb cache.