Skip to content
This repository has been archived by the owner on Jun 10, 2019. It is now read-only.

Totals sorting aren't correct when using prices excl. tax #124

Open
ZieClaw opened this issue Oct 31, 2017 · 1 comment
Open

Totals sorting aren't correct when using prices excl. tax #124

ZieClaw opened this issue Oct 31, 2017 · 1 comment

Comments

@ZieClaw
Copy link

ZieClaw commented Oct 31, 2017

Hello, I ran into this problem with Magento and PHP7 on websites using prices excluding taxes. Due to usort being changed in PHP7 it will not add the taxes to the grand total but instead substract it as if the prices are entered including taxes.

I also found a solution for this issue which is really easy, add a sort order to the MRSP tag like this in the config.xml file in the module.

<global>
    <sales>
        <quote>
            <totals>
                <nominal>
                    <class>sales/quote_address_total_nominal</class>
                    <before>subtotal</before>
                </nominal>
                <subtotal>
                    <class>sales/quote_address_total_subtotal</class>
                    <after>nominal</after>
                    <before>grand_total</before>
                </subtotal>
                <shipping>
                    <class>sales/quote_address_total_shipping</class>
                    <after>subtotal,freeshipping,tax_subtotal,msrp</after>
                    <before>grand_total</before>
                </shipping>
                <grand_total>
                    <class>sales/quote_address_total_grand</class>
                    <after>subtotal</after>
                </grand_total>
                <msrp>
                    <class>sales/quote_address_total_msrp</class>
                    <before>grand_total</before> <----------------------------- missing in magento
                </msrp>
            </totals>
        </quote>
    </sales>
</global>
@ivanweiler
Copy link
Contributor

Thx for help @ZieClaw

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

No branches or pull requests

2 participants