Campaign - Variables in Email Template are blank in email received 7.11.1 & 7.11.2

Hello,

Can you please tell me if you have the same problem ?

Sending tests emails to targets and leads, all the variables I tried are empty/blank in the emails received.
They should be replaced by the values. There is no error in any log or on the front.

Campaign type: Email & Newsletter
Variables tested: $contact_full_name , $contact_first_name , $contact_last_name , $contact_name

Is it working for you ?

Aure

By the way, I just found out that in CAMPAIGN Wizard, the only option in the drop-down is Contact/Lead/Target, whereas if I create an Email Template in the Email Templates module, the drop-down contains all the modules in SuiteCRM.

I just tried to copy some variable names ($prospect_first_name) in the Campaign Email and then my prospects receive emails with their names, but not leads.

Does it mean that:

  • Campaign Email only works with Contacts by default ? Only can choose contacts variables ($contact_full_name , $contact_first_name , $contact_last_name) ?
  • If I want to have variables for Leads and Targets, I should write manually something like this: “Hello $prospect_first_name,$lead_first_name,$contact_first_name” ?

Please let me know if all this is normal ? Thanks a lot

I confirm that after changing the logs to WARNING I can see:

[WARN] Variable $contact_name parsed to an empty string, because attribute name is not set in Lead bean
[WARN] Variable $contact_first_name parsed to an empty string, because attribute first_name is not set in Lead bean
[WARN] Variable $contact_name parsed to an empty string, because attribute name is not set in Prospect bean
[WARN] Variable $contact_first_name parsed to an empty string, because attribute first_name is not set in Prospect bean

Why the option in the drop-down is called “Contact/Lead/Target” if it only works with Contacts ?
Is it a bug ?
Is it working for you ?

@aureh12, yes, this is a bug and the developers have it as an open issue on Github. More detail here:

https://suitecrm.com/suitecrm/forum/suitecrm-7-0-discussion/21822-v7-11-1-campaign-email-variables-fail-error-unable-to-find-relationship-emails-email-templates#78931

BTW, I just noticed that variables work for CONTACTS but don’t work for LEADS and TARGETS (v7.11.3)

Leads variables workaround: https://suitecrm.com/suitecrm/forum/suitecrm-7-0-discussion/21822-v7-11-1-campaign-email-variables-fail-error-unable-to-find-relationship-emails-email-templates?start=15