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

Merged
merged 4 commits into from
Dec 2, 2024

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.

@zawan-ila zawan-ila merged commit 2eb6717 into openedx:master Dec 2, 2024
14 checks passed
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