feat(invite): redesign for pending invite list, added revoke button and link, copy invite also works now, #2353

This commit is contained in:
Torkel Ödegaard
2015-07-20 14:26:49 +02:00
parent 3242354a4b
commit 024c112944
7 changed files with 16 additions and 4 deletions
+4
View File
@@ -16,6 +16,10 @@ func GetPendingOrgInvites(c *middleware.Context) Response {
return ApiError(500, "Failed to get invites from db", err)
}
for _, invite := range query.Result {
invite.Url = setting.ToAbsUrl("invite/" + invite.Code)
}
return Json(200, query.Result)
}
+1
View File
@@ -75,6 +75,7 @@ type TempUserDTO struct {
Role string `json:"role"`
InvitedBy string `json:"invitedBy"`
Code string `json:"code"`
Url string `json:"url"`
EmailSent bool `json:"emailSent"`
EmailSentOn time.Time `json:"emailSentOn"`
Created time.Time `json:"createdOn"`
+1
View File
@@ -54,6 +54,7 @@ func GetTempUsersForOrg(query *m.GetTempUsersForOrgQuery) error {
tu.email as email,
tu.name as name,
tu.role as role,
tu.code as code,
tu.email_sent as email_sent,
tu.email_sent_on as email_sent_on,
tu.created as created,