MCPcopy Create free account
hub / github.com/rilldata/rill / PrintProjectInvites

Method PrintProjectInvites

cli/pkg/printer/resources.go:297–312  ·  view source on GitHub ↗
(invites []*adminv1.ProjectInvite)

Source from the content-addressed store, hash-verified

295}
296
297func (p *Printer) PrintProjectInvites(invites []*adminv1.ProjectInvite) {
298 if len(invites) == 0 {
299 return
300 }
301 rows := make([]*projectInvite, 0, len(invites))
302 for _, i := range invites {
303 rows = append(rows, &projectInvite{
304 Email: i.Email,
305 RoleName: i.RoleName,
306 OrgRoleName: i.OrgRoleName,
307 InvitedBy: i.InvitedBy,
308 Resources: formatResourceNamesPB(i.RestrictResources, i.Resources),
309 })
310 }
311 p.PrintDataWithTitle(rows, "Invites pending acceptance")
312}
313
314type projectInvite struct {
315 Email string `header:"email" json:"email"`

Callers 1

listProjectInvitesFunction · 0.80

Calls 2

PrintDataWithTitleMethod · 0.95
formatResourceNamesPBFunction · 0.85

Tested by

no test coverage detected