【修复】修复二维码生成与微信交互判断失效的问题。

pull/212/head
jianweie code 2 years ago
parent 75eae8a984
commit de18c3eb06

@ -391,17 +391,17 @@ namespace CoreCms.Net.Services
request.LineColor = new WxaGetWxaCodeUnlimitRequest.Types.Color() { Red = 221, Blue = 51, Green = 238 };
var response = await client.ExecuteWxaGetWxaCodeUnlimitAsync(request);
if (response.IsSuccessful() && response.ErrorCode == (int)WeChatReturnCode.ReturnCode.page)
if (!response.IsSuccessful() && response.ErrorCode == (int)WeChatReturnCode.ReturnCode.page)
{
jm.msg = "后台小程序配置的APPID和APPSECRET对应的小程序未发布上线,或者page没有发布无法生成海报";
return jm;
}
else if (response.IsSuccessful() && response.ErrorCode == (int)WeChatReturnCode.ReturnCode.access_tokenAppSecretaccess_token)
else if (!response.IsSuccessful() && response.ErrorCode == (int)WeChatReturnCode.ReturnCode.access_tokenAppSecretaccess_token)
{
jm.msg = "微信小程序access_token已过期无法为你生成海报";
return jm;
}
else if (response.IsSuccessful() && response.ErrorCode > 0)
else if (!response.IsSuccessful() && response.ErrorCode > 0)
{
var enumType = EnumHelper.GetEnumberEntity<WeChatReturnCode.ReturnCode>(response.ErrorCode);
if (enumType != null)

Loading…
Cancel
Save