Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🎨 Added the issue worklog structs on the IssueScheme(v2/v3). #199

Merged
merged 1 commit into from
May 17, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
55 changes: 28 additions & 27 deletions pkg/infra/models/jira_issue_v2.go
Original file line number Diff line number Diff line change
Expand Up @@ -85,33 +85,34 @@ func (i *IssueSchemeV2) ToMap() (map[string]interface{}, error) {
}

type IssueFieldsSchemeV2 struct {
Parent *ParentScheme `json:"parent,omitempty"`
IssueType *IssueTypeScheme `json:"issuetype,omitempty"`
IssueLinks []*IssueLinkScheme `json:"issuelinks,omitempty"`
Watcher *IssueWatcherScheme `json:"watches,omitempty"`
Votes *IssueVoteScheme `json:"votes,omitempty"`
Versions []*VersionScheme `json:"versions,omitempty"`
Project *ProjectScheme `json:"project,omitempty"`
FixVersions []*VersionScheme `json:"fixVersions,omitempty"`
Priority *PriorityScheme `json:"priority,omitempty"`
Components []*ComponentScheme `json:"components,omitempty"`
Creator *UserScheme `json:"creator,omitempty"`
Reporter *UserScheme `json:"reporter,omitempty"`
Assignee *UserScheme `json:"assignee,omitempty"`
Resolution *ResolutionScheme `json:"resolution,omitempty"`
Resolutiondate string `json:"resolutiondate,omitempty"`
Workratio int `json:"workratio,omitempty"`
StatusCategoryChangeDate string `json:"statuscategorychangedate,omitempty"`
LastViewed string `json:"lastViewed,omitempty"`
Summary string `json:"summary,omitempty"`
Created string `json:"created,omitempty"`
Updated string `json:"updated,omitempty"`
Labels []string `json:"labels,omitempty"`
Status *StatusScheme `json:"status,omitempty"`
Description string `json:"description,omitempty"`
Comment *IssueCommentPageSchemeV2 `json:"comment,omitempty"`
Subtasks []*IssueScheme `json:"subtasks,omitempty"`
Security *SecurityScheme `json:"security,omitempty"`
Parent *ParentScheme `json:"parent,omitempty"`
IssueType *IssueTypeScheme `json:"issuetype,omitempty"`
IssueLinks []*IssueLinkScheme `json:"issuelinks,omitempty"`
Watcher *IssueWatcherScheme `json:"watches,omitempty"`
Votes *IssueVoteScheme `json:"votes,omitempty"`
Versions []*VersionScheme `json:"versions,omitempty"`
Project *ProjectScheme `json:"project,omitempty"`
FixVersions []*VersionScheme `json:"fixVersions,omitempty"`
Priority *PriorityScheme `json:"priority,omitempty"`
Components []*ComponentScheme `json:"components,omitempty"`
Creator *UserScheme `json:"creator,omitempty"`
Reporter *UserScheme `json:"reporter,omitempty"`
Assignee *UserScheme `json:"assignee,omitempty"`
Resolution *ResolutionScheme `json:"resolution,omitempty"`
Resolutiondate string `json:"resolutiondate,omitempty"`
Workratio int `json:"workratio,omitempty"`
StatusCategoryChangeDate string `json:"statuscategorychangedate,omitempty"`
LastViewed string `json:"lastViewed,omitempty"`
Summary string `json:"summary,omitempty"`
Created string `json:"created,omitempty"`
Updated string `json:"updated,omitempty"`
Labels []string `json:"labels,omitempty"`
Status *StatusScheme `json:"status,omitempty"`
Description string `json:"description,omitempty"`
Comment *IssueCommentPageSchemeV2 `json:"comment,omitempty"`
Subtasks []*IssueScheme `json:"subtasks,omitempty"`
Security *SecurityScheme `json:"security,omitempty"`
Worklog *IssueWorklogRichTextPageScheme `json:"worklog,omitempty"`
}

type ParentScheme struct {
Expand Down
57 changes: 29 additions & 28 deletions pkg/infra/models/jira_issue_v3.go
Original file line number Diff line number Diff line change
Expand Up @@ -85,34 +85,35 @@ func (i *IssueScheme) ToMap() (map[string]interface{}, error) {
}

type IssueFieldsScheme struct {
Parent *ParentScheme `json:"parent,omitempty"`
IssueType *IssueTypeScheme `json:"issuetype,omitempty"`
IssueLinks []*IssueLinkScheme `json:"issuelinks,omitempty"`
Watcher *IssueWatcherScheme `json:"watches,omitempty"`
Votes *IssueVoteScheme `json:"votes,omitempty"`
Versions []*VersionScheme `json:"versions,omitempty"`
Project *ProjectScheme `json:"project,omitempty"`
FixVersions []*VersionScheme `json:"fixVersions,omitempty"`
Priority *PriorityScheme `json:"priority,omitempty"`
Components []*ComponentScheme `json:"components,omitempty"`
Creator *UserScheme `json:"creator,omitempty"`
Reporter *UserScheme `json:"reporter,omitempty"`
Assignee *UserScheme `json:"assignee,omitempty"`
Resolution *ResolutionScheme `json:"resolution,omitempty"`
Resolutiondate string `json:"resolutiondate,omitempty"`
Workratio int `json:"workratio,omitempty"`
StatusCategoryChangeDate string `json:"statuscategorychangedate,omitempty"`
LastViewed string `json:"lastViewed,omitempty"`
Summary string `json:"summary,omitempty"`
Created string `json:"created,omitempty"`
Updated string `json:"updated,omitempty"`
Labels []string `json:"labels,omitempty"`
Status *StatusScheme `json:"status,omitempty"`
Description *CommentNodeScheme `json:"description,omitempty"`
Comment *IssueCommentPageScheme `json:"comment,omitempty"`
Subtasks []*IssueScheme `json:"subtasks,omitempty"`
Security *SecurityScheme `json:"security,omitempty"`
Attachment []*AttachmentScheme `json:"attachment,omitempty"`
Parent *ParentScheme `json:"parent,omitempty"`
IssueType *IssueTypeScheme `json:"issuetype,omitempty"`
IssueLinks []*IssueLinkScheme `json:"issuelinks,omitempty"`
Watcher *IssueWatcherScheme `json:"watches,omitempty"`
Votes *IssueVoteScheme `json:"votes,omitempty"`
Versions []*VersionScheme `json:"versions,omitempty"`
Project *ProjectScheme `json:"project,omitempty"`
FixVersions []*VersionScheme `json:"fixVersions,omitempty"`
Priority *PriorityScheme `json:"priority,omitempty"`
Components []*ComponentScheme `json:"components,omitempty"`
Creator *UserScheme `json:"creator,omitempty"`
Reporter *UserScheme `json:"reporter,omitempty"`
Assignee *UserScheme `json:"assignee,omitempty"`
Resolution *ResolutionScheme `json:"resolution,omitempty"`
Resolutiondate string `json:"resolutiondate,omitempty"`
Workratio int `json:"workratio,omitempty"`
StatusCategoryChangeDate string `json:"statuscategorychangedate,omitempty"`
LastViewed string `json:"lastViewed,omitempty"`
Summary string `json:"summary,omitempty"`
Created string `json:"created,omitempty"`
Updated string `json:"updated,omitempty"`
Labels []string `json:"labels,omitempty"`
Status *StatusScheme `json:"status,omitempty"`
Description *CommentNodeScheme `json:"description,omitempty"`
Comment *IssueCommentPageScheme `json:"comment,omitempty"`
Subtasks []*IssueScheme `json:"subtasks,omitempty"`
Security *SecurityScheme `json:"security,omitempty"`
Attachment []*AttachmentScheme `json:"attachment,omitempty"`
Worklog *IssueWorklogADFPageScheme `json:"worklog,omitempty"`
}

type IssueTransitionScheme struct {
Expand Down