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

Add GET path for finding relationships of a node #33

Closed
aadarsh-ram opened this issue Jul 30, 2022 · 2 comments · Fixed by #35
Closed

Add GET path for finding relationships of a node #33

aadarsh-ram opened this issue Jul 30, 2022 · 2 comments · Fixed by #35
Labels
✨ enhancement New feature or request fastapi

Comments

@aadarsh-ram
Copy link
Collaborator

There is no path for finding relationships (mainly is_child_of relationship) for any node. This must be added to compute the immediate parents and children of a particular node. (Will be helpful for the frontend)

@alexgarel
Copy link
Member

You can either do it with an API or add it to the /entry API ? (maybe with a additional_fields=parents) ?

@aadarsh-ram
Copy link
Collaborator Author

You can either do it with an API or add it to the /entry API ? (maybe with a additional_fields=parents) ?

@alexgarel I think having an additional fields property would make the code a little messy on the "database functions" (entries.py) side, with a lot of conditions. It seemed cleaner to make two different paths /entry/{entry}/parents and /entry/{entry}/children instead.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
✨ enhancement New feature or request fastapi
Projects
No open projects
Development

Successfully merging a pull request may close this issue.

2 participants