resources.py 390 B

12345678910111213141516171819
  1. from import_export import resources
  2. from .models import User
  3. class UserResource(resources.ModelResource):
  4. class Meta:
  5. model = User
  6. skip_unchanged = True
  7. fields = (
  8. "id",
  9. # "password",
  10. "is_superuser",
  11. "email",
  12. "name",
  13. "is_staff",
  14. "is_active",
  15. "created",
  16. )