feat:完善信息
This commit is contained in:
@ -33,7 +33,7 @@ func (a *Account) Login(c *gin.Context) {
|
||||
api.APIFailure(err.(error))(c)
|
||||
return
|
||||
}
|
||||
data, err := account.NewLogin()().Launch(account.LoginMode(form.Mode), &account.LoginParams{
|
||||
data, err := account.NewLogin()(api.GetLocal()(c).(uint64)).Launch(account.LoginMode(form.Mode), &account.LoginParams{
|
||||
Captcha: struct {
|
||||
Mobile string
|
||||
Captcha string
|
||||
@ -53,7 +53,7 @@ func (a *Account) Register(c *gin.Context) {
|
||||
api.APIFailure(err.(error))(c)
|
||||
return
|
||||
}
|
||||
data, err := account.NewRegister()().Launch(&account.RegisterParams{
|
||||
data, err := account.NewRegister()(api.GetLocal()(c).(uint64)).Launch(&account.RegisterParams{
|
||||
Name: form.Name, Mobile: form.Mobile, Captcha: form.Captcha,
|
||||
Password: form.Password, RepeatPass: form.RepeatPass, Identity: form.Identity,
|
||||
})
|
||||
@ -72,6 +72,6 @@ func (a *Account) Logout(c *gin.Context) {
|
||||
if handle != nil {
|
||||
session = handle.(*service.SessionEnterprise)
|
||||
}
|
||||
err := account.NewLogout()(session).Launch()
|
||||
err := account.NewLogout()(session, api.GetLocal()(c).(uint64)).Launch()
|
||||
api.APIResponse(err)(c)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user