now with utc unix timestamp #4

Manually merged
tux merged 2 commits from timestamp into master 2020-03-14 13:12:39 +01:00
Showing only changes of commit b23b5abe15 - Show all commits

View file

@ -4,6 +4,7 @@
import npyscreen
import json
from datetime import date
import time
from sys import argv
@ -75,6 +76,8 @@ def main(*_args):
new_data['stammdaten'] = dict(zip(app.sd2.keys(), map(lambda f: f.value, app.sd2.values())))
new_data['finanzdaten'] = dict(zip(app.fin2.keys(), map(lambda f: f.value, app.fin2.values())))
new_data['mitgliederdaten'] = dict(zip(app.mem2.keys(), map(lambda f: f.value, app.mem2.values())))
new_data['timestamp'] = f"{int(time.time())}"
outfile_name = '{}_{}.json'.format(date.today().isoformat(), '_'.join(new_data['stammdaten']['fullname'].split()))
with open(outfile_name, 'w') as outfile:
json.dump(new_data, outfile, sort_keys=True, indent=4)