How can you determine in a Before Commit Microflow which fields have updated?

0
In a before commit handler I want to check if certain fields have changed, this to determine should take certain actions. Is it possible to access the before values and compare them with the values to be committed?
asked
3 answers
4

retrieve the record from the database and compare values

Retrieve
From database
Select correct Entity

Range
First

XPath
[id = $ObjectVariableName]

VariableName
RetrieveObjectFromDataBase

Decision
$ObjectVariableName/Attribute = $RetrieveObjectFromDataBase/Attribute

 

answered
4

You could use Community Commons in the Marketplace. This has the memberHasChanged action in the ORM section where you pass in an object and the name of the attribute you want to see has changed. It returns a boolean that’s true if it’s changed since the last commit.

Hope this helps.

answered
1

A retrieve action from DB should work, with that xpath : [id = $myObject] 

Then you just have to compare every fields of $myObject with the object returned by your action. 

 

answered