magento / magento2

Prior to making any Submission(s), you must sign an Adobe Contributor License Agreement, available here at: https://opensource.adobe.com/cla.html. All Submissions you make to Adobe Inc. and its affiliates, assigns and subsidiaries (collectively “Adobe”) are subject to the terms of the Adobe Contributor License Agreement.
http://www.magento.com
Open Software License 3.0
11.56k stars 9.32k forks source link

Coding error in tax details #30376

Closed hanaks closed 3 years ago

hanaks commented 4 years ago

Preconditions (*)

Magento version 2.4.0

Steps to reproduce (*)

  1. Set up Magento with a two tax classes with different rates. One for shipping and another for product. I have used setup for Norway.
  2. Install Nets payment gateway module: https://tech.dibspayment.com/easy/webshop_modules/magento2
  3. Configure for testing.
  4. Submit a test order: https://tech.dibspayment.com/easy/test-information
  5. Visit the successfully placed order in backend.

Expected result (*)

No error.

Actual result (*)

Order details in backend doesn't fully generate. There is an error in bottom, after which there is no more output: <tr id="rate-An error has happened during application run. See exception log for details.

The error happens in vendor/magento/module-sales/view/adminhtml/templates/order/totals/tax.phtml

Here is dump of $_fullInfo variable in that file:

Array
(
    [0] => Array
        (
            [amount] => 70.0000
            [base_amount] => 70.0000
            [base_real_amount] => 70.0000
            [rates] => Array
                (
                    [0] => Array
                        (
                            [code] => Mva lav
                            [title] => Mva lav
                            [percent] => 15
                            [position] => 0
                            [priority] => 0
                        )

                    [1] => Array
                        (
                            [code] => Mva Høy
                            [title] => Mva Høy
                            [percent] => 25
                            [position] => 0
                            [priority] => 0
                        )

                )

            [percent] => 40
            [id] => Mva lavMva Høy
        )

)

Order printing is affected too, error is in different file. I didn't test invoice, creditmemo, shipment and printing of these.


Please provide Severity assessment for the Issue as Reporter. This information will help during Confirmation and Issue triage processes.

m2-assistant[bot] commented 4 years ago

Hi @hanaks. Thank you for your report. To help us process this issue please make sure that you provided the following information:

Please make sure that the issue is reproducible on the vanilla Magento instance following Steps to reproduce. To deploy vanilla Magento instance on our environment, please, add a comment to the issue:

@magento give me 2.4-develop instance - upcoming 2.4.x release

For more details, please, review the Magento Contributor Assistant documentation.

Please, add a comment to assign the issue: @magento I am working on this


:clock10: You can find the schedule on the Magento Community Calendar page.

:telephone_receiver: The triage of issues happens in the queue order. If you want to speed up the delivery of your contribution, please join the Community Contributions Triage session to discuss the appropriate ticket.

:movie_camera: You can find the recording of the previous Community Contributions Triage on the Magento Youtube Channel

:pencil2: Feel free to post questions/proposals/feedback related to the Community Contributions Triage process to the corresponding Slack Channel

Morgy93 commented 4 years ago

Already reported here: #30094

m2-assistant[bot] commented 3 years ago

Hi @engcom-Alfa. Thank you for working on this issue. In order to make sure that issue has enough information and ready for development, please read and check the following instruction: :point_down:

engcom-Alfa commented 3 years ago

Duplicate of #30094

Kilawuyiek commented 1 year ago

It appears that there is an error happening in the Magento sales module when trying to display the tax information for orders that have been placed using the Nets payment gateway module. The error message states that there is an error in the file "vendor/magento/module-sales/view/adminhtml/templates/order/totals/tax.phtml" and that "An error has happened during application run. See exception log for details."

It seems that this issue is caused by the fact that the tax classes in the order have the same code, "Mva lavMva Høy", which is causing the issue in displaying the tax information.

To resolve this issue, you should check the tax class configuration and make sure that the tax classes have unique codes. Alternatively, you can also contact the developer of the Nets payment gateway module for further assistance.