Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Default field set differs during import in v4 #1820

Closed
matthewhegarty opened this issue May 10, 2024 · 3 comments
Closed

Default field set differs during import in v4 #1820

matthewhegarty opened this issue May 10, 2024 · 3 comments

Comments

@matthewhegarty
Copy link
Contributor

Describe the bug

in v3, all model fields are presented during import:

image

In v4, only certain model fields are presented, even when no fields attribute is defined.

image

To Reproduce

Import the books.csv file using the Admin console.

Versions (please complete the following information):

  • Django Import Export: 4.0.1
  • Python 3.11
  • Django 5.0.2

Expected behavior

For consistency with v3, we should see all default fields presented.

@bmihelac
Copy link
Member

@matthewhegarty I could not reproduce this. You mention importing books.csv but screenshot looks like E-books import (it has author field). Without digging deeper, it seems fields that are presented are defined with Resource class and not import file headers.

@matthewhegarty
Copy link
Contributor Author

Ah good point - thanks for checking. I'll check again later and close if I cannot reproduce.

@matthewhegarty
Copy link
Contributor Author

Yes, it looks ok when importing a file to Book

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants