from django.contrib import admin

from import_export.admin import ImportExportMixin

from .models import Book, Category, Author


class BookAdmin(ImportExportMixin, admin.ModelAdmin):
    pass


admin.site.register(Book, BookAdmin)
admin.site.register(Category)
admin.site.register(Author)

from django.contrib import admin

from import_export.admin import ImportExportMixin

from .models import Book, Category, Author


class BookAdmin(ImportExportMixin, admin.ModelAdmin):
    list_filter = ['categories', 'author']


admin.site.register(Book, BookAdmin)
admin.site.register(Category)
admin.site.register(Author)

Add BookAdmin options in test app
Add BookAdmin options in test app

  from django.contrib import admin
  
  from import_export.admin import ImportExportMixin
  
  from .models import Book, Category, Author
  
  
  class BookAdmin(ImportExportMixin, admin.ModelAdmin):
-     pass
+     list_filter = ['categories', 'author']
  
  
  admin.site.register(Book, BookAdmin)
  admin.site.register(Category)
  admin.site.register(Author)
  
Add BookAdmin options in test app
## Code Before:
from django.contrib import admin

from import_export.admin import ImportExportMixin

from .models import Book, Category, Author


class BookAdmin(ImportExportMixin, admin.ModelAdmin):
    pass


admin.site.register(Book, BookAdmin)
admin.site.register(Category)
admin.site.register(Author)

## Instruction:
Add BookAdmin options in test app
## Code After:
from django.contrib import admin

from import_export.admin import ImportExportMixin

from .models import Book, Category, Author


class BookAdmin(ImportExportMixin, admin.ModelAdmin):
    list_filter = ['categories', 'author']


admin.site.register(Book, BookAdmin)
admin.site.register(Category)
admin.site.register(Author)
