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

Update request for project related resources; Cleanup to match back-end #408

Merged
merged 6 commits into from
Nov 8, 2023

Conversation

jeffdaley
Copy link
Contributor

@jeffdaley jeffdaley commented Nov 7, 2023

  • Updates the Project requests to grab the related resources separately.
  • Renames stuff to align with the back end
  • Cleanup and note-to-self

Comment on lines -519 to -536
/**
* Used by the /projects route to fetch a list of projects.
*/
this.get("/projects", () => {
const projects = this.schema.projects.all().models;
return new Response(200, {}, projects);
});

/**
* Used by the /projects/:project_id route to fetch a single project.
*/
this.get("/projects/:project_id", (schema, request) => {
const project = schema.projects.findBy({
id: request.params.project_id,
});
return new Response(200, {}, project.attrs);
});

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These were duplicates. Probably a merge error.

@jeffdaley jeffdaley changed the title Jeffdaley/update projects interface Update request for project related resources; Cleanup to match back-end Nov 7, 2023
@jeffdaley jeffdaley marked this pull request as ready for review November 7, 2023 22:23
@jeffdaley jeffdaley requested a review from a team as a code owner November 7, 2023 22:23
@jeffdaley jeffdaley mentioned this pull request Nov 7, 2023
Comment on lines +23 to +24
jiraIssueID?: string;
jiraIssue?: JiraIssue;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is jiraIssueID supposed to represent the internal Jira ID (if so, curious how we use that)? Can we put that as part of a JiraIssue? Note/caveat: I haven't dove into the Jira part of the backend work yet so I'm cool with this changing as we start to incorporate that.

Copy link
Contributor Author

@jeffdaley jeffdaley Nov 8, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I interpreted JiraIssueID to be an external reference, like "LABS-123" (as in test-org.atlassian.com/issues/LABS-123 that would be used to query the Jira API for the full JiraIssue object.

@jeffdaley jeffdaley merged commit 3eda168 into main Nov 8, 2023
1 check passed
@jeffdaley jeffdaley deleted the jeffdaley/update-projects-interface branch November 8, 2023 01:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants