Skip to content

Commit

Permalink
serialize brand info for preprint provider (#10410)
Browse files Browse the repository at this point in the history
  • Loading branch information
adlius authored Jul 13, 2023
1 parent 7dcf6fa commit 2b80663
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions api/providers/serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -237,6 +237,11 @@ class Meta:
related_view_kwargs={'provider_id': '<_id>'},
)

brand = RelationshipField(
related_view='brands:brand-detail',
related_view_kwargs={'brand_id': '<brand.id>'},
)

def get_preprints_url(self, obj):
return absolute_reverse(
'providers:preprint-providers:preprints-list', kwargs={
Expand Down

0 comments on commit 2b80663

Please sign in to comment.