From 3b5355dec882a636b2e02e41333e9dbf0dce641a Mon Sep 17 00:00:00 2001 From: BonfaceKilz Date: Mon, 19 Oct 2020 16:24:56 +0300 Subject: Update snpString link * wqflask/wqflask/marker_regression/display_mapping_results.py: Replace "%" strings with f-strings. Also, replace old "Href" with new htmlgen "Link" method. --- .../wqflask/marker_regression/display_mapping_results.py | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/wqflask/wqflask/marker_regression/display_mapping_results.py b/wqflask/wqflask/marker_regression/display_mapping_results.py index 377f58b6..ca430e8d 100644 --- a/wqflask/wqflask/marker_regression/display_mapping_results.py +++ b/wqflask/wqflask/marker_regression/display_mapping_results.py @@ -2806,9 +2806,17 @@ class DisplayMappingResults(object): geneIdString = 'http://www.ncbi.nlm.nih.gov/entrez/query.fcgi?db=gene&cmd=Retrieve&dopt=Graphics&list_uids=%s' % theGO["GeneID"] if theGO["snpCount"]: - snpString = HT.Href(url="http://genenetwork.org/webqtl/main.py?FormID=snpBrowser&chr=%s&start=%s&end=%s&geneName=%s&s1=%d&s2=%d" % (theGO["Chromosome"], - theGO["TxStart"], theGO["TxEnd"], theGO["GeneSymbol"], self.diffCol[0], self.diffCol[1]), - text=theGO["snpCount"], target="_blank", Class="normalsize") + snpString = HT.Link( + (f"http://genenetwork.org/webqtl/main.py?FormID=snpBrowser&" + f"chr={theGO['Chromosome']}&" + f"start={theGO['TxStart']}&" + f"end={theGO['TxEnd']}&" + f"geneName={theGO['GeneSymbol']}&" + f"s1={self.diffCol[0]}&s2=%d"), + theGO["snpCount"] # The text to display + ) + snpString.set_blank_target() + snpString.set_attribute("class", "normalsize") else: snpString = 0 -- cgit v1.2.3