-
Notifications
You must be signed in to change notification settings - Fork 22
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
Added pretix newsletter CSV import #563
base: main
Are you sure you want to change the base?
Conversation
} | ||
elif "first_name" in headers and "last_name" in headers: | ||
csv_format = { | ||
"name": "combine", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not a fan of storing different things in name
: both a column name and a magic constant which implies that two columns should be combined. I suggest to instead return a list of fields here and checking in import_csv
whether a list was returned (isinstance(row['name'], list)
)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To simplify this could also always return a list for name
, which for the other cases only contains a single entry
No description provided.