-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
676f61f
commit cb918af
Showing
10 changed files
with
2,520 additions
and
2,681 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
43 changes: 43 additions & 0 deletions
43
pkg/github/models/organization_custom_organization_role_create_schema_base_role.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
package models | ||
// The system role from which this role can inherit permissions. | ||
type OrganizationCustomOrganizationRoleCreateSchema_base_role int | ||
|
||
const ( | ||
READ_ORGANIZATIONCUSTOMORGANIZATIONROLECREATESCHEMA_BASE_ROLE OrganizationCustomOrganizationRoleCreateSchema_base_role = iota | ||
TRIAGE_ORGANIZATIONCUSTOMORGANIZATIONROLECREATESCHEMA_BASE_ROLE | ||
WRITE_ORGANIZATIONCUSTOMORGANIZATIONROLECREATESCHEMA_BASE_ROLE | ||
MAINTAIN_ORGANIZATIONCUSTOMORGANIZATIONROLECREATESCHEMA_BASE_ROLE | ||
ADMIN_ORGANIZATIONCUSTOMORGANIZATIONROLECREATESCHEMA_BASE_ROLE | ||
) | ||
|
||
func (i OrganizationCustomOrganizationRoleCreateSchema_base_role) String() string { | ||
return []string{"read", "triage", "write", "maintain", "admin"}[i] | ||
} | ||
func ParseOrganizationCustomOrganizationRoleCreateSchema_base_role(v string) (any, error) { | ||
result := READ_ORGANIZATIONCUSTOMORGANIZATIONROLECREATESCHEMA_BASE_ROLE | ||
switch v { | ||
case "read": | ||
result = READ_ORGANIZATIONCUSTOMORGANIZATIONROLECREATESCHEMA_BASE_ROLE | ||
case "triage": | ||
result = TRIAGE_ORGANIZATIONCUSTOMORGANIZATIONROLECREATESCHEMA_BASE_ROLE | ||
case "write": | ||
result = WRITE_ORGANIZATIONCUSTOMORGANIZATIONROLECREATESCHEMA_BASE_ROLE | ||
case "maintain": | ||
result = MAINTAIN_ORGANIZATIONCUSTOMORGANIZATIONROLECREATESCHEMA_BASE_ROLE | ||
case "admin": | ||
result = ADMIN_ORGANIZATIONCUSTOMORGANIZATIONROLECREATESCHEMA_BASE_ROLE | ||
default: | ||
return nil, nil | ||
} | ||
return &result, nil | ||
} | ||
func SerializeOrganizationCustomOrganizationRoleCreateSchema_base_role(values []OrganizationCustomOrganizationRoleCreateSchema_base_role) []string { | ||
result := make([]string, len(values)) | ||
for i, v := range values { | ||
result[i] = v.String() | ||
} | ||
return result | ||
} | ||
func (i OrganizationCustomOrganizationRoleCreateSchema_base_role) isMultiValue() bool { | ||
return false | ||
} |
Oops, something went wrong.