我想在Netsuite Advanced PDF / HTML中对与相同税码相对应的值进行小计。它甚至可能吗?有什么其他方法可以实现我的目标?
答案 0 :(得分:1)
这绝对是可能的。 Netsuite在引擎盖下使用的模板引擎是Apache FreeMarker,我强烈建议在那里查看documentation以获取完整的详细信息。
以下是一些可用于启动的基本 未经测试的 代码:
<#assign tax1subtotal = 0 >
<#assign tax2subtotal = 0 >
<#assign tax3subtotal = 0 >
<#list record.item as item>
<#if item.taxcode == [taxcode1]>
<#assign tax1subtotal = tax1subtotal + item.tax1amt>
</#if>
<#if item.taxcode == [taxcode2]>
<#assign tax2subtotal = tax2subtotal + item.tax1amt>
</#if>
<#if item.taxcode == [taxcode3]>
<#assign tax3subtotal = tax3subtotal + item.tax1amt>
</#if>
</#list>
Tax Type 1 Subtotal: ${tax1subtotal}<br/>
Tax Type 2 Subtotal: ${tax2subtotal}<br/>
Tax Type 3 Subtotal: ${tax3subtotal}<br/>