Details
-
Type: Bug
-
Status: Done/Fixed
-
Priority: Major
-
Resolution: Fixed/Completed
-
Affects Version/s: 3.1.5
-
Fix Version/s: 3.2
-
Component/s: Core CiviCRM
-
Labels:None
Description
Steps to reproduce:
1. Create a Contact Reference type custom field for Individuals.
2. Edit a contact and populate that field with an invalid contact. Save.
3. Notice the validation warning that a valid contact is required. Now select a valid contact. Save
3. Edit the contact again. Enter an invalid string in the autocomplete field. Save.
Results: The contact record is saved without the validation warning. The field 'reverts' to the previous valid contact.
Cause: The hidden autocomplete element ID field is not updated unless a valid contact is selected. This hidden field should be emptied on any change to the text field, so that validation will trigger.