2014-01-16 78 views
3

我已经在Magento 1.7.0.2中设置了联邦快递和DHL运输模块,我的原产国是英国。当我启用记录到日志文件中会显示类似这样的错误:Magento 1.7.0.2联邦快递和DHL不工作

2014-01-16T11:37:32+00:00 DEBUG (7): Array 
(
    [request] => Array 
     (
      [WebAuthenticationDetail] => Array 
       (
        [UserCredential] => Array 
         (
          [Key] => Du7g4fjPU7X4yr4S 
          [Password] => 7TaHmEQyzOdxcxBLlspPIV8sJ 
         ) 

       ) 

      [ClientDetail] => Array 
       (
        [AccountNumber] => 510087062 
        [MeterNumber] => 118588382 
       ) 

      [Version] => Array 
       (
        [ServiceId] => crs 
        [Major] => 10 
        [Intermediate] => 0 
        [Minor] => 0 
       ) 

      [RequestedShipment] => Array 
       (
        [DropoffType] => REGULAR_PICKUP 
        [ShipTimestamp] => 2014-01-16T11:37:31+00:00 
        [PackagingType] => YOUR_PACKAGING 
        [TotalInsuredValue] => Array 
         (
          [Amount] => 3 
          [Currency] => UKL 
         ) 

        [Shipper] => Array 
         (
          [Address] => Array 
           (
            [PostalCode] => SA129NG 
            [CountryCode] => GB 
           ) 

         ) 

        [Recipient] => Array 
         (
          [Address] => Array 
           (
            [PostalCode] => 21001 
            [CountryCode] => DE 
            [Residential] => 1 
           ) 

         ) 

        [ShippingChargesPayment] => Array 
         (
          [PaymentType] => SENDER 
          [Payor] => Array 
           (
            [AccountNumber] => 510087062 
            [CountryCode] => GB 
           ) 

         ) 

        [CustomsClearanceDetail] => Array 
         (
          [CustomsValue] => Array 
           (
            [Amount] => 3 
            [Currency] => UKL 
           ) 

         ) 

        [RateRequestTypes] => LIST 
        [PackageCount] => 1 
        [PackageDetail] => INDIVIDUAL_PACKAGES 
        [RequestedPackageLineItems] => Array 
         (
          [0] => Array 
           (
            [Weight] => Array 
             (
              [Value] => 3 
              [Units] => LB 
             ) 

            [GroupPackageCount] => 1 
            [InsuredValue] => Array 
             (
              [Amount] => 3 
              [Currency] => UKL 
             ) 

           ) 

         ) 

       ) 

     ) 

    [result] => stdClass Object 
     (
      [HighestSeverity] => ERROR 
      [Notifications] => stdClass Object 
       (
        [Severity] => ERROR 
        [Source] => prof 
        [Code] => 1000 
        [Message] => Authentication Failed 
       ) 

      [Version] => stdClass Object 
       (
        [ServiceId] => crs 
        [Major] => 10 
        [Intermediate] => 0 
        [Minor] => 0 
       ) 

     ) 

    [__pid] => 373 
) 

我已成立了联邦快递帐号细节在管理端(客户没有,开发测试键,测试仪表和密码)但它仍然会抛出错误:

此送货方式当前不可用。如果您想使用此送货方式发货,请与我们联系。

+0

你有没有找到答案?我正面临与测试模式相同的问题..如果您的答案比请让我知道.. –

+0

通过Zend \ Http \ Response :: decodeChunkedBody并添加以下代码,而不是当前代码public static function decodeChunkedBody($ body ){$ decBody =''; if(preg_match(“/ ^([\ da-fA-F] +)[^ \ r \ n] * \ r \ n/sm”,trim($ body))){while(preg_match(“/^[\ da-fA-F] +)[^ \ r \ n] * \ r \ n/sm“,trim($ body),$ m)){$ length = hexdec(trim($ m [1]) ); $ cut = strlen($ m [0]); $ decBody。= substr($ body,$ cut,$ length); $ body = substr($ body,$ cut + $ length + 2); }} else {return $ body; } return $ decBody; } @NishantSolanki – drsndodiya

+0

我尝试上面的代码,它的工作对我..hope同样会帮助你 – drsndodiya

回答

0

假设您的凭据是正确的,它看起来像是FedEx沙箱的一个临时问题。我遇到了同样的问题,但它似乎现在正在工作。

+0

嗨,我做了一些Google搜索,并找到一个解决方案可能会帮助你@Josh – drsndodiya

+0

去通过Zend \ Http \ Response :: decodeChunkedBody – drsndodiya

+0

并添加下面的代码,而不是当前的代码public static function decodeChunkedBody ($ body) \t { \t $ decBody =''; (preg_match(“/ ^([\ da-fA-F] +)[^ \ r \ n] * \ r \ n/sm”,trim($ body))){pref_match “/ ^([\ da-fA-F] +)[^ \ r \ n] * \ r \ n/sm”,trim($ body),$ m)){ ($ M [1])); \t \t $ cut = strlen($ m [0]); \t \t \t $ decBody。= substr($ body,$ cut,$ length); \t \t $ body = substr($ body,$ cut + $ length + 2); \t} \t} else { \t return $ body; \t} \t \t return $ decBody; \t} @Josh – drsndodiya