diff options
Diffstat (limited to 'uploader/genotypes')
-rw-r--r-- | uploader/genotypes/views.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/uploader/genotypes/views.py b/uploader/genotypes/views.py index 7b5994e..9f08ca6 100644 --- a/uploader/genotypes/views.py +++ b/uploader/genotypes/views.py @@ -1,4 +1,5 @@ """Views for the genotypes.""" +from requests.models import Response from MySQLdb.cursors import DictCursor from flask import (flash, request, @@ -171,7 +172,7 @@ def create_dataset(species: dict, population: dict, **kwargs):# pylint: disable= activelink="create-dataset") form = request.form - _new_dataset = save_new_dataset( + new_dataset = save_new_dataset( cursor, population["Id"], form["geno-dataset-name"], @@ -179,7 +180,7 @@ def create_dataset(species: dict, population: dict, **kwargs):# pylint: disable= form["geno-dataset-shortname"]) def __success__(_success): - flash("Successfully created genotype dataset." "alert-success") + flash("Successfully created genotype dataset.", "alert-success") return redirect(url_for( "species.populations.genotypes.list_genotypes", species_id=species["SpeciesId"], @@ -206,6 +207,7 @@ def create_dataset(species: dict, population: dict, **kwargs):# pylint: disable= **dict(request.form), "species_id": species["SpeciesId"], "population_id": population["Id"], + "dataset_id": new_dataset["Id"], "dataset_name": form["geno-dataset-name"], "dataset_fullname": form["geno-dataset-fullname"], "dataset_shortname": form["geno-dataset-shortname"], |