Create Automation for the Field "Mark up by"

Create Automation for the Field "Mark up by"

Hello everyone,

I'm importing expenses from Zoho Expense to Zoho Books.

I want to auto-calculate the "Mark up by" field based on the custom field “Discount” I created before.

The trigger of the workflow will be the creation of the expense itself.

The filter will be 1. WHEN the expense is billable AND 2. when the field “Discount” equals "25%" OR 3. "50%".

In the case the discount is 25% the field "Mark up by" should be [Original Net Expense Amount] * 1,33.
In the case the discount is 50% the field "Mark up by" should be [Original Net Expense Amount] * 2,00.

I need help to code the script.