File tree Expand file tree Collapse file tree 8 files changed +81
-62
lines changed Expand file tree Collapse file tree 8 files changed +81
-62
lines changed Original file line number Diff line number Diff line change @@ -8,8 +8,11 @@ import "time"
88
99// CreateUserOption create user options 
1010type  CreateUserOption  struct  {
11- 	SourceID   int64   `json:"source_id"` 
11+ 	SourceID  int64  `json:"source_id"` 
12+ 	// identifier of the user, provided by the external authenticator (if configured) 
13+ 	// default: empty 
1214	LoginName  string  `json:"login_name"` 
15+ 	// username of the user 
1316	// required: true 
1417	Username  string  `json:"username" binding:"Required;Username;MaxSize(40)"` 
1518	FullName  string  `json:"full_name" binding:"MaxSize(100)"` 
@@ -32,6 +35,8 @@ type CreateUserOption struct {
3235type  EditUserOption  struct  {
3336	// required: true 
3437	SourceID  int64  `json:"source_id"` 
38+ 	// identifier of the user, provided by the external authenticator (if configured) 
39+ 	// default: empty 
3540	// required: true 
3641	LoginName  string  `json:"login_name" binding:"Required"` 
3742	// swagger:strfmt email 
Original file line number Diff line number Diff line change @@ -71,7 +71,8 @@ type PayloadUser struct {
7171	// Full name of the commit author 
7272	Name  string  `json:"name"` 
7373	// swagger:strfmt email 
74- 	Email     string  `json:"email"` 
74+ 	Email  string  `json:"email"` 
75+ 	// username of the user 
7576	UserName  string  `json:"username"` 
7677}
7778
Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ type AddTimeOption struct {
1414	Time  int64  `json:"time" binding:"Required"` 
1515	// swagger:strfmt date-time 
1616	Created  time.Time  `json:"created"` 
17- 	// User  who spent the time (optional) 
17+ 	// username of the user  who spent the time working on the issue  (optional) 
1818	User  string  `json:"user_name"` 
1919}
2020
@@ -26,7 +26,8 @@ type TrackedTime struct {
2626	// Time in seconds 
2727	Time  int64  `json:"time"` 
2828	// deprecated (only for backwards compatibility) 
29- 	UserID    int64   `json:"user_id"` 
29+ 	UserID  int64  `json:"user_id"` 
30+ 	// username of the user 
3031	UserName  string  `json:"user_name"` 
3132	// deprecated (only for backwards compatibility) 
3233	IssueID  int64   `json:"issue_id"` 
Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ type Organization struct {
1515	Location                   string  `json:"location"` 
1616	Visibility                 string  `json:"visibility"` 
1717	RepoAdminChangeTeamAccess  bool    `json:"repo_admin_change_team_access"` 
18+ 	// username of the organization 
1819	// deprecated 
1920	UserName  string  `json:"username"` 
2021}
@@ -30,6 +31,7 @@ type OrganizationPermissions struct {
3031
3132// CreateOrgOption options for creating an organization 
3233type  CreateOrgOption  struct  {
34+ 	// username of the organization 
3335	// required: true 
3436	UserName     string  `json:"username" binding:"Required;Username;MaxSize(40)"` 
3537	FullName     string  `json:"full_name" binding:"MaxSize(100)"` 
Original file line number Diff line number Diff line change @@ -15,9 +15,9 @@ import (
1515type  User  struct  {
1616	// the user's id 
1717	ID  int64  `json:"id"` 
18- 	// the user's  username 
18+ 	// login of  the user, same as ` username`  
1919	UserName  string  `json:"login"` 
20- 	// the user's authentication sign-in name.  
20+ 	// identifier of  the user, provided by the external authenticator (if configured)  
2121	// default: empty 
2222	LoginName  string  `json:"login_name"` 
2323	// The ID of the user's Authentication Source 
Original file line number Diff line number Diff line change @@ -11,6 +11,7 @@ type Email struct {
1111	Verified  bool    `json:"verified"` 
1212	Primary   bool    `json:"primary"` 
1313	UserID    int64   `json:"user_id"` 
14+ 	// username of the user 
1415	UserName  string  `json:"username"` 
1516}
1617
Original file line number Diff line number Diff line change @@ -123,7 +123,7 @@ func ListPublicMembers(ctx *context.APIContext) {
123123// IsMember check if a user is a member of an organization 
124124func  IsMember (ctx  * context.APIContext ) {
125125	// swagger:operation GET /orgs/{org}/members/{username} organization orgIsMember 
126- 	// ---    
126+ 	// --- 
127127	// summary: Check if a user is a member of an organization 
128128	// parameters: 
129129	// - name: org 
    
 
   
 
     
   
   
          
     
  
    
     
 
    
      
     
 
     
    You can’t perform that action at this time.
  
 
    
  
     
    
      
        
     
 
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments