Skip to content

Instantly share code, notes, and snippets.

@ashwoods
Created October 8, 2013 12:29
Show Gist options
  • Save ashwoods/6883938 to your computer and use it in GitHub Desktop.
Save ashwoods/6883938 to your computer and use it in GitHub Desktop.
tirolissimo export
for entry in award_entries:
try:
extra_data = entry.entrydata_set.get(slug='step1')
kunde = extra_data.answer.get('kunde')
agentur = extra_data.answer.get('agentur')
except:
kunde = None
agentur = None
entry_row = [
entry.code,
entry.status,
entry.price,
entry.modified,
entry.status_changed,
entry.category,
kunde,
agentur,
entry.title,
entry.user_id,
entry.user.user.first_name,
entry.user.user.last_name,
entry.user.user.email,
"\n".join([asset.name for asset in entry.entrysimpleasset_set.all()]),
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment