When calculating a value with "Call a webhook", how to apply the updated value?

Hi.

I would like to aggregate the values from the journal table into a trial balance table.

The journal table has debit and credit columns. And the trial balance table has debitAmount, creditAmount, and endAmount.

The debitAmount and creditAmount are calculated by aggregating the debit and credit of the journal table, and the endAmount is calculated as the sum of the debitAmount and creditAmount.

 

I compiled the trial balance amount using the following Call a webhook.

{
"Action": "Edit",
"Properties": {
"Locale": "ko-KR",
"Timezone": "Korea Standard Time"
},
"Rows": [
<<START: ........................................................................>>
{
"periodID": "<<[periodID]>>",
"separateID": "<<[separateID]>>",
"accountID": "<<[accountID]>>",
"debitAmount": "<<sum(select(journal[........................................................................))>>",
"creditAmount": "<<sum(select(journal[........................................................................))>>",
"endAmount": "<<[debitAmount]+[creditAmount]>>"
}
<<END>>
]
}

Although we succeeded in calculating debitAmount and creditAmount in the trial balance, endAmount does not reflect the debitAmount and creditAmount values calculated previously. It just gets the value before it is calculated with Call a webhook.

Help me, please.

Thank you.

Solved Solved
0 2 61
1 ACCEPTED SOLUTION

In that case, simply writing out the SUM expressions of both debitAmount and creadAmount in the endAmount should get you what you are looking for.

View solution in original post

2 REPLIES 2

In that case, simply writing out the SUM expressions of both debitAmount and creadAmount in the endAmount should get you what you are looking for.

@TeeSee1 Thank you very much.
I solved the problem by writing 'debitAmount+creditAmount' in "App Formula".

Top Labels in this Space