tig-nl/gls-magento2

[BUG] Languages not supported?

Opened this issue · 2 comments

To Reproduce
Steps to reproduce the behavior:

  1. Setup a multistore with various languages, install the plugin etc. Make sure it's all working fine IN DUTCH
  2. Switch the store view to another language (tested fr_FR and sv_SE) and try to order

Expected result
Having deliveryOptions available in the correct language

Actual result
No deliveryOptions available. The 'gls/deliveryoptions/services?postcode=XXX&country=XXX&_=XXXX' route returns '[]' (empty array). When calling that same url through the main/dutch store it DOES give the proper results

Workaround
TIG/GLS/Service/DeliveryOptions/Services.php:74 $langCode -> Change into 'NL' (hardcoded language)

I assume GLS only supports a limited amount of languages OR the language code is passed on wrongly. In either case I'd love to have a fallback to English

** Please complete the following information**

  • Magento version: Mage 2.4.3-p1
  • PHP version: 7.4.X
  • TIG GLS version: 2.6 Sorry, 1.4.0

Hi @vandijkstef,

Because of this, you cannot place the order because it is expecting delivery options while the delivery options are not available, am I correct? I will also internally talk about this issue if the GLS works outside NL.

Have a great day,
Jeffrey

Hi @tig-jeffreybranderhorst ,

Indeed the order isn't accepted.

The 'storepickup' options are available (if chosen a destination in NL), but the 'default' delivery isn't.