Happy Business Starts Here

Highlighted
Zuora Support

Multiple If conditions in Invoice template

Question:

 

Hello,

Today, our company is only charging VAT for customers in Russia. To make sure we display the correct details on the customer invoice we have a table that is displayed based on an IF statement to look for only customers with Russian Federation as the Bill To Country. We set that up based on the below article:
https://knowledgecenter.zuora.com/CB_Billing/IA_Invoices/Creating_a_Custom_Invoice_Template/EA_IF_Fi...

For 2020, we are adding Malaysia and Singapore to the countries we will need to charge VAT. I am wondering if we can continue to use this but adjust the IF statement to display the table if it is one of those three countries? The article only outlines the single country example so not sure if that is possible.

We want to display the same fields that are displayed today for Russian customers, so I copy/pasted that existing table to replace the PRINT MALAYSIA text.

When I attempt to upload it I get an error message 'TableStart:TaxSummary is a duplicate table' and it will not allow me to proceed.

Is there a way to conditionally display that same original table I created but just now display for 3 countries instead of 1? Unless there is another way to avoid that duplicate issue.

 

Solution:

  • Copy the table, under the "Links" section in "Insert" tool and select "Bookmark"
  • Provide a name and click on Add
  • Then in IF condition, navigate to usual mergefield dialogue box, instead of "Mergefield" function, select "REF" and then select the Bookmark name we added in the previous step and click ok
  • Now the table is added for the respective countries and it will be printed only IF condition value matches. For eg. IF BillToContact.Country is "United States", it won't print anything. 


 

 

 

 

Attached the sample template for reference. 

 






If you found my answer helpful, please give me a kudo ↑
Help others find answers faster by accepting my post as a solution √