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.54k stars 9.32k forks source link

Cart Hardcoding removing tax from total #7769

Closed 4DallasC closed 7 years ago

4DallasC commented 7 years ago

In file:- vendor/magento/module-checkout/Model/Cart/CartTotalRepository.php at 112 $amount = $quoteTotals->getGrandTotal() - $quoteTotals->getTaxAmount(); $amount = $amount > 0 ? $amount : 0; $quoteTotals->setCouponCode($this->couponService->get($cartId)); $quoteTotals->setGrandTotal($amount);

This hard coded removal of tax is in contradiction to the configuration value stored at:- tax/cart_display/grandtotal.

The configuration value should be control the grand total's inclusion of tax, but isn't.

choukalos commented 7 years ago

Hello @4DallasC can you update this ticket per our bug submission guide (link). In particular the pre-conditions and expected/actual results.

Thanks!

veloraven commented 7 years ago

According to contributor guide, tickets without response for two weeks should be closed. If this issue still reproducible please feel free to create the new one: format new issue according to the Issue reporting guidelines: with steps to reproduce, actual result and expected result and specify Magento version.

4DallasC commented 7 years ago

It's unbelievable the effort you guys go to, to avoid fixing the issue.

woxxy commented 7 years ago

Also appears in https://github.com/magento/magento2/issues/5589

springerin commented 7 years ago

@4DallasC why don't you do a PR?

snez commented 6 years ago

@veloraven This is still an issue and manifests in the checkout front-end code:

screen_shot_2018-02-27_at_23_20_40

The grand total excludes the tax whereas the base grand total includes it, even if they are both in the same currency.

snez commented 6 years ago

@choukalos this issue cannot be easily reproduced at the front-end, in my case I came across it while developing a module that injects the quote JS object in a component. But the issue is that the tax is omitted in the back end where @4DallasC pointed out. There is no step-by-step guide to reproduce this, something custom must be put together to have this manifest.

Possibly load the quote object from within a simple payment method like check/money order. Then dump the object in a log file and try to compare the base_grand_total with the grand_total, which will be different.

Can someone confirm the latest version of Magento where this issue manifests?

yeegor commented 4 years ago

Encountered the same issue in 2020. image Magento CLI 2.3.3

matthewhaworth commented 4 years ago

I'm also experiencing this exact issue in 2.3.5. It's particularly strange because it is removing the tax amount but this code has been here for five years... was it previously working by chance and another bug fix elsewhere has brought it to light?

matthewhaworth commented 4 years ago

@magento give me 2.4-develop instance

magento-engcom-team commented 4 years ago

Hi @matthewhaworth. Thank you for your request. I'm working on Magento 2.4-develop instance for you

magento-engcom-team commented 4 years ago

Hi @matthewhaworth, here is your Magento instance. Admin access: https://i-7769-2-4-develop.instances.magento-community.engineering/admin_c448 Login: 30cf1f06 Password: eaf28056dfb6 Instance will be terminated in up to 3 hours.

4DallasC commented 4 years ago

I'm also experiencing this exact issue in 2.3.5. It's particularly strange because it is removing the tax amount but this code has been here for five years... was it previously working by chance and another bug fix elsewhere has brought it to light?

I just gave up reporting bugs like this and just got used to fixing these bugs directly. I suggest you do the same.

ln8711 commented 3 years ago

any idea why the issue still in 2.4 version?

oleksiyzestlogic commented 10 months ago

@magento give me 2.4-develop instance

magento-deployment-service[bot] commented 10 months ago

Hi @oleksiyzestlogic. Thank you for your request. I'm working on Magento instance for you.

magento-deployment-service[bot] commented 10 months ago

Hi @oleksiyzestlogic, here is your Magento Instance: https://db164641e47b841a5519f81721bd4d6f.instances-prod.magento-community.engineering Admin access: https://db164641e47b841a5519f81721bd4d6f.instances-prod.magento-community.engineering/admin_9d31 Login: c75f924b Password: 8efcfc5658dd