diff --git a/app/corpora/views.py b/app/corpora/views.py index a6670d62..4c1da169 100644 --- a/app/corpora/views.py +++ b/app/corpora/views.py @@ -106,7 +106,10 @@ def add_corpus_file(corpus_id): or field.id == "csrf_token" or field.id == "file")] field_dict = dict(zip(ids, data)) - corpus_file = CorpusFile(**field_dict, corpus=corpus, dir=dir, filename=filename) + corpus_file = CorpusFile(**field_dict, + corpus=corpus, + dir=dir, + filename=filename) db.session.add(corpus_file) db.session.commit() thread = Thread(target=edit_corpus_file_, @@ -165,8 +168,6 @@ def edit_corpus_file(corpus_id, corpus_file_id): if edit_corpus_file_form.validate_on_submit(): corpus_file.author = edit_corpus_file_form.author.data corpus_file.publishing_year = edit_corpus_file_form.publishing_year.data - corpus_file.title = edit_corpus_file_form.title.data - corpus_file.pages = edit_corpus_file_form.pages.data db.session.commit() thread = Thread(target=edit_corpus_file_, args=(current_app._get_current_object(), diff --git a/app/templates/_formhelpers.html.j2 b/app/templates/_formhelpers.html.j2 index 37d4f381..d3aa5c19 100644 --- a/app/templates/_formhelpers.html.j2 +++ b/app/templates/_formhelpers.html.j2 @@ -2,7 +2,7 @@