我已将 DHL 方法集成到 magento 1.9.2.4 中,但其中存在一个问题。我的原籍国是 AE,当我尝试在同一个国家订购 AE 的东西时,DHL 方法不适用于所有其他国家。我已经联系了 DHL,他们说 magento 日志文件中的标签必须是 N。目前得到 Y
谁能告诉我原始问题是什么以及如何将标签编辑为 N ?
提前谢谢。
好的,这是我已成功解决的这个问题的完整答案。
在这里替换 DHL 功能。app/code/core/Mage/Usa/Model/Shipping/Carrier/Dhl/International.php。确保您在本地制作副本,然后进行更改。
在这个文件中,将此函数更改为下面给出的。
受保护的函数 _checkDomesticStatus($origCountryCode, $destCountryCode){ $this->_isDomestic = false;
$origCountry = (string)$this->getCountryParams($origCountryCode)->name;
$destCountry = (string)$this->getCountryParams($destCountryCode)->name;
$isDomesticOrig = (string)$this->getCountryParams($origCountryCode)->domestic;
$isDomesticDest = (string)$this->getCountryParams($destCountryCode)->domestic;
if (($origCountry == $destCountry) || ($isDomesticOrig && $isDomesticDest)) {
$this->_isDomestic = true;
}
return $this->_isDomestic;
}