From 28c9447fb51fc764143b5add664e8f4b892a703d Mon Sep 17 00:00:00 2001
From: Frederick Muriuki Muriithi
Date: Mon, 10 Mar 2025 12:36:08 -0500
Subject: Update how the DataTables handlers are set up.
---
uploader/static/js/populations.js | 4 +++-
uploader/static/js/species.js | 3 ++-
uploader/templates/phenotypes/view-dataset.html | 2 ++
3 files changed, 7 insertions(+), 2 deletions(-)
(limited to 'uploader')
diff --git a/uploader/static/js/populations.js b/uploader/static/js/populations.js
index ded9b10..d4980db 100644
--- a/uploader/static/js/populations.js
+++ b/uploader/static/js/populations.js
@@ -18,7 +18,8 @@ var populationDataTable = (populationdata) => {
data: (apopulation) => {
return ``;
+ + `value="${apopulation.InbredSetId}" `
+ + `class="chk-row-select">`;
}
},
{
@@ -35,6 +36,7 @@ var populationDataTable = (populationdata) => {
$(() => {
+ dtAddCommonHandlers("#tbl-select-population");
populationDataTable(JSON.parse(
$("#tbl-select-population").attr("data-populations-list")));
});
diff --git a/uploader/static/js/species.js b/uploader/static/js/species.js
index b070725..0ab9c19 100644
--- a/uploader/static/js/species.js
+++ b/uploader/static/js/species.js
@@ -18,7 +18,7 @@ var speciesDataTable = (speciesdata) => {
data: (aspecies) => {
return ``;
+ + `value="${aspecies.SpeciesId}" class="chk-row-select">`;
}
},
{
@@ -34,6 +34,7 @@ var speciesDataTable = (speciesdata) => {
};
$(() => {
+ dtAddCommonHandlers("#tbl-select-species");
speciesDataTable(JSON.parse(
$("#tbl-select-species").attr("data-species-list")));
});
diff --git a/uploader/templates/phenotypes/view-dataset.html b/uploader/templates/phenotypes/view-dataset.html
index 86c16f7..103ab02 100644
--- a/uploader/templates/phenotypes/view-dataset.html
+++ b/uploader/templates/phenotypes/view-dataset.html
@@ -85,6 +85,8 @@
{%block javascript%}