Browse Source

Fix XmlDocument usage.

pull/49/head
gdlcf88 6 years ago
parent
commit
937406c8b9
  1. 2
      modules/EasyAbp.EShop.Baskets/common.props
  2. 2
      modules/EasyAbp.EShop.Orders/common.props
  3. 2
      modules/EasyAbp.EShop.Payments.WeChatPay/common.props
  4. 18
      modules/EasyAbp.EShop.Payments.WeChatPay/src/EasyAbp.EShop.Payments.WeChatPay.Domain/EasyAbp/EShop/Payments/WeChatPay/WeChatPayPaymentServiceProvider.cs
  5. 2
      modules/EasyAbp.EShop.Payments/common.props
  6. 2
      modules/EasyAbp.EShop.Products/common.props
  7. 2
      modules/EasyAbp.EShop.Stores/common.props

2
modules/EasyAbp.EShop.Baskets/common.props

@ -1,7 +1,7 @@
<Project>
<PropertyGroup>
<LangVersion>latest</LangVersion>
<Version>0.1.6</Version>
<Version>0.1.7</Version>
<NoWarn>$(NoWarn);CS1591</NoWarn>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<Authors>EasyAbp Team</Authors>

2
modules/EasyAbp.EShop.Orders/common.props

@ -1,7 +1,7 @@
<Project>
<PropertyGroup>
<LangVersion>latest</LangVersion>
<Version>0.1.6</Version>
<Version>0.1.7</Version>
<NoWarn>$(NoWarn);CS1591</NoWarn>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<Authors>EasyAbp Team</Authors>

2
modules/EasyAbp.EShop.Payments.WeChatPay/common.props

@ -1,7 +1,7 @@
<Project>
<PropertyGroup>
<LangVersion>latest</LangVersion>
<Version>0.1.6</Version>
<Version>0.1.7</Version>
<NoWarn>$(NoWarn);CS1591</NoWarn>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<Authors>EasyAbp Team</Authors>

18
modules/EasyAbp.EShop.Payments.WeChatPay/src/EasyAbp.EShop.Payments.WeChatPay.Domain/EasyAbp/EShop/Payments/WeChatPay/WeChatPayPaymentServiceProvider.cs

@ -79,21 +79,21 @@ namespace EasyAbp.EShop.Payments.WeChatPay
receipt: payeeConfigurations.GetOrDefault("receipt") as string ?? "N",
sceneInfo: null);
if (result.Attributes == null || result.Attributes["return_code"].Value != "SUCCESS")
if (result.SelectSingleNode("return_code")?.Value != "SUCCESS")
{
throw new UnifiedOrderFailedException(result.Attributes?["return_code"].Value, result.Attributes?["return_msg"].Value);
throw new UnifiedOrderFailedException(result.SelectSingleNode("return_code")?.Value, result.SelectSingleNode("return_msg")?.Value);
}
if (result.Attributes["result_code"].Value != "SUCCESS")
if (result.SelectSingleNode("result_code")?.Value != "SUCCESS")
{
throw new UnifiedOrderFailedException(result.Attributes["return_code"]?.Value,
result.Attributes["return_msg"]?.Value, result.Attributes["err_code_des"]?.Value,
result.Attributes["err_code"]?.Value);
throw new UnifiedOrderFailedException(result.SelectSingleNode("return_code")?.Value,
result.SelectSingleNode("return_msg")?.Value, result.SelectSingleNode("err_code_des")?.Value,
result.SelectSingleNode("err_code")?.Value);
}
payment.SetProperty("trade_type", result.Attributes["trade_type"]);
payment.SetProperty("prepay_id", result.Attributes["prepay_id"]);
payment.SetProperty("code_url", result.Attributes["code_url"]);
payment.SetProperty("trade_type", result.SelectSingleNode("trade_type"));
payment.SetProperty("prepay_id", result.SelectSingleNode("prepay_id"));
payment.SetProperty("code_url", result.SelectSingleNode("code_url"));
return await _paymentRepository.UpdateAsync(payment, true);
}

2
modules/EasyAbp.EShop.Payments/common.props

@ -1,7 +1,7 @@
<Project>
<PropertyGroup>
<LangVersion>latest</LangVersion>
<Version>0.1.6</Version>
<Version>0.1.7</Version>
<NoWarn>$(NoWarn);CS1591</NoWarn>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<Authors>EasyAbp Team</Authors>

2
modules/EasyAbp.EShop.Products/common.props

@ -1,7 +1,7 @@
<Project>
<PropertyGroup>
<LangVersion>latest</LangVersion>
<Version>0.1.6</Version>
<Version>0.1.7</Version>
<NoWarn>$(NoWarn);CS1591</NoWarn>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<Authors>EasyAbp Team</Authors>

2
modules/EasyAbp.EShop.Stores/common.props

@ -1,7 +1,7 @@
<Project>
<PropertyGroup>
<LangVersion>latest</LangVersion>
<Version>0.1.6</Version>
<Version>0.1.7</Version>
<NoWarn>$(NoWarn);CS1591</NoWarn>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<Authors>EasyAbp Team</Authors>

Loading…
Cancel
Save