I am trying to create a custom validator for variable 'amount' in my domain class, such that the new value should be greater than previous by 0.50.
For example, lets say the previous value was 1.0, next time the value should be atleast: [previous value + 0.50] or more.
Thanks in advance for the help
You can try reading
domainEntity.getPersistentValue('amount')
.EDIT: ... in custom validator, like: