You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by "Paul Foxworthy (JIRA)" <ji...@apache.org> on 2011/06/28 05:32:17 UTC

[jira] [Issue Comment Edited] (OFBIZ-4326) VAT Correction for ProductPrice that has priceWithTax =N is not correct (with patch)

    [ https://issues.apache.org/jira/browse/OFBIZ-4326?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13056234#comment-13056234 ] 

Paul Foxworthy edited comment on OFBIZ-4326 at 6/28/11 3:32 AM:
----------------------------------------------------------------

Hi Stéphane,

Could you say a bit more about the problem you've found? I don't understand what the problem is with rounding.

I don't think your suggested fix will do the job. The itemPrice parameter will have the price the user entered, which might be different from the list price or any other standard price. If the list price doesn't already include tax, lines 434-537 are working out the difference between the priceWithTax and the tax included in the actual price for this order, and putting in the difference as an order adjustment.

If the problem is with rounding, why not just round the price variable, or round enteredTotalPriceWithTax when it's calculated on line 515?


Thanks

Paul Foxworthy


      was (Author: paul_foxworthy):
    Hi Stéphane,

Could you say a bit more about the problem you've found? I don't understand what the problem is with rounding.

I don't think your suggested fix will do the job. The itemPrice parameter will have the price the user entered, which might be different from the list price or any other standard price. If the list price includes tax, lines 434-537 are working out the difference between the tax including in the list price and the tax included in the actual price for this order, and putting in the difference as an order adjustment.

If the problem is with rounding, why not just round the itemPrice, or round enteredTotalPriceWithTax when it's calculated on line 515?

Thanks

Paul Foxworthy

  
> VAT Correction for ProductPrice that has priceWithTax =N is not correct (with patch)
> ------------------------------------------------------------------------------------
>
>                 Key: OFBIZ-4326
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4326
>             Project: OFBiz
>          Issue Type: Bug
>          Components: accounting
>    Affects Versions: SVN trunk
>            Reporter: Stéphane DUCAS
>            Priority: Minor
>         Attachments: vatCorrection.patch, vatCorrection_2.patch, vatCorrection_2.patch
>
>
> The VAT correction adjustment is not correct because it's based on the price not rounded (while tax adjustment is calculated from the rounded price).
> I provide the patch for that.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira