Details
Description
Selecting the Fill option for a contact import, which should skip over a data field if there's already a value in it, doesn't for custom data. I duplicated this with the John Smith record on the demo site using the Most Important Issue, Marital Status and Gender fields. The first two were overwritten by the import, but the last one wasn't.
http://d46.demo.civicrm.org/civicrm/contact/view?reset=1&cid=202
I'll try to attach the CSV I used after submitting the ticket; I'm getting a 500 error trying to attach it here.
The relevant code is in CRM/Contact/Import/Parser/Contact.php, line 1752
elseif ($customFieldId = CRM_Core_BAO_CustomField::getKeyID($key)) { $custom = TRUE; }
I'm not completely sure what this part of the conditional is doing. I rewrote this in a hacky way to get this fixed for my immediate need, but it's not committable. I can provide a patch with a little more context and guidance about the above section of the code.