Can't figure out email condition??

Matthews

New Member
Hi, I'm having major problems getting a condition to work on a form email.

I would have thought this is quite simple. I've trawled the forum and adapted all the suggested solutions to my needs, but still not working!

I want to send an email when a record has been edited only when the sales stage of the record is equal to 'closed won'. I've tried ...

return '{bm_bookings___b_salestage}' = 'Closed won';
(As described in the wiki - but doesn't work)

return '{bm_bookings___b_salestage}' == 'Closed won';

Any help is greatly appreciated.
 
At least it must be ==
you can do
var_dump('{bm_bookings___b_salestage}');exit;

to see what is in b_salestage.
Try with '{bm_bookings___b_salestage_raw}'

What's the element type?
 
Put the code in the condition; it will show you a blank page with something like
string(xx) "yyyy"
 
First one using b_salestage displays...

string(28) "
  • Closed won
Second using b_salestage_raw displays...

string(10) "Closed won"
 
Ha, should've wrapped those outputs - its meant to read...

string(28 ) "
  • Closed won
"
No space between the 8 and closing bracket, but it keeps inserting a smiley. I also missed the second set of quote marks
 
Right on! I can see what's happening now - nice one Troester! It works using the _raw data.

So just to clarify for any others having problems, I used:
return '{bm_bookings___b_salestage_raw}' == 'Closed won';
 
We are in need of some funding.
More details.

Thank you.

Members online

No members online now.
Back
Top