|
@@ -166,6 +166,18 @@ function __construct(){
|
|
|
$xml .= "<PhoneNumber>".preg_replace('/\D/s','',$data['phone'])."</PhoneNumber>".$xmend;//联系方式
|
|
|
//$xml .= "<Email>".$data['email']."</Email>".$xmend;//联系邮箱
|
|
|
$xml .= "</Contact>".$xmend;
|
|
|
+
|
|
|
+ if(($data['country'] == 'Mexico' || $data['al'] == 'MX') && !empty($data['r_tax_id'])){
|
|
|
+ $xml .= "<RegistrationNumbers>".$xmend;
|
|
|
+ $xml .= "<RegistrationNumber>".$xmend;
|
|
|
+ $xml .= '<Number>'.$data['r_tax_id'].'</Number>'.$xmend;
|
|
|
+ $xml .= '<NumberTypeCode>RFC</NumberTypeCode>'.$xmend;
|
|
|
+ $xml .= '<NumberIssuerCountryCode>MX</NumberIssuerCountryCode>'.$xmend;
|
|
|
+ $xml .= "</RegistrationNumber>".$xmend;
|
|
|
+ $xml .= "</RegistrationNumbers>".$xmend;
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
$xml .= "</Consignee>".$xmend;
|
|
|
$xml .= "<Commodity>".$xmend;//多商品循环此外层标签及内层标签
|
|
|
$xml .= "<CommodityCode>".$hgbm."</CommodityCode>".$xmend;//商品编码
|
|
@@ -285,17 +297,6 @@ function __construct(){
|
|
|
/** 发件人承担税费 e**/
|
|
|
}
|
|
|
|
|
|
- if(($data['country'] == 'Mexico' || $data['al'] == 'MX') && !empty($data['r_tax_id'])){
|
|
|
- $xml .= "<CustomerDetails>".$xmend;
|
|
|
- $xml .= "<RegistrationNumbers>".$xmend;
|
|
|
- $xml .= "<RegistrationNumber>".$xmend;
|
|
|
- $xml .= '<Number>'.$data['r_tax_id'].'</Number>'.$xmend;
|
|
|
- $xml .= '<NumberTypeCode>RFC</NumberTypeCode>'.$xmend;
|
|
|
- $xml .= '<NumberIssuerCountryCode>MX</NumberIssuerCountryCode>'.$xmend;
|
|
|
- $xml .= "</RegistrationNumber>".$xmend;
|
|
|
- $xml .= "</RegistrationNumbers>".$xmend;
|
|
|
- $xml .= "</CustomerDetails>".$xmend;
|
|
|
- }
|
|
|
|
|
|
if($data['bx'] > 0)
|
|
|
{
|