Prevent Logic Hook/Workflow Trigger Firing from a Custom Scheduler

Hi,

I have a custom scheduler job to calculate and update an SLA timer field on Cases, currently running every 5 minutes.

Is there anyway to prevent a bean save ($myCase->save()) from firing logic hooks or initiating workflows?

For example, we are using Sierra workflow to update a datetime field the first time a case is modified (first response time). However our custom scheduler causes the workflow to trigger and the field to be set. We only want it set on a user-initiated modification.

Thanks

Gary.

Parents
  • Hi Gary,

    You can create a custom checkbox (boolean) field with default as unchecked on the cases, when scheduler run just update this checkbox to check (make it 1).

    Now Add a condition on workflow to trigger when custom checkbox field is unchecked. Same condition you can provide in Logic hooks also before it get trigger by save() function.

    this is the simplest way of not to trigger the workflow or Logic hook when your scheduler run.

    Hope this help!!!

Reply
  • Hi Gary,

    You can create a custom checkbox (boolean) field with default as unchecked on the cases, when scheduler run just update this checkbox to check (make it 1).

    Now Add a condition on workflow to trigger when custom checkbox field is unchecked. Same condition you can provide in Logic hooks also before it get trigger by save() function.

    this is the simplest way of not to trigger the workflow or Logic hook when your scheduler run.

    Hope this help!!!

Children