aboutsummaryrefslogtreecommitdiff
path: root/wqflask
diff options
context:
space:
mode:
authorzsloan2021-05-04 19:35:31 +0000
committerzsloan2021-06-18 19:31:27 +0000
commit16338316a7529265aaa94d541698c8ed8cc97aba (patch)
tree3de552ff444b2677cd646533f8c6af7653ab1467 /wqflask
parent304128b1231df425709fbe3b128bd0c5eda4139b (diff)
downloadgenenetwork2-16338316a7529265aaa94d541698c8ed8cc97aba.tar.gz
Include table/table_id as parameters in setUseerColumnsDefWidths and saveColumnSettings
Diffstat (limited to 'wqflask')
-rw-r--r--wqflask/wqflask/templates/search_result_page.html12
1 files changed, 6 insertions, 6 deletions
diff --git a/wqflask/wqflask/templates/search_result_page.html b/wqflask/wqflask/templates/search_result_page.html
index adc8c264..a351256b 100644
--- a/wqflask/wqflask/templates/search_result_page.html
+++ b/wqflask/wqflask/templates/search_result_page.html
@@ -424,7 +424,7 @@
function loadDataTable(first_run=false){
if (!first_run){
- setUserColumnsDefWidths();
+ setUserColumnsDefWidths(tableId);
}
//ZS: Need to make sort by symbol, also need to make sure blank symbol fields at the bottom and symbols starting with numbers below letters
@@ -508,7 +508,7 @@
width_change = ui.size.width - ui.originalSize.width;
},
stop: function () {
- saveColumnSettings();
+ saveColumnSettings(tableId, trait_table);
loadDataTable();
}
});
@@ -541,11 +541,11 @@
trait_table.columns.adjust();
});
- function setUserColumnsDefWidths() {
+ function setUserColumnsDefWidths(table_id) {
var userColumnDef;
// Get the settings for this table from localStorage
- var userColumnDefs = JSON.parse(localStorage.getItem(tableId)) || [];
+ var userColumnDefs = JSON.parse(localStorage.getItem(table_id)) || [];
if (userColumnDefs.length === 0 ) return;
@@ -575,8 +575,8 @@
});
}
- function saveColumnSettings() {
- var userColumnDefs = JSON.parse(localStorage.getItem(tableId)) || [];
+ function saveColumnSettings(table_id, trait_table) {
+ var userColumnDefs = JSON.parse(localStorage.getItem(table_id)) || [];
var width, header, existingSetting;