And then the following fields to the order line:
'documentNo','type','no','description','locationCode','quantity','unitPrice','lineDiscount','lineAmount','qtyToShip','qtyToInvoice','plannedDeliveryDate','plannedShipmentDate','shipmentDate','shortcutDimension1Code','shortcutDimension2Code','ShortcutDimCode3','documentType',
And, as said, all this is working correctly.
: : : : MODIFICATION REQUEST : : : :
The request is to add the
vatProdPostingGroup
vatBusPostingGroup
fields to the order line and the order, so that those fields are set correctly in the resulting orders.
: : : : THE PROBLEM : : : :
For the test order we have the following custom VAT code values:
vatProdPostingGroup: '22.S' (our normal 22%VAT)
vatBusPostingGroup: 'NAZ' (national customers)
When adding those fields we get different results (error or no field added) depending on the situation.
1) Initially, adding the vatProdPostingGroup field to the line and the vatBusPostingGroup to the order we got an error:
The VAT Posting Setup does not exist. Identification fields and values:
VAT Bus. Posting Group='',VAT Prod. Posting Group='022.S'
This shows that the Vat Bus Posting Group is totally ignored (instead of 'NAZ' it is set to an empty string) and BC complains the combination ( empty, '22.S' ) is not registered in VAT Posting Setup. The order is left empty, with no lines, but the VAT Bus Posting Group is correctly set to NAZ (!!)
2) Adding the combination of ( '' empty , '22.S' ) in VPS:
avoids the error, and the line is correctly added to the order, but (and this was very surprising) the VAT Prod Posting Group is left empty!
So, first BC complained about not beeing ableto add a line with said VAT Posting- After adding the right combo, it added the line without the VAT posting.
At this point we have no clue. Any help is apprecieted.
Thanks for any suggestion you can give us... for any doubt or clarification please ask.