From c281820ea0ccb8c078c83deca128010b3df95dce Mon Sep 17 00:00:00 2001 From: Frederick Muriuki Muriithi Date: Fri, 21 Mar 2025 13:18:37 -0500 Subject: Rename endpoint: Distinguish edit download from other downloads. --- uploader/phenotypes/views.py | 5 +++-- uploader/templates/phenotypes/view-dataset.html | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) (limited to 'uploader') diff --git a/uploader/phenotypes/views.py b/uploader/phenotypes/views.py index 407493c..2f6e926 100644 --- a/uploader/phenotypes/views.py +++ b/uploader/phenotypes/views.py @@ -866,16 +866,17 @@ def process_phenotype_data_for_download(pheno: dict) -> dict: } } + @phenotypesbp.route( "/populations//phenotypes/datasets" - "//download", + "//edit-download", methods=["POST"]) @require_login @with_dataset( species_redirect_uri="species.populations.phenotypes.index", population_redirect_uri="species.populations.phenotypes.select_population", redirect_uri="species.populations.phenotypes.list_datasets") -def download_phenotype_data(# pylint: disable=[unused-argument] +def edit_download_phenotype_data(# pylint: disable=[unused-argument] species: dict, population: dict, dataset: dict, diff --git a/uploader/templates/phenotypes/view-dataset.html b/uploader/templates/phenotypes/view-dataset.html index ed59d76..e08afc1 100644 --- a/uploader/templates/phenotypes/view-dataset.html +++ b/uploader/templates/phenotypes/view-dataset.html @@ -178,7 +178,7 @@ $.ajax( (`/species/${species_id}/populations/` + `${population_id}/phenotypes/datasets/` + - `${dataset_id}/download`), + `${dataset_id}/edit-download`), { method: "POST", data: JSON.stringify(phenoids), -- cgit v1.2.3