Skip to main content
olavo_zapata
Contributor ⭐️⭐️⭐️⭐️
October 16, 2018

Suggestion about workarounds to create CTA by rule with a specific Due date

  • October 16, 2018
  • 13 replies
  • 193 views
Hi Guys,

I'm looking for a way to create CTAs with a specific Due Date by the rules.
I've posted before replying about some other guy suggestion about it (3years ago).

But I didn't have any answer. I would like to know if someone has some workaround to do this:
We try to create an alternative with Process Builder, but it doesn't work I don't know why (maybe because has some Gainsight apex that updates de Due date in the CTA creation).

If someone can check our logic of Process Builder and give some advice will be great as well.

My intention is:
When a CTA is created I want to update the Original Due and Due date to the last day of month from Today()+7

So we did in Salesforce Process Builder the following steps.


1. [JBCXM__CTA__c].Name contains (uncovered customer) - Sample of some CTA.
2. [JBCXM__CTA__c].JBCXM__Source__c = Rules
3. [JBCXM__CTA__c].JBCXM__Reason__c= a0U1a00000G3APaEAN - Our Reason ID
4. [JBCXM__CTA__c].JBCXM__OriginalDueDate__c is null = false

So, basically get a specific reason with a specific name that was created by rules and has the OriginalDueDate.

After that as immediate action:
Update Due Date and Original Due date field with this formula:
DATE(
IF(MONTH( TODAY()+7 ) = 12, YEAR( TODAY()+7 )+1, YEAR( TODAY()+7 )),
IF(MONTH( TODAY()+7 ) = 12, MONTH( TODAY()+7 ) - 11, MONTH( TODAY()+7 )+1),
1) -1

So looks like a simples process builder but just doesn't work.

I'm afraid if someone understands why.

Anyway, thanks for help.

    13 replies

    olavo_zapata
    Contributor ⭐️⭐️⭐️⭐️
    October 26, 2018
    Hi Srinivasa,

    Thanks, I really appreciate your effort for it.

    srinivasa_pulagam
    Helper ⭐️⭐️
    October 30, 2018
    Hi Olavo,

    We tried few processes with Salesforce process builder to update CTA due date, haven't faced any issues. Probably issue is with process criteria or something else. Can you please check with due date set to a static value of far future date in your process action and see you are not facing this issue only for Rules based CTAs.

    olavo_zapata
    Contributor ⭐️⭐️⭐️⭐️
    October 30, 2018
    Hi Srinivasa,



    Strange, but if it works for you and not for me I will record a video and open a ticket.

    I checked the process builder criteria, and the same criteria on manually work the issue are the Rules CTAs.

    So thanks for your effort on this, I really appreciate and now I know that is possible. We just need to understand the bug cause that I will check with support.

    Bests,