Page 1 of 1

Shipping cost not modify if shipping address is same as billing address

Posted: 14 Feb 2023, 17:58
by lominformatique
Hi,
i've set rules for different countries in shipping action and calculation parameters are set to shipping country rules based on shipping address (if empty on billing address)
it's ok if i set both shipping and billing country, but if i set check box : same address for billing and shipping, the shipping country previously set is used and not deleted, so the calculation is wrong
help ...

Re: Shipping cost not modify if shipping address is same as billing address

Posted: 18 Feb 2023, 21:14
by Jan
Hi, yes, unfortunately this is common logic problem and it is still under review. The "billing and shipping address is the same" is valid for current order so the shipping address is not internal deleted). So yes, in this case, this produce such problem. But the question, which is still discused in community is, should we delete the common user shipping address when this box is checked or should be somehow only set it for current order, etc. etc. Because if user set that the shipping address is the same like billing address, maybe he/she don't expect that his shipping adress will be completely removed.

As you can see e.g. in order:
Image

The shipping address is still included but for this order, it is just not valid (but it is still there for next order, in case user want to select it)


Jan

Re: Shipping cost not modify if shipping address is same as billing address

Posted: 18 Feb 2023, 23:16
by Jan
Hi, please test newest Beta version:
https://github.com/PhocaCz/PhocaCart/re ... Beta17.zip

There is new parameter called: Same Delivery And Billing Address - Influence on Rules

It it is set to 'Yes (Same Value)', then the rules are based not on address which is stored in database. When user checks "billing and delivery address is the same" then for the rules it means that country or region or ZIP is based on billing address.

The parameter is set to "No" (which means internal address is valid for the rules)

Image

When parameter is enabled
Image

stored information in user account is ignored and the same values like by billing address are used. There is even option that values are takes as empty (not set).

Image

Please test and let me know.

Thank you, Jan