Skip to content

Commit

Permalink
order abstract - #233
Browse files Browse the repository at this point in the history
  • Loading branch information
eliselavy committed Jul 18, 2024
1 parent a5a113a commit bd4206e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion jdhapi/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ def get_form(self, request, obj=None, **kwargs):
form = super().get_form(request, obj, **kwargs)
if obj is None:
# Limit abstract choices when creating new article instance
form.base_fields['abstract'].queryset = Abstract.objects.filter(article__isnull=True)
form.base_fields['abstract'].queryset = Abstract.objects.filter(article__isnull=True).order_by('title')
return form

def issue_name(self, obj):
Expand Down

0 comments on commit bd4206e

Please sign in to comment.