| @@ -1264,9 +1264,9 @@ func SignUp(ctx *context.Context) { | |||||
| // SignUpPost response for sign up information submission | // SignUpPost response for sign up information submission | ||||
| func SignUpPost(ctx *context.Context, cpt *captcha.Captcha, form auth.RegisterForm) { | func SignUpPost(ctx *context.Context, cpt *captcha.Captcha, form auth.RegisterForm) { | ||||
| ctx.Data["Title"] = ctx.Tr("sign_up") | ctx.Data["Title"] = ctx.Tr("sign_up") | ||||
| invitationCode := ctx.Query("invitation_code") | |||||
| ctx.Data["SignUpLink"] = setting.AppSubURL + "/user/sign_up" | ctx.Data["SignUpLink"] = setting.AppSubURL + "/user/sign_up" | ||||
| ctx.Data["invitationCode"] = invitationCode | |||||
| ctx.Data["EnableCaptcha"] = setting.Service.EnableCaptcha | ctx.Data["EnableCaptcha"] = setting.Service.EnableCaptcha | ||||
| ctx.Data["RecaptchaURL"] = setting.Service.RecaptchaURL | ctx.Data["RecaptchaURL"] = setting.Service.RecaptchaURL | ||||
| ctx.Data["CaptchaType"] = setting.Service.CaptchaType | ctx.Data["CaptchaType"] = setting.Service.CaptchaType | ||||
| @@ -1366,7 +1366,6 @@ func SignUpPost(ctx *context.Context, cpt *captcha.Captcha, form auth.RegisterFo | |||||
| } | } | ||||
| log.Trace("Account created: %s", u.Name, ctx.Data["MsgID"]) | log.Trace("Account created: %s", u.Name, ctx.Data["MsgID"]) | ||||
| invitationCode := ctx.Query("invitation_code") | |||||
| log.Info("enter here, and form.InvitaionCode =" + invitationCode) | log.Info("enter here, and form.InvitaionCode =" + invitationCode) | ||||
| if invitationCode != "" { | if invitationCode != "" { | ||||
| RegisteUserByInvitaionCode(invitationCode, u.ID) | RegisteUserByInvitaionCode(invitationCode, u.ID) | ||||