Commit dab8a4d0 authored by Aurel's avatar Aurel

use the right field key for the validator, thus required relation

field now works when all fields are validated


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@40355 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 4d0542ee
...@@ -130,8 +130,10 @@ class RelationStringFieldValidator( ...@@ -130,8 +130,10 @@ class RelationStringFieldValidator(
except IndexError: except IndexError:
# No object was selected # No object was selected
return [] return []
relation_field_id = field.generate_subfield_key("%s" % \
SUB_FIELD_ID, key=key)
value = self.default_validator_instance.validate(field, value = self.default_validator_instance.validate(field,
key, REQUEST) relation_field_id, REQUEST)
return [(relation_item_id, relation_uid_list, value)] return [(relation_item_id, relation_uid_list, value)]
def _generateFieldValueList(self, field, key, def _generateFieldValueList(self, field, key,
......
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