Custom Field Value is not displaying in email

Hi,

I have created a custom drop-down field in Leads module and populating values from database.

There is a workflow when creating a lead with status as Unassigned email is generated and new email template is created.

Email which is generated using workflow is displaying empty, but when I send same email template using email compose the value is displaying.

Email received using workflow

image

Email sent using email compose

Lead unassigned email

Lead Name: Test email 26

Lead State: IN

Lead Status: Unassigned

Lead County : Patillas

Lead Alt County:

Hi,

Please any one help in this, I’m stuck with this issue.

It’s buggy code, and unfortunately the template variable replacement code is repeated, with variations, in the several places where emails get sent. So sometimes one of them won’t do as much as the others (things like fetching from related modules, or custom fields).

I began doing fixes for this and ended up creating a whole new system (PowerReplacer).

If you are a PHP developer I can try helping you find the code where that is done. but if you’re not, you will have to use an add-on or find a workaround (like a Workflow to copy the field value into a non-custom field).

Hi,

Thank you so much for the reply.

Yes I’m a developer, so can you please help with the code where can I do the customization

I think that if you start from here it will take you to the correct place for variable replacements in emails sent from Workflow.

modules/AOW_Actions/actions/templateParser.php

Thank you @pgr

Will check and let you know

You might try doing a similar fix to this one:

It’s basically changing from old template-replacement code to newer one (far from perfect, also, but possibly solves your problem).