import django_filters
from .models import Art


"""自定义过滤器"""
class ArtFilter(django_filters.rest_framework.FilterSet):

    oid = django_filters.CharField(max_length=50, verbose_name="用户id")
    types = django_filters.IntegerField(choices=((1, "游戏"), (2, "旅游"), (3, "唱歌"), (4, "其它")), default=1, verbose_name="类型")
    isdel = django_filters.IntegerField(choices=((1, "删除"),(0, "正常")), default=0, verbose_name="是否删除", null=True, blank=True)

    class Meta:
        model = Art
        fields = ['oid', 'types', 'isdel']

14c10a5b34b0d2e5553db64a9b37c89b74475278
<mask token>

<mask token>


class ArtFilter(django_filters.rest_framework.FilterSet):
    <mask token>
    <mask token>
    <mask token>


    class Meta:
        model = Art
        fields = ['oid', 'types', 'isdel']

<mask token>


class ArtFilter(django_filters.rest_framework.FilterSet):
    oid = django_filters.CharField(max_length=50, verbose_name='用户id')
    types = django_filters.IntegerField(choices=((1, '游戏'), (2, '旅游'), (3,
        '唱歌'), (4, '其它')), default=1, verbose_name='类型')
    isdel = django_filters.IntegerField(choices=((1, '删除'), (0, '正常')),
        default=0, verbose_name='是否删除', null=True, blank=True)


    class Meta:
        model = Art
        fields = ['oid', 'types', 'isdel']

import django_filters
from .models import Art
<mask token>


class ArtFilter(django_filters.rest_framework.FilterSet):
    oid = django_filters.CharField(max_length=50, verbose_name='用户id')
    types = django_filters.IntegerField(choices=((1, '游戏'), (2, '旅游'), (3,
        '唱歌'), (4, '其它')), default=1, verbose_name='类型')
    isdel = django_filters.IntegerField(choices=((1, '删除'), (0, '正常')),
        default=0, verbose_name='是否删除', null=True, blank=True)


    class Meta:
        model = Art
        fields = ['oid', 'types', 'isdel']

import django_filters
from .models import Art


"""自定义过滤器"""
class ArtFilter(django_filters.rest_framework.FilterSet):

    oid = django_filters.CharField(max_length=50, verbose_name="用户id")
    types = django_filters.IntegerField(choices=((1, "游戏"), (2, "旅游"), (3, "唱歌"), (4, "其它")), default=1, verbose_name="类型")
    isdel = django_filters.IntegerField(choices=((1, "删除"),(0, "正常")), default=0, verbose_name="是否删除", null=True, blank=True)

    class Meta:
        model = Art
        fields = ['oid', 'types', 'isdel']
