|
15 | 15 | # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, |
16 | 16 | # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. |
17 | 17 | # |
18 | | -# $Id: htmltemplate.py,v 1.80 2002-02-21 07:19:08 richard Exp $ |
| 18 | +# $Id: htmltemplate.py,v 1.81 2002-02-21 07:21:38 richard Exp $ |
19 | 19 |
|
20 | 20 | __doc__ = """ |
21 | 21 | Template engine. |
@@ -655,8 +655,17 @@ def do_submit(self): |
655 | 655 | else: |
656 | 656 | return _('[Submit: not called from item]') |
657 | 657 |
|
658 | | - def do_classhelp(self, classname, properties): |
| 658 | + def do_classhelp(self, classname, properties, label='?', width='400', |
| 659 | + height='400'): |
659 | 660 | '''pop up a javascript window with class help |
| 661 | +
|
| 662 | + This generates a link to a popup window which displays the |
| 663 | + properties indicated by "properties" of the class named by |
| 664 | + "classname". The "properties" should be a comma-separated list |
| 665 | + (eg. 'id,name,description'). |
| 666 | +
|
| 667 | + You may optionally override the label displayed, the width and |
| 668 | + height. The popup window will be resizable and scrollable. |
660 | 669 | ''' |
661 | 670 | return '<a href="javascript:help_window(\'classhelp?classname=%s&' \ |
662 | 671 | 'properties=%s\', \'%s\', \'%s\')"><b>(%s)</b></a>'%(classname, |
@@ -1082,6 +1091,9 @@ def render(self, form): |
1082 | 1091 |
|
1083 | 1092 | # |
1084 | 1093 | # $Log: not supported by cvs2svn $ |
| 1094 | +# Revision 1.80 2002/02/21 07:19:08 richard |
| 1095 | +# ... and label, width and height control for extra flavour! |
| 1096 | +# |
1085 | 1097 | # Revision 1.79 2002/02/21 06:57:38 richard |
1086 | 1098 | # . Added popup help for classes using the classhelp html template function. |
1087 | 1099 | # - add <display call="classhelp('priority', 'id,name,description')"> |
|
0 commit comments