From d473276cf2be0282fb1650d4c5a913af4aebb9bd Mon Sep 17 00:00:00 2001 From: Sefa Kilic Date: Tue, 13 Sep 2016 22:21:10 -0700 Subject: [PATCH] make ECO terms visible --- src/core/models.py | 8 +++++--- src/static/collectf.css | 12 ++++++++++++ src/templates/browse/experimental_technique.html | 8 ++++++-- src/templates/browse/view_motif_reports.html | 2 +- 4 files changed, 24 insertions(+), 6 deletions(-) diff --git a/src/core/models.py b/src/core/models.py index ed2e2e6..37485cc 100644 --- a/src/core/models.py +++ b/src/core/models.py @@ -520,7 +520,7 @@ def extend_sequence(self, n=250): class Meta: verbose_name = "Site instance" - + class Curation_SiteInstance(models.Model): @@ -753,6 +753,10 @@ class Meta: verbose_name = "Experimental technique" ordering = ['name'] + def ECO_term_link(self): + """Returns the URL for the ECO term.""" + return "http://purl.obolibrary.org/obo/" + self.EO_term.replace(':', '_') + class ExperimentalTechniqueCategory(models.Model): """Experimental technique category table. @@ -906,5 +910,3 @@ def __unicode__(self): class Meta: verbose_name = "GO term" - - diff --git a/src/static/collectf.css b/src/static/collectf.css index 6f231bf..46d7c73 100644 --- a/src/static/collectf.css +++ b/src/static/collectf.css @@ -75,3 +75,15 @@ img { .label-blue { background-color: #2196F3; } + +table a:link { + text-decoration: none !important; +} + +table a:not(.btn) { + text-decoration: none !important; +} + +table a:hover { + text-decoration: underline !important; +} diff --git a/src/templates/browse/experimental_technique.html b/src/templates/browse/experimental_technique.html index bb2d087..0e3d808 100644 --- a/src/templates/browse/experimental_technique.html +++ b/src/templates/browse/experimental_technique.html @@ -6,8 +6,10 @@ {{ technique.name }} + {% if technique.EO_term %} + ({% with term=technique.EO_term %}{{ term }}{% endwith %}) + {% endif %} -