gitea_hat/modules/structs/pull.go

42 lines
2.0 KiB
Go

package structs
import (
"time"
gitea_api "code.gitea.io/gitea/modules/structs"
)
type PullRequest struct {
ID int64 `json:"id"`
URL string `json:"url"`
Index int64 `json:"number"`
Poster *gitea_api.User `json:"user"`
Title string `json:"title"`
Body string `json:"body"`
Labels []*gitea_api.Label `json:"labels"`
Milestone *gitea_api.Milestone `json:"milestone"`
Assignee *gitea_api.User `json:"assignee"`
Assignees []*gitea_api.User `json:"assignees"`
State gitea_api.StateType `json:"state"`
IsLocked bool `json:"is_locked"`
Comments int `json:"comments"`
HTMLURL string `json:"html_url"`
DiffURL string `json:"diff_url"`
PatchURL string `json:"patch_url"`
Mergeable bool `json:"mergeable"`
HasMerged bool `json:"merged"`
Merged *time.Time `json:"merged_at"`
MergedCommitID *string `json:"merge_commit_sha"`
MergedBy *gitea_api.User `json:"merged_by"`
AllowMaintainerEdit bool `json:"allow_maintainer_edit"`
Base *gitea_api.PRBranchInfo `json:"base"`
Head *gitea_api.PRBranchInfo `json:"head"`
MergeBase string `json:"merge_base"`
Deadline *time.Time `json:"due_date"`
Created *time.Time `json:"created_at"`
Updated *time.Time `json:"updated_at"`
Closed *time.Time `json:"closed_at"`
CommitNum int `json:"commit_num"`
ChangedFiles int `json:"changed_files"`
}