feat: 其他生产记录增加查询handle_date
This commit is contained in:
parent
85a49c4b0f
commit
0f2d2dbee9
|
@ -382,6 +382,9 @@ class OtherLogViewSet(CustomModelViewSet):
|
||||||
"""
|
"""
|
||||||
queryset = OtherLog.objects.all()
|
queryset = OtherLog.objects.all()
|
||||||
serializer_class = OtherLogSerializer
|
serializer_class = OtherLogSerializer
|
||||||
filterset_fields = ['product']
|
filterset_fields = {
|
||||||
|
"product": ["exact"],
|
||||||
|
"handle_date": ["exact", "gte", "lte"]
|
||||||
|
}
|
||||||
search_fields = ['product']
|
search_fields = ['product']
|
||||||
ordering = ['-handle_date', '-create_time']
|
ordering = ['-handle_date', '-create_time']
|
||||||
|
|
Loading…
Reference in New Issue