Question: Product Exclusive Tax Calculation Issue

Product Exclusive Tax Calculation Issue

Products exclusive of 6.625% seems to be calculating as 6% for exclusive. A product listed for $10.08usd + (10.08*6.625%) = $10.75 On POS calculation it shows $10.68 which is only 6% How

RP

Rupesh Patel

Asked
Products exclusive of 6.625% seems to be calculating as 6% for exclusive.

A product listed for $10.08usd + (10.08*6.625%) = $10.75
On POS calculation it shows $10.68 which is only 6%


How to fix
  • MS

    Mian Saleem

    Answered
    Hello,

    You are calculating exclusively.

    The tax is calculated as following

    ```
    Product Price 100 and Tax 10%
    Inclusive tax method: (100 * 10) / (100 + 10) = 9.09
    Price 90.91 and Tax amount: 9.09 = 100 (total price with tax)


    Exclusive tax method: (100 * 10) / 100 = 10
    Price 100 and Tax amount: 10 = 110 (total price with tax)
    ```

    Thank you
  • RP

    Rupesh Patel

    Answered
    Try out $3.79 item on demo pos.

    Calculating using exclusive formula, with tax 6.625 totals $4.041, but as per my experience POS is outputting $4.017

    Correct formula
    $3.79 x $6.625 = $25.10875
    $25.10875/100 = $0.2510875
    $3.79 + $0.2510875 = $4.0410875

    The code is rounding down to integer or something because $4.017 means only 6%. Tried multiple items.
  • MS

    Mian Saleem

    Answered
    Hello,

    The tax will be rounded to your decimal points. There is only 4 max decimal points for precision.

    Simple POS are using the above mentioned from start and there is no plan to change. If you need, you can modify the `exlusiveTax` & `inclusiveTax` method of `app/libraries/Tec.php` for php while `themes/default/assets/dev/js/custom.js` for javascript.

    Thank you
  • Login to Reply