# coding=utf-8
import django_filters
from .models import Commodity

class CommodityFilter(django_filters.FilterSet):
    name = django_filters.CharFilter(field_name='name', lookup_expr='icontains')
    category_id = django_filters.CharFilter(field_name='category_id')

    class Meta:
        model = Commodity
        fields = '__all__'
