Jump to content

Recommended Posts

Posted

Hi

I have an email template called WFServicesOvertimeApproval that uses ESP conditions so that information is only displayed if something is entered in the custom fields on the PC.  

When it generates it always also brings back 'undefined' at the end (see example attached) and I can't determine why this is happening. Can anyone take a look as advise?  Thanks

Sam  

image.png

 

Posted

In the email template what is the variable 'undefined' supposed to be?

I would check the SR in db direct and make sure that all custom field mappings are correct (If it is a custom field (more than once I have selected the wrong custom field and only realised when something doesn't work!))

Unanswered PC questions don't show as undefined anymore (tested by adding 26 variables into a single line in a custom field to extract the one answer a user could have provided) so must be a blank field somewhere else. 

Posted

I don't know what undefined is supposed to be, as far as I am aware, nothing!  I've tested all the variables and they all work fine if something is entered in each of them so that's why I'm miffed about what the undefined is.

Sam 

Posted
6 minutes ago, SJEaton said:

yes but all the variables in the template work fine, there are none that don't pull through

Not that I don't believe you but the "undefined" at the bottom of the email suggests there might be a variable there. Just to clarify this, may I as if you can post a screenshot of the current template configuration, the template used to send that email?

Posted

No idea.  Out of curiosity how did you identify it was Custom N?

I'm just going to remove it and start again I think.

I also have another issue on these emails to do with the date/time displaying 1 hour before what is entered in the PC but this is being address under another topic

Sam

Posted
1 minute ago, SJEaton said:

Out of curiosity how did you identify it was Custom N?

I looked at the template ... After "Claim Details" line you have a bunch of variables on each line. Then I matched the lines in your email examples with the lines in the template:

- the first line in the template (after "Claim Details" line) is {{.H_custom_l}} and matches the first line in the email 23-04-2018 23:00;

- the second line in the template (after {{.H_custom_l}}) is {{.H_custom_d}} and matches the second line in the email 1 hours;

- etc.

- until I reached the {{.H_custom_n}} line in the template which matched the "undefined" line in the email.

I highlighted this in the screenshot as well...

Posted

OK Thanks.  Well I've re-done the template and it seems ok now.  Now I just need to sort out the date/time issue and all is good lol

Sam

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...