You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

Conditional Groovy in a form comparing two accounts

Hello experts!!

I have a requeriment to do, I have this form:

And with Groovy I should get a validation in BALANCE row.

My requeriment is if BALANCE is equal to C1290_CALC then BALANCE cell should be green, else red.

Desired form:

I know how to do it just focusing in BALANCE if is 0 or different to 0, but is not usefull for me:

def greenColor = 0x00FF00 // Verde
def redColor = 0xFF0000 // Rojo

operation.grid.dataCellIterator('BALANCE').each { cell ->
if (cell.data < -1 || cell.data > 1) {
cell.bgColor = redColor
} else {
cell.bgColor = greenColor
}
}

So can I do comparing result between two rows?

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!