diff roundup/htmltemplate.py @ 676:bc46480e2a2b

Fixed serialisation problem... ...by moving the serialisation step out of the hyperdb.Class (get, set) into the hyperdb.Database. Also fixed htmltemplate after the showid changes I made yesterday. Unit tests for all of the above written.
author Richard Jones <richard@users.sourceforge.net>
date Wed, 03 Apr 2002 05:54:31 +0000
parents 604c84696461
children 9fe50036e8df
line wrap: on
line diff
--- a/roundup/htmltemplate.py	Wed Apr 03 05:53:03 2002 +0000
+++ b/roundup/htmltemplate.py	Wed Apr 03 05:54:31 2002 +0000
@@ -15,7 +15,7 @@
 # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE,
 # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
 # 
-# $Id: htmltemplate.py,v 1.85 2002-04-02 01:40:58 richard Exp $
+# $Id: htmltemplate.py,v 1.86 2002-04-03 05:54:31 richard Exp $
 
 __doc__ = """
 Template engine.
@@ -357,10 +357,11 @@
             linkvalue = cgi.escape(linkcl.get(value, k))
             if showid:
                 label = value
-		title = ' title="%s"'%linkvalue
-		# note ... this should be urllib.quote(linkcl.get(value, k))
+                title = ' title="%s"'%linkvalue
+                # note ... this should be urllib.quote(linkcl.get(value, k))
             else:
                 label = linkvalue
+                title = ''
             if is_download:
                 return '<a href="%s%s/%s"%s>%s</a>'%(linkname, value,
                     linkvalue, title, label)
@@ -376,9 +377,10 @@
                 if showid:
                     label = value
                     title = ' title="%s"'%linkvalue
-		    # note ... this should be urllib.quote(linkcl.get(value, k))
+                    # note ... this should be urllib.quote(linkcl.get(value, k))
                 else:
                     label = linkvalue
+                    title = ''
                 if is_download:
                     l.append('<a href="%s%s/%s"%s>%s</a>'%(linkname, value,
                         linkvalue, title, label))
@@ -1126,6 +1128,12 @@
 
 #
 # $Log: not supported by cvs2svn $
+# Revision 1.85  2002/04/02 01:40:58  richard
+#  . link() htmltemplate function now has a "showid" option for links and
+#    multilinks. When true, it only displays the linked node id as the anchor
+#    text. The link value is displayed as a tooltip using the title anchor
+#    attribute.
+#
 # Revision 1.84  2002/03/29 19:41:48  rochecompaan
 #  . Fixed display of mutlilink properties when using the template
 #    functions, menu and plain.

Roundup Issue Tracker: http://roundup-tracker.org/