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

Added pretix newsletter CSV import #563

Open
wants to merge 7 commits into
base: main
Choose a base branch
from
Open

Added pretix newsletter CSV import #563

wants to merge 7 commits into from

Conversation

gpkvt
Copy link
Contributor

@gpkvt gpkvt commented Sep 9, 2024

No description provided.

@gpkvt gpkvt requested a review from pajowu September 9, 2024 08:48
}
elif "first_name" in headers and "last_name" in headers:
csv_format = {
"name": "combine",
Copy link
Member

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))

Copy link
Member

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

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

Successfully merging this pull request may close these issues.

3 participants