Skip to content

Commit

Permalink
✨ Added the JQL service on the API implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
ctreminiom committed Oct 28, 2022
1 parent 47e57ce commit 6462a5a
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
7 changes: 7 additions & 0 deletions jira/v2/api_client_impl.go
Original file line number Diff line number Diff line change
Expand Up @@ -333,6 +333,11 @@ func New(httpClient common.HttpClient, site string) (*Client, error) {
return nil, err
}

jql, err := internal.NewJQLService(client, "2")
if err != nil {
return nil, err
}

client.Permission = permission
client.MySelf = mySelf
client.Auth = internal.NewAuthenticationService(client)
Expand All @@ -347,6 +352,7 @@ func New(httpClient common.HttpClient, site string) (*Client, error) {
client.Task = task
client.User = user
client.Workflow = workflow
client.JQL = jql

return client, nil
}
Expand All @@ -368,6 +374,7 @@ type Client struct {
Server *internal.ServerService
User *internal.UserService
Workflow *internal.WorkflowService
JQL *internal.JQLService
}

func (c *Client) NewFormRequest(ctx context.Context, method, apiEndpoint, contentType string, payload io.Reader) (*http.Request, error) {
Expand Down
7 changes: 7 additions & 0 deletions jira/v3/api_client_impl.go
Original file line number Diff line number Diff line change
Expand Up @@ -333,6 +333,11 @@ func New(httpClient common.HttpClient, site string) (*Client, error) {
return nil, err
}

jql, err := internal.NewJQLService(client, "3")
if err != nil {
return nil, err
}

client.Permission = permission
client.MySelf = mySelf
client.Auth = internal.NewAuthenticationService(client)
Expand All @@ -347,6 +352,7 @@ func New(httpClient common.HttpClient, site string) (*Client, error) {
client.Server = server
client.User = user
client.Workflow = workflow
client.JQL = jql

return client, nil
}
Expand All @@ -368,6 +374,7 @@ type Client struct {
Server *internal.ServerService
User *internal.UserService
Workflow *internal.WorkflowService
JQL *internal.JQLService
}

func (c *Client) NewFormRequest(ctx context.Context, method, apiEndpoint, contentType string, payload io.Reader) (*http.Request, error) {
Expand Down

0 comments on commit 6462a5a

Please sign in to comment.