From 9f76abc95859be4ce7b6b19d51b3b2844c04a197 Mon Sep 17 00:00:00 2001 From: zsloan Date: Tue, 8 Sep 2020 13:37:25 -0500 Subject: Changed regular and global search results table to use the new sort method that always places NAs at bottom, changed the Add to Collection button's color, and added something to the regular search page template to display alternative text if there are more than 50000 results * wqflask/wqflask/templates/gsearch_gene.html - Added natural-minus-na sort to certain columns and changed Add button color * wqflask/wqflask/templates/gsearch_pheno.html - Added natural-minus-na sort to certain columns and changed Add button color * wqflask/wqflask/templates/search_result_page.html - Added natural-minus-na sort to certain columns, changed Add button color, and added template logic that shows alternative text if there are more than 50,000 results --- wqflask/wqflask/templates/gsearch_gene.html | 14 ++++----- wqflask/wqflask/templates/gsearch_pheno.html | 14 ++++----- wqflask/wqflask/templates/search_result_page.html | 38 +++++++++++++---------- 3 files changed, 35 insertions(+), 31 deletions(-) (limited to 'wqflask') diff --git a/wqflask/wqflask/templates/gsearch_gene.html b/wqflask/wqflask/templates/gsearch_gene.html index acb3ee75..478d6f5f 100644 --- a/wqflask/wqflask/templates/gsearch_gene.html +++ b/wqflask/wqflask/templates/gsearch_gene.html @@ -20,7 +20,7 @@ - +
@@ -47,12 +47,12 @@ {% block js %} - + - + - @@ -163,6 +167,8 @@ + + @@ -218,9 +224,7 @@ } } - console.time("Creating table"); //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 - $('#trait_table').DataTable( { 'drawCallback': function( settings ) { $('#trait_table tr').click(function(event) { @@ -314,33 +318,33 @@ }, { 'title': "Location", - 'type': "natural", + 'type': "natural-minus-na", 'width': "120px", 'data': "location" }, { 'title': "Mean", - 'type': "natural", + 'type': "natural-minus-na", 'width': "40px", 'data': "mean", 'orderSequence': [ "desc", "asc"] }, { 'title': "Max LRS?", - 'type': "natural", + 'type': "natural-minus-na", 'data': "lrs_score", 'width': "80px", 'orderSequence': [ "desc", "asc"] }, { 'title': "Max LRS Location", - 'type': "natural", + 'type': "natural-minus-na", 'width': "150px", 'data': "lrs_location" }, { 'title': "Additive Effect?", - 'type': "natural", + 'type': "natural-minus-na", 'data': "additive", 'width': "120px", 'orderSequence': [ "desc", "asc"] @@ -360,7 +364,7 @@ }, { 'title': "Mean", - 'type': "natural", + 'type': "natural-minus-na", 'width': "110px", 'data': "mean", 'orderSequence': [ "desc", "asc"] @@ -387,7 +391,7 @@ }, { 'title': "Year", - 'type': "natural", + 'type': "natural-minus-na", 'orderDataType': "dom-inner-text", 'data': null, 'width': "80px", @@ -402,27 +406,27 @@ }, { 'title': "Max LRS?", - 'type': "natural", + 'type': "natural-minus-na", 'data': "lrs_score", 'width': "80px", 'orderSequence': [ "desc", "asc"] }, { 'title': "Max LRS Location", - 'type': "natural", + 'type': "natural-minus-na", 'width': "150px", 'data': "lrs_location" }, { 'title': "Additive Effect?", - 'type': "natural", + 'type': "natural-minus-na", 'width': "120px", 'data': "additive", 'orderSequence': [ "desc", "asc"] }{% elif dataset.type == 'Geno' %}, { 'title': "Location", - 'type': "natural", + 'type': "natural-minus-na", 'width': "140px", 'data': "location" }{% endif %} -- cgit v1.2.3