my issue could be related to this one Updating leads after adding fields but since there was no answer on this topic I create this one.
I got a few custom fields in my leads table.
My code which shall to update the fields in the leads table it looks like that:
$entity = $repo->findOneBy( $keyArray );
The following sets a value of my custom field which I added in the Contacts table via
The following is a method which is provided by the CustomFieldEntityTrait which is used in the
It prints out the information that the customfieldvalue has been set!
[customfieldvalue] => 5
The problem is that the persist and the flush only store the update of the FirstName field (which is part of the Mautic Lead entity). However the custom field gets ignored.
Does anybody know how what I am doing wrong?
Another useful information might be if I am creating the dataset (so not updating an existing one, but creating a new one) using:
Both fields are set correctly. So really seems to be a problem with the update of custom fields.