Skip to content

Commit e01792d

Browse files
authored
Merge pull request #392 from sparcs-kaist/feat/article-filter
Add board slug to article filter parameter
2 parents f331773 + 1280b5e commit e01792d

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

apps/core/filters/article.py

+6-1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@
55

66

77
class ArticleFilter(FilterSet):
8+
board = CharFilter(field_name="parent_board__slug", lookup_expr="exact")
9+
810
class Meta:
911
model = Article
1012
fields = {
@@ -45,7 +47,10 @@ class Meta:
4547
"in",
4648
"exact",
4749
],
48-
"communication_article__school_response_status": ["exact", "lt"],
50+
"communication_article__school_response_status": [
51+
"exact",
52+
"lt",
53+
],
4954
}
5055

5156
main_search__contains = CharFilter(

0 commit comments

Comments
 (0)