Skip to content

Commit

Permalink
fix: 问题列表,根据创建时间倒序
Browse files Browse the repository at this point in the history
  • Loading branch information
shaohuzhang1 committed Apr 8, 2024
1 parent 11e116b commit ddf7fdd
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions apps/dataset/serializers/problem_serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ def get_query_set(self):
**{'dataset_id': self.data.get('dataset_id')})
if 'content' in self.data:
query_set = query_set.filter(**{'content__contains': self.data.get('content')})
query_set = query_set.order_by("-create_time")
return query_set

def list(self):
Expand Down

0 comments on commit ddf7fdd

Please sign in to comment.