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

feat(mi): add owner_id to applets response (M2-6948) #1402

Merged
merged 4 commits into from
Jun 12, 2024

Conversation

ChaconC
Copy link
Contributor

@ChaconC ChaconC commented Jun 11, 2024

📝 Description

Adds owner_id to various applet responses

🔗 Jira Ticket M2-6948

🪤 Peer Testing

This PR is easier to test from the corresponding Web PR.
Alternatively, perform these requests and validate owner_id is included in the response:

  • /workspaces/{workspaceId}/applets/{appletId}
  • /applets
  • /applets/{appletId}

✏️ Notes

This PR should be tested with the corresponding Web App PR ChildMindInstitute/mindlogger-web-refactor#483

@rcmerlo
Copy link
Contributor

rcmerlo commented Jun 11, 2024

Why returning owner_id in /workspaces/{workspaceId}/applets and /workspaces/{workspaceId}/applets/{appletId} ? workspaceId and ownerId are the same so FE already have this value

@ChaconC
Copy link
Contributor Author

ChaconC commented Jun 11, 2024

Why returning owner_id in /workspaces/{workspaceId}/applets and /workspaces/{workspaceId}/applets/{appletId} ? workspaceId and ownerId are the same so FE already have this value

The value gets included from AppletService.get_full_applet in /workspaces/{workspaceId}/applets/{appletId}. Plus I figured we should maintain a fairly similar response from both endpoints.

I'll remove it from /search and /workspaces/{workspaceId}/applets to limit the scope of changes 👍

/workspace/applets/search and /workspace/{id}/applets
Copy link

➡️ Preview environment created: Click Me!

Copy link

❌ E2E tests failed

Copy link
Contributor

@sultanofcardio sultanofcardio left a comment

Choose a reason for hiding this comment

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

Looking good/functional so far. I just have a couple suggested changes

src/apps/applets/api/applets.py Show resolved Hide resolved
src/apps/applets/api/applets.py Show resolved Hide resolved
@ChaconC ChaconC requested a review from sultanofcardio June 12, 2024 15:00
@ChaconC ChaconC merged commit bee7306 into feature/multiinformant-metapod Jun 12, 2024
23 of 25 checks passed
@ChaconC ChaconC deleted the fix/M2-6948-takenow-ownerid branch June 12, 2024 16:30
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.

3 participants