diff options
author | zsloan | 2020-09-25 14:52:40 -0500 |
---|---|---|
committer | zsloan | 2020-09-25 14:52:40 -0500 |
commit | 37500c0c36fbbb2b4ab291cf164b5397776357a7 (patch) | |
tree | bd986dd14dabbce56451096557487685828860cb | |
parent | 143c8e42e15ae1ed4b5a2353a64b3a4ba77bd337 (diff) | |
download | genenetwork2-37500c0c36fbbb2b4ab291cf164b5397776357a7.tar.gz |
Fixed issue where attribute columns' alignment was offset by 1
* wqflask/wqflask/static/new/javascript/initialize_show_trait_tables.js
- attribute cells' alignment and column names were wrong because they were referring to an attribute offset by 1 in the attribute list
-
-rw-r--r-- | wqflask/wqflask/static/new/javascript/initialize_show_trait_tables.js | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/wqflask/wqflask/static/new/javascript/initialize_show_trait_tables.js b/wqflask/wqflask/static/new/javascript/initialize_show_trait_tables.js index 53d5b3f7..71eae87f 100644 --- a/wqflask/wqflask/static/new/javascript/initialize_show_trait_tables.js +++ b/wqflask/wqflask/static/new/javascript/initialize_show_trait_tables.js @@ -147,8 +147,8 @@ var primary_table = $('#samples_primary').DataTable( { sorted_key_list = Object.keys(js_data.attributes).sort() for (i=0; i < sorted_key_list.length; i++) { - $('td', row).eq(attribute_start_pos + i).addClass("column_name-" + js_data.attributes[sorted_key_list[i]].name) - $('td', row).eq(attribute_start_pos + i).attr("style", "text-align: " + js_data.attributes[sorted_key_list[i]].alignment + "; padding-top: 2px; padding-bottom: 0px;") + $('td', row).eq(attribute_start_pos + i + 1).addClass("column_name-" + js_data.attributes[sorted_key_list[i]].name) + $('td', row).eq(attribute_start_pos + i + 1).attr("style", "text-align: " + js_data.attributes[sorted_key_list[i]].alignment + "; padding-top: 2px; padding-bottom: 0px;") } }, 'data': js_data['sample_lists'][0], @@ -205,8 +205,8 @@ if (js_data.sample_lists.length > 1){ sorted_key_list = Object.keys(js_data.attributes).sort() for (i=0; i < sorted_key_list.length; i++) { - $('td', row).eq(attribute_start_pos + i).addClass("column_name-" + js_data.attributes[sorted_key_list[i]].name) - $('td', row).eq(attribute_start_pos + i).attr("style", "text-align: " + js_data.attributes[sorted_key_list[i]].alignment + "; padding-top: 2px; padding-bottom: 0px;") + $('td', row).eq(attribute_start_pos + i + 1).addClass("column_name-" + js_data.attributes[sorted_key_list[i]].name) + $('td', row).eq(attribute_start_pos + i + 1).attr("style", "text-align: " + js_data.attributes[sorted_key_list[i]].alignment + "; padding-top: 2px; padding-bottom: 0px;") } }, 'data': js_data['sample_lists'][1], |