Rollback updates if a specific condition is met

Elvin_Salim
Tera Contributor

If I change any field's value in the record and save it, after saving it if the "Message" field gets a value via the API, it should rollback all the updates I made in the record. Any idea how I can implement such logic?

2 REPLIES 2

Prataps135
Mega Sage

Hi @Elvin_Salim ,

 

In my understanding you can use before BR and use REST Message script there.

Or can you please more elaborate your issue.

 

Regards,

Pratap Singh Sisodia

Hi @Prataps135 ,

 

The logic should be like this: If the "Message" field's value is still "Error" or its value changed to "Error" after the updates, then rollback all current updates in the record.

There is no need to get that value via API, the simple condition is like this: (If the "Message" field still is/changes to "Error" then rollback all current updates in the record).