Issue:
A requirement to map Tax Codes specifically based on POS locations. It would also include certain states through website orders.
Resolution:
Below is a Multi-field Formula that allows the IO SmartConnector to evaluate both the POS location and the Ship to State for all website orders. This code evaluates the different values and produces a single value to be passed to the Tax Code Value within the Line item in NetSuite.
{{#compare $.source_name '==' 'pos'}}
{{#compare $.location_id '==' '<locationID>'}}<taxCode ID>
{{else compare $.location_id '==' '<locationID>'}}<taxCode ID>
{{else}}<Default Tax Code>
{{/compare}}
{{else compare $.source_name '==' 'web'}}
{{#compare $.shipping_address.province_code '==' '<state code>'}}
<taxCode ID>
{{else}}<Default Tax Code>
{{/compare}}
{{else}}
<Default Tax Code>
{{/compare}}