Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-9535

Merge Contacts : Merging of email addresses with different location types results in over-writing of data

    Details

    • Type: Bug
    • Status: Done/Fixed
    • Priority: Minor
    • Resolution: Fixed/Completed
    • Affects Version/s: 4.1.0
    • Fix Version/s: 4.2.0
    • Component/s: Core CiviCRM
    • Labels:
      None

      Description

      Currently if the two contacts being merged each have an email address associated with a different location type, we include an "add new" checkbox. However, if the user doesn't check the box - we overwrite contact b's email address with the value from contact a - despite the fact that the location types are different. This is confusing and inconsistent with the behavior used for Address merging (where we automatically 'add new' if the two addresses have different location types).

      To recreate:

      • add 2 contacts with same first and last name. Contact A has a billing email only. Contact B has a home email only
      • run dedupe and select the pair for merging
      • if you request data to be merged for email address, leave 'Home' location type selected for Contact B, and do NOT check "[ ] add new" box, then the home email address value is overridden by the billing email.

      This behavior is confusing and unexpected.

      If you do something similar with Addresses, then we only overwrite Address B with Address A if the SAME location type is selected - and we clearly mark this with "(overwrite)" when the same location type is selected. If a different location type is selected, we automatically "(add)". I think the behavior is different because we do NOT allow multiple addresses w/ same location type, but we do allow multiple emails, phones etc. with same location type.

      Suggested fix:
      1. Only show the [ ] add checkbox when user has selected the same location type for Contact A email and Contact B email. The purpose of the checkbox is to allow user to say I want to add ANOTHER email with the same location type.

      2. If a different location type is selected, then we can just display "(add)" text AND the behavior should be to insert the additional email with it's location type .

      NOTE: A screenshot of the 'setup' for this is attached. I haven't tested with Phone, Website or IM but I suspect they have the same problem.

        Attachments

          Activity

            People

            • Assignee:
              deepak Deepak Srivastava
              Reporter:
              dgg David Greenberg
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: