There can be a need to set the default flat rate service, as a user hint/shortcut.

Patch attached in comment adds this feature.



kotnik’s picture

Status:Active» Needs review
new5.26 KB

Patch attached.

kotnik’s picture

In order for this to work, patch in #1612706: Add support for default shipping service must be applied as well.

Simon Georges’s picture

Wouldn't #1342270: Control the display order of the shipping options on the checkout form be the way to go? Ordering the services should be a way to choose a default, don't you think?

fago’s picture

JennySmith’s picture

I think my issue is related to this one. I think default shipping rates ought to be triggered using default customer profiles rather than setting order or a default shipping option flag.

I'm setting up a single page checkout. I've got two main shipping options:

  • flat rate international (where shipping country != US)
  • flate rate domestic (where shipping country = US)

The default country for shipping address in the customer profiles section is set to US, but the shipping module does not use that value to set its initial shipping rates. Instead of showing the domestic value as expected since the default US is selected, the international flat rate is displayed, I assume because shipping country != US is returning true, which probably means that the code isn't looking at the default values in the profile. Hope this makes sense -- coding isn't my forte'.

Correct shipping rates are displayed once the customer completes the shipping form and triggers shipping module to recalculate (after city, country, state, zip are all entered)