Magento2: Product Price is mismatch in invoice and invoice PDF magento for Bundle Product 2.2.1

Created on 22 Dec 2017  路  16Comments  路  Source: magento/magento2


I am getting different price in invoice and invoice PDf for the bundle product. Actually, The price in the invoice pdf are wrong. I am getting right price in order, order email, invoice, invoice email or everywhere in the application, but invoice PDf price is wrong only Bundle product.

Preconditions


  1. Install Magento 2.2.1
  2. Create Bundle product in application.
  3. In Magento Admin go to Stores - Tax Rules and Add New Tax Rule
    34373744-2e6633ec-eb03-11e7-9fbe-2aa2ffa9a13c
  4. Go to Stores - Configuration - Sales - Tax and enable the following settings
    34373758-3a995126-eb03-11e7-857f-3b38d4fbf36c

Steps to reproduce

  1. Create the order with bundle product.
  2. Create the invoice, then download the invoice PDF.

Expected result

  1. Price in the invoice PDF should be same as invoice page or order page.
    Invoice Screen shot:

screenshot from 2017-12-22 14-38-25

Actual result

  1. Prices in the invoice PDF and invoice page are different. Getting wrong price in invoice PDF for bundle product.
    Invoice PDF Screen shot:
    invoice-pdf

Email Confirmed P1 dev in progress ready for dev Reported on 2.2.x Reproduced on 2.1.x Reproduced on 2.2.x Reproduced on 2.3.x Reproduced on 2.4.x S1

Most helpful comment

Working on this.

All 16 comments

@digvijay2017 thank you for your report.
We were not able to reproduce this issue by following the steps you provided. Please provide more detailed steps to reproduce or try to reproduce this issue on a clean installation or latest release.

Hi,

This issue occurring only with the bundle product. And product is taxable good, So Create a Tax Rule and Zone like This:
tax zones

tax-rule

Please use the following Tax configuration :

tax-include-config

I have checked this issue with the fresh Magento 2.2.1 installation:

Invoice :
error-invoice

Invoice Pdf screenshot:
invoice-error-pdf

In the screen shoot first product is the simple product but second product is the bundle product. Basically bundle product not including the TAX amount in the invoice PDF.

@digvijay2017, thank you for your report.
We've created internal ticket(s) MAGETWO-86128 to track progress on the issue.

Working on this.

Hello Magento-team, is there any progress for this bug ? I am facing the same problem.

@sergiypop Solution is in the process of delivery at the moment.

@ishakhsuvarov It would be great if you could post the commit for the solution.

@sergiypop It is currently available only in private repositories. Comment with information will be posted once fix is delivered.

@sergiypop @ishakhsuvarov . I am still looking the permanent solution for this issue. Well
For temporary solution: I am added this
$price = $order->formatPriceTxt($childItem->getPriceInclTax());
instead of
$price = $order->formatPriceTxt($childItem->getPrice()); in the file : vendor/magento/module-bundle/Model/Sales/Order/Pdf/Items/Invoice.php line : 135 by overwrite the Model : Magento\Bundle\Model\Sales\Order\Pdf\Items\Invoice

@ishakhsuvarov @sergiypop Will this be in 2.3.2?

Hi @engcom-Bravo. Thank you for working on this issue.
Looks like this issue is already verified and confirmed. But if you want to validate it one more time, please, go though the following instruction:

  • [ ] 1. Add/Edit Component: XXXXX label(s) to the ticket, indicating the components it may be related to.
  • [ ] 2. Verify that the issue is reproducible on 2.4-develop branch

    Details- Add the comment @magento give me 2.4-develop instance to deploy test instance on Magento infrastructure.
    - If the issue is reproducible on 2.4-develop branch, please, add the label Reproduced on 2.4.x.
    - If the issue is not reproducible, add your comment that issue is not reproducible and close the issue and _stop verification process here_!

  • [ ] 3. If the issue is not relevant or is not reproducible any more, feel free to close it.


Reproducible on Magento 2.4-develop
bundle_subtotal

@engcom-Bravo Thank you for verifying the issue.

Unfortunately, not enough information was provided to acknowledge ticket. Please consider adding the following:

  • [ ] Add "Component: " label(s) to this ticket based on verification result. If uncertain, you may follow the best guess

Once all required information is added, please add label "Issue: Confirmed" again.
Thanks!

:white_check_mark: Confirmed by @engcom-Bravo
Thank you for verifying the issue. Based on the provided information internal tickets MC-30127 were created

Issue Available: @engcom-Bravo, _You will be automatically unassigned. Contributors/Maintainers can claim this issue to continue. To reclaim and continue work, reassign the ticket to yourself._

Hi @maheshWebkul721. Thank you for working on this issue.
Looks like this issue is already verified and confirmed. But if you want to validate it one more time, please, go though the following instruction:

  • [ ] 1. Add/Edit Component: XXXXX label(s) to the ticket, indicating the components it may be related to.
  • [ ] 2. Verify that the issue is reproducible on 2.4-develop branch

    Details- Add the comment @magento give me 2.4-develop instance to deploy test instance on Magento infrastructure.
    - If the issue is reproducible on 2.4-develop branch, please, add the label Reproduced on 2.4.x.
    - If the issue is not reproducible, add your comment that issue is not reproducible and close the issue and _stop verification process here_!

  • [ ] 3. If the issue is not relevant or is not reproducible any more, feel free to close it.


Hi @engcom-Golf. Thank you for working on this issue.
Looks like this issue is already verified and confirmed. But if you want to validate it one more time, please, go though the following instruction:


    1. Add/Edit Component: XXXXX label(s) to the ticket, indicating the components it may be related to.

    1. Verify that the issue is reproducible on 2.4-develop branch
      Details- Add the comment @magento give me 2.4-develop instance to deploy test instance on Magento infrastructure.
      - If the issue is reproducible on 2.4-develop branch, please, add the label Reproduced on 2.4.x.
      - If the issue is not reproducible, add your comment that issue is not reproducible and close the issue and _stop verification process here_!
    1. If the issue is not relevant or is not reproducible any more, feel free to close it.

Was this page helpful?
0 / 5 - 0 ratings