Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix creditmemo tax calculation bug when using multiple discounts (again) #250

Closed
wants to merge 2 commits into from

Conversation

seansan
Copy link
Contributor

@seansan seansan commented Mar 26, 2017

Taken from #88 / maybe can be edited now

Replace

        $creditmemo->setGrandTotal($creditmemo->getGrandTotal() + $subtotal);
        $creditmemo->setBaseGrandTotal($creditmemo->getBaseGrandTotal() + $baseSubtotal);

with 

        $creditmemo->setGrandTotal($creditmemo->getGrandTotal() + $subtotalInclTax);
        $creditmemo->setBaseGrandTotal($creditmemo->getBaseGrandTotal() + $baseSubtotalInclTax);
@seansan
Copy link
Contributor Author

seansan commented Mar 26, 2017

@tmotyl Can you access now? It has been a while since I made these changes. Also need to dive in again. This is why I also asked for confirmation from other testers/people that work with credit memo

@tmotyl
Copy link
Contributor

tmotyl commented Mar 28, 2017

yes, it's editable now

@sreichel
Copy link
Contributor

From #88

When adding several product types and utilizing several (more than 1) discount code the credit memo calculation is not correct.

Please correct me, but magento does not support multiple discount codes by default.

$creditmemo->setGrandTotal($creditmemo->getGrandTotal() + $subtotal);
$creditmemo->setBaseGrandTotal($creditmemo->getBaseGrandTotal() + $baseSubtotal);
$creditmemo->setGrandTotal($creditmemo->getGrandTotal() + $subtotalInclTax);
$creditmemo->setBaseGrandTotal($creditmemo->getBaseGrandTotal() + $baseSubtotalInclTax);

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this tested with different tax settings?

@LeeSaferite
Copy link
Contributor

@sreichel You are correct, Magento does not support multiple coupon codes.

@sreichel
Copy link
Contributor

So it should be fixed in 3rd-party code?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants