with open(csvpath, 'r') as csvfile:
csvreader = csv.DictReader(csvfile, delimiter=',', quotechar='"')
+ uni = "FAU Erlangen"
for row in csvreader:
if is_veranstaltungsleiter(row):
nick = "%s %s" % (VERANSTALTUNGSLEITER[row['username']][0], VERANSTALTUNGSLEITER[row['username']][1])
- uni = "Veranstaltungsleiter"
- else:
- nick = "%s" % (row['username'])
- uni = "FAU Erlangen"
+ with open(os.path.join(outdir, "%s.svg" % nick), 'w') as f:
+ f.write(template.render(nick=nick.decode('utf-8'), uni1=uni.decode('utf-8')).encode('utf-8'))
+ nick = "%s" % (row['username'])
with open(os.path.join(outdir, "%s.svg" % nick), 'w') as f:
- f.write(template.render(nick=nick.decode('utf-8'), uni=uni.decode('utf-8')).encode('utf-8'))
+ f.write(template.render(nick=nick.decode('utf-8'), uni1=uni.decode('utf-8')).encode('utf-8'))
def import_teilnehmer(input):