Discussion tool fails when user explicitly disables discussion
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Zope CMF buildout |
Fix Released
|
Undecided
|
Tres Seaver |
Bug Description
f a user chooses "Disabled" on "allow discussion on this item" on a story, the object saves with it set to "Enabled".
(Default works correctly)
----
Root cause:
-SelectionWidget (used for allowDiscussion 3-way) must use strings for vocabulary, so, we use '0', '1', and 'None' for disabled, enabled and default.
The string '0' and the string '1' are both Boolean "True", but Products.
simply does a 'bool(allowDisc
So, disabled ('0') sets the object allow_discussion to True, incorrectly.
---------
Suggested FIX:
Products.
overrideDiscuss
Replace:
else:
content.
With:
else:
content.
Changed in zope-cmf: | |
assignee: | nobody → Tres Seaver (tseaver) |
status: | New → In Progress |
The attached patch is a failing unit test demostrating the bug.