If merging 2 contacts, one with reference, and another without, and being the target
one the contact without reference, the constraint is raised as the reference value
is copied before unlinking the other contact.
We avoid it disabling the constraint when merging.
Before this commit, the partner_ref_unique could be changed on the
company even if existing partners share the same internal ref.
Therefore, errors will appear afterwards as DB already contains
duplicates although the policy shouldn't allow it.
With this change, the error will appear as soon as the policy is
changed, so that the data must be fixed before activating the
constraint.