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

fix: add partner field to person documents #4497

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

zawan-ila
Copy link
Contributor

@zawan-ila zawan-ila commented Nov 28, 2024

PROD-4240

This PR adds the partner field to person documents. This fixes the issue of person objects not being returned in GET requests against search/all due to the filtering in CatalogDataFilterDataMixin

Comment on lines +32 to +34
def prepare_partner(self, obj):
return obj.partner.short_code if obj.partner else ''

Copy link
Contributor

Choose a reason for hiding this comment

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

should this not be added in common too?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We could but it wouldn't be as neat since some documents have "different" implementations for it.

Copy link
Contributor

Choose a reason for hiding this comment

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

If only course run has a different implementation, it makes sense to override it there. But if all others have the same pattern, it would be good to move this in common as you have done for field itself.

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