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

Customize child links #1159

Closed
m-mohr opened this issue Jun 14, 2023 · 2 comments · Fixed by #1160
Closed

Customize child links #1159

m-mohr opened this issue Jun 14, 2023 · 2 comments · Fixed by #1160
Milestone

Comments

@m-mohr
Copy link
Contributor

m-mohr commented Jun 14, 2023

If I add a child link to a catalog, there's no easy way to customize it (i.e. add an additional property). The created Link object is completely hidden from the users and getting it via a get_child_links or similar fundtions is cumbersome.

I could imagine two ways:

  1. Add an extra_fields parameter to add_child
  2. Return the created link object (instead of None) so that we can add more fields to the link

Thoughts? Happy to create a PR, but would like to get some thoughts from the maintainers first.

@gadomski
Copy link
Member

Return the created link object (instead of None) so that we can add more fields to the link

This feels the most intuitive to me.

@m-mohr
Copy link
Contributor Author

m-mohr commented Jun 14, 2023

Thanks, I'll create a PR that applies this behavior.

@gadomski gadomski linked a pull request Jun 14, 2023 that will close this issue
5 tasks
@gadomski gadomski added this to the 1.8 milestone Jun 14, 2023
gadomski pushed a commit that referenced this issue Jun 15, 2023
* Return Link Object after adding a child or item #1159

* Return List of Links from add_childen and add_items #1159
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants