Skip to content
Snippets Groups Projects
Commit 79c7f196 authored by root's avatar root
Browse files

shortend data

parent f74d0725
No related branches found
No related tags found
No related merge requests found
......@@ -12,9 +12,14 @@ def parseDay( dom, dayName ):
for tr in range(day.length()):
tds = day[tr].find("td");
gericht = tds[0].text()
#-zusatzstoffe
gericht = re.sub(r'\([\d+,]+\)', '', gericht)
gericht = re.sub(r'\bdazu \d Beilagen nach Wahl\b', '', gericht)
gericht = re.sub(r' ,', ',', gericht)
#+verkuerzung
gericht = re.sub(r' dazu \d Beilagen nach Wahl', '', gericht)
gericht = re.sub(r',\sdazu\s', ' + ', gericht)
gericht = re.sub(r'\sund\s', ' & ', gericht)
#eyecandy
gericht = re.sub(r'\s,', ',', gericht)
gericht = re.sub(r',\S', ', ', gericht)
gericht = re.sub(r'\s$', '', gericht)
gericht = re.sub(r',$', '', gericht)
......@@ -34,3 +39,6 @@ result = {
with io.open('mensaPlan.json', 'w', encoding='utf-8') as f:
f.write(unicode(json.dumps(result)))
#multimensa
#style
This diff is collapsed.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment