From: richard Date: Thu, 10 Oct 2002 08:04:26 +0000 (+0000) Subject: display _some_ text even when the link isn't interesting X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=6feed87712949831120378a149405951396a2653;p=roundup.git display _some_ text even when the link isn't interesting git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/trunk@1336 57a73879-2fb5-44c3-a270-3262357dd7e2 --- diff --git a/roundup/cgi/templating.py b/roundup/cgi/templating.py index cfe998e..89e3eee 100644 --- a/roundup/cgi/templating.py +++ b/roundup/cgi/templating.py @@ -566,7 +566,8 @@ class HTMLItem(HTMLPermissions): # TODO: test for node existence even when # there's no labelprop! try: - if labelprop is not None: + if labelprop is not None and \ + labelprop != 'id': label = linkcl.get(linkid, labelprop) except IndexError: comments['no_link'] = _('''The @@ -577,6 +578,8 @@ class HTMLItem(HTMLPermissions): if hrefable: subml.append('%s'%( classname, linkid, label)) + else: + subml.append(label) ml.append(sublabel + ', '.join(subml)) cell.append('%s:\n %s'%(k, ', '.join(ml))) elif isinstance(prop, hyperdb.Link) and args[k]: @@ -584,7 +587,7 @@ class HTMLItem(HTMLPermissions): # if we have a label property, try to use it # TODO: test for node existence even when # there's no labelprop! - if labelprop is not None: + if labelprop is not None and labelprop != 'id': try: label = linkcl.get(args[k], labelprop) except IndexError: