Documentation
¶
Index ¶
Constants ¶
View Source
const CSVContentType = "text/csv"
Variables ¶
View Source
var ErrNoContent = errors.New("no content")
Functions ¶
This section is empty.
Types ¶
type AggregatedUser ¶
type AggregatedUser struct {
ID string `rql:"name=id,type=string"`
Name string `rql:"name=name,type=string"`
Title string `rql:"name=title,type=string"`
Avatar string `rql:"name=avatar,type=string"`
Email string `rql:"name=email,type=string"`
State user.State `rql:"name=state,type=string"`
RoleNames []string `rql:"name=role_names,type=string"`
RoleTitles []string `rql:"name=role_titles,type=string"`
RoleIDs []string `rql:"name=role_ids,type=string"`
OrgID string `rql:"name=org_id,type=string"`
OrgJoinedAt time.Time `rql:"name=org_joined_at,type=datetime"`
}
type CSVExport ¶
type CSVExport struct {
UserID string `csv:"User ID"`
Name string `csv:"Name"`
Title string `csv:"Title"`
Email string `csv:"Email"`
State string `csv:"State"`
RoleNames string `csv:"Role Names"`
RoleTitles string `csv:"Role Titles"`
OrgJoinedAt string `csv:"Organization Joined At"`
}
CSVExport represents the structure for CSV export of organization users
func NewCSVExport ¶
func NewCSVExport(user AggregatedUser) CSVExport
NewCSVExport converts AggregatedUser to CSVExport
func (CSVExport) GetHeaders ¶
GetHeaders returns the CSV headers based on struct tags
type OrgUsers ¶
type OrgUsers struct {
Users []AggregatedUser `json:"users"`
Group Group `json:"group"`
Pagination Page `json:"pagination"`
}
type Repository ¶
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func NewService ¶
func NewService(repository Repository) *Service
Click to show internal directories.
Click to hide internal directories.