Roundup Tracker - Issues

Issue 2550822

classification
Class's menu() method additional= kwarg doesn't properly handle list
Type: behavior Severity: minor
Components: Web interface Versions: 1.5
process
Status: fixed fixed
:
: ThomasAH : ThomasAH, jmack
Priority: normal :

Created on 2013-11-12 20:33 by jmack, last changed 2013-11-13 10:17 by ThomasAH.

Files
File name Uploaded Description Edit Remove
templating.py jmack, 2013-11-12 20:33
Messages
msg4949 Author: [hidden] (jmack) Date: 2013-11-12 20:33
I had the following option in one of my templates:
tal:content="structure python:context.propname.menu(additional=
['propname1', 'propname2'])"

I expected this to display both propname1 and propname2 in the menu. It 
only displayed propname2.

I found some errors in roundup/cgi/templating.py and fixed them. A revised 
1.5.0 templating.py is attached. The changes are to the section "if 
additional:" in the LinkHTMLProperty.menu() method.
msg4950 Author: [hidden] (ThomasAH) Date: 2013-11-13 10:17
Thank you! I think I encountered this problem in the past, too.

I just pushed these changesets, the third one was needed due to code
duplication for links and multilinks.

changeset:   4846:3e36a3bc0335
user:        Thomas Arendsen Hein <thomas@intevation.de>
date:        Wed Nov 13 11:12:21 2013 +0100
files:       CHANGES.txt roundup/cgi/templating.py
description:
issue2550822: Fix showing more than one additional property in class menu

Report and patch provided by James Mack:
| I had the following option in one of my templates:
| tal:content="structure python:context.propname.menu(additional=
| ['propname1', 'propname2'])"
|
| I expected this to display both propname1 and propname2 in the menu. It
| only displayed propname2.


changeset:   4847:843886af0ea1
user:        Thomas Arendsen Hein <thomas@intevation.de>
date:        Wed Nov 13 11:12:55 2013 +0100
files:       roundup/cgi/templating.py
description:
Reformat previous change (3e36a3bc0335) to 80 chars


changeset:   4848:e8ae54db8b95
user:        Thomas Arendsen Hein <thomas@intevation.de>
date:        Wed Nov 13 11:13:26 2013 +0100
files:       roundup/cgi/templating.py
description:
Fix issue2550822 (3e36a3bc0335 and 843886af0ea1) for multilinks, too
History
Date User Action Args
2013-11-13 10:17:16ThomasAHsetstatus: new -> fixed
nosy: + ThomasAH
messages: + msg4950
priority: normal
assignee: ThomasAH
resolution: fixed
2013-11-12 20:33:56jmackcreate