#1 — Subfields cannot all be cleared in a field, edit is ignored
by
Webworks
—
last modified
Jul 07, 2010 10:48 AM
| State | Unconfirmed |
|---|---|
| Version: | 0.9.2 |
| Area | Functionality |
| Issue type | Bug |
| Severity | Medium |
| Submitted by | Webworks |
| Submitted on | Jul 07, 2010 |
| Responsible |
—
|
| Target release: |
—
|
A recordfield cannot be cleared of all values when editing. The field will just be ignored and the old values remain. If at least one sub field has a value, it works though. This is why you do not notice this as long as at least one sub field is required.
I have tested this in versions 1.1a2 and 0.9.6.
When creating a recordfield with no mandatory subfields
ateapi.RecordField(
name='test_empty',
subfields=('field1',
'field2'),
subfield_types = {'field1':'lines','field2':'lines'},
widget=ateapi.RecordWidget(
label=_("Test empty"),
),
),
If you enter values in this field and save, the values will remain. If you then subsequently clear all subfields and save, the old values will still be there. It seems Plone never processes the field in that case.
I have tested this in versions 1.1a2 and 0.9.6.
When creating a recordfield with no mandatory subfields
ateapi.RecordField(
name='test_empty',
subfields=('field1',
'field2'),
subfield_types = {'field1':'lines','field2':'lines'},
widget=ateapi.RecordWidget(
label=_("Test empty"),
),
),
If you enter values in this field and save, the values will remain. If you then subsequently clear all subfields and save, the old values will still be there. It seems Plone never processes the field in that case.
- Steps to reproduce:
- Clear values of all subfields of a field, and save.
No responses can be added.
If you can, please log in before submitting a reaction.
