Commit d08308f3 authored by Hanno Schlichting's avatar Hanno Schlichting

LP #1061247: Fix ZMI properties edit form for properties named `method`.

parent e92a261c
......@@ -18,6 +18,8 @@ http://docs.zope.org/zope2/releases/.
- repoze.tm2 = 1.0
- tempstorage = 2.12.2
- LP #1061247: Fix ZMI properties edit form for properties named `method`.
- LP #1058049: Fix support for zoperunner section in zope.conf.
- Explicitly close all databases on shutdown, which ensures `Data.fs.index`
......
......@@ -299,9 +299,9 @@ class PropertyManager(Base, ElementWithAttributes):
name = prop['id']
if 'w' in prop.get('mode', 'wd'):
if prop['type'] == 'multiple selection':
value = REQUEST.get(name, [])
value = REQUEST.form.get(name, [])
else:
value = REQUEST.get(name, '')
value = REQUEST.form.get(name, '')
self._updateProperty(name, value)
if REQUEST:
message = "Saved changes."
......@@ -316,8 +316,11 @@ class PropertyManager(Base, ElementWithAttributes):
name=value parameters
"""
if REQUEST is None:
props={}
else: props=REQUEST
props = {}
elif isinstance(REQUEST, dict):
props = REQUEST
else:
props = REQUEST.form
if kw:
for name, value in kw.items():
props[name]=value
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment