diff options
author | zsloan | 2021-02-18 16:51:36 +0000 |
---|---|---|
committer | zsloan | 2021-02-18 16:51:36 +0000 |
commit | 7b722f044c13d2f73652798aef2cb3387b24a1a6 (patch) | |
tree | 20b161c075f40030def02148f4cb052d1d457a6c | |
parent | fccbed3de9cd74ca2895c12ba1254957cbcca3fd (diff) | |
download | genenetwork2-7b722f044c13d2f73652798aef2cb3387b24a1a6.tar.gz |
Fixed remaining issue with gen_menu query to also sort by CreateTime, change OrderList sort to put NULLs at bottom, and exclude datasets with public = 0
-rw-r--r-- | wqflask/wqflask/api/gen_menu.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/wqflask/wqflask/api/gen_menu.py b/wqflask/wqflask/api/gen_menu.py index e490054d..4ce19fdb 100644 --- a/wqflask/wqflask/api/gen_menu.py +++ b/wqflask/wqflask/api/gen_menu.py @@ -206,9 +206,10 @@ def build_datasets(species, group, type_name): "Species.Name = '{0}' AND Species.Id = " "InbredSet.SpeciesId AND InbredSet.Name = '{1}' " "AND ProbeSetFreeze.ProbeFreezeId = ProbeFreeze.Id " - "and Tissue.Name = '{2}' AND ProbeFreeze.TissueId = " + "AND Tissue.Name = '{2}' AND ProbeFreeze.TissueId = " "Tissue.Id and ProbeFreeze.InbredSetId = InbredSet.Id " - "ORDER BY ProbeSetFreeze.OrderList ").format(species, group, type_name)).fetchall() + "AND ProbeSetFreeze.public > 0 " + "ORDER BY -ProbeSetFreeze.OrderList DESC, ProbeSetFreeze.CreateTime DESC").format(species, group, type_name)).fetchall() datasets = [] for dataset_info in results: |