Skip to content

Commit

Permalink
Merge pull request #2945 from JeffreySu/Developer
Browse files Browse the repository at this point in the history
Developer
  • Loading branch information
JeffreySu authored Nov 10, 2023
2 parents d7f18a3 + ff4946c commit f4712f7
Show file tree
Hide file tree
Showing 11 changed files with 41 additions and 36 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Senparc.CO2NET.WebApi" Version="1.4.2" />
<PackageReference Include="Senparc.CO2NET.WebApi" Version="1.5.0-rc.2" />
<PackageReference Include="Senparc.NeuChar.App" Version="1.4.0-rc.2" />
<PackageReference Include="Senparc.NeuChar.AspNet" Version="1.4.0-rc.2" />

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,10 @@

<!--引用 Nuget 包-->
<ItemGroup>
<PackageReference Include="Senparc.Weixin.AspNet" Version="1.0.5-beta1" />
<PackageReference Include="Senparc.Weixin.MP" Version="16.19.3" />
<PackageReference Include="Senparc.Weixin.MP.Middleware" Version="1.0.6-beta1" />
<PackageReference Include="Senparc.Weixin.MP.MVC" Version="7.12.13" />
<PackageReference Include="Senparc.Weixin.AspNet" Version="1.1.0-rc.2" />
<PackageReference Include="Senparc.Weixin.MP" Version="16.20.0-rc.2" />
<PackageReference Include="Senparc.Weixin.MP.Middleware" Version="1.1.0-rc.2" />
<PackageReference Include="Senparc.Weixin.MP.MVC" Version="7.13.0-rc.2" />
</ItemGroup>

<!--直接引用源码-->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,10 @@

<!--引用 Nuget 包-->
<ItemGroup>
<PackageReference Include="Senparc.Weixin.AspNet" Version="1.0.5-beta1" />
<PackageReference Include="Senparc.Weixin.MP" Version="16.19.3" />
<PackageReference Include="Senparc.Weixin.MP.MVC" Version="7.12.13" />
<PackageReference Include="Senparc.Weixin.TenPay" Version="1.12.14" />
<PackageReference Include="Senparc.Weixin.AspNet" Version="1.1.0-rc.2" />
<PackageReference Include="Senparc.Weixin.MP" Version="16.20.0-rc.2" />
<PackageReference Include="Senparc.Weixin.MP.MVC" Version="7.13.0-rc.2" />
<PackageReference Include="Senparc.Weixin.TenPay" Version="1.13.0-rc.2" />
<PackageReference Include="System.Drawing.Common" Version="8.0.0-rc.2.23479.14" />
<PackageReference Include="ZXing.Net" Version="0.16.9" />
</ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@

<!--引用 Nuget 包-->
<ItemGroup>
<PackageReference Include="Senparc.Weixin.AspNet" Version="1.0.5-beta1" />
<PackageReference Include="Senparc.Weixin.MP" Version="16.19.3" />
<PackageReference Include="Senparc.Weixin.MP.MVC" Version="7.12.13" />
<PackageReference Include="Senparc.Weixin.TenpayV3" Version="1.1.0-beta1" />
<PackageReference Include="Senparc.Weixin.AspNet" Version="1.1.0-rc.2" />
<PackageReference Include="Senparc.Weixin.MP" Version="16.20.0-rc.2" />
<PackageReference Include="Senparc.Weixin.MP.MVC" Version="7.13.0-rc.2" />
<PackageReference Include="Senparc.Weixin.TenpayV3" Version="1.2.0-rc.2" />
<PackageReference Include="System.Drawing.Common" Version="8.0.0-rc.2.23479.14" />
<PackageReference Include="ZXing.Net" Version="0.16.9" />
</ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@

<!--引用 Nuget 包-->
<ItemGroup>
<PackageReference Include="Senparc.Weixin.AspNet" Version="1.0.5-beta1" />
<PackageReference Include="Senparc.Weixin.Work" Version="3.17.0" />
<PackageReference Include="Senparc.Weixin.Work.Middleware" Version="1.0.6-beta1" />
<PackageReference Include="Senparc.Weixin.AspNet" Version="1.1.0-rc.2" />
<PackageReference Include="Senparc.Weixin.Work" Version="3.18.0-rc.2" />
<PackageReference Include="Senparc.Weixin.Work.Middleware" Version="1.1.0-rc.2" />
</ItemGroup>

<!--直接引用源码-->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@

<!--引用 Nuget 包-->
<ItemGroup>
<PackageReference Include="Senparc.Weixin.AspNet" Version="1.0.5-beta1" />
<PackageReference Include="Senparc.Weixin.TenPayV3" Version="1.1.0-beta1" />
<PackageReference Include="Senparc.Weixin.WxOpen" Version="3.16.4" />
<PackageReference Include="Senparc.Weixin.WxOpen.Middleware" Version="1.0.6-beta1" />
<PackageReference Include="Senparc.Weixin.AspNet" Version="1.1.0-rc.2" />
<PackageReference Include="Senparc.Weixin.TenPayV3" Version="1.2.0-rc.2" />
<PackageReference Include="Senparc.Weixin.WxOpen" Version="3.17.0-rc.2" />
<PackageReference Include="Senparc.Weixin.WxOpen.Middleware" Version="1.1.0-rc.2" />
</ItemGroup>

<!--直接引用源码-->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ namespace Senparc.Weixin.MP.AdvancedAPIs
/// <summary>
/// 模板消息接口
/// </summary>
[NcApiBind(NeuChar.PlatformType.WeChat_OfficialAccount,true)]
[NcApiBind(NeuChar.PlatformType.WeChat_OfficialAccount, true)]
public static class TemplateApi
{
/// <summary>
Expand Down Expand Up @@ -180,29 +180,30 @@ public static GetIndustryJsonResult GetIndustry(string accessTokenOrAppId, int t
/// </summary>
/// <param name="accessTokenOrAppId">AccessToken或AppId(推荐使用AppId,需要先注册)</param>
/// <param name="template_id_short">模板库中模板的编号,有“TM**”和“OPENTMTM**”等形式</param>
/// <param name="keyword_name_list">选用的类目模板的关键词,按顺序传入,如果为空,或者关键词不在模板库中,会返回40246错误码</param>
/// <param name="timeOut"></param>
/// <returns></returns>
public static AddtemplateJsonResult Addtemplate(string accessTokenOrAppId, string template_id_short, int timeOut = Config.TIME_OUT)
public static AddtemplateJsonResult AddTemplate(string accessTokenOrAppId, string template_id_short, string[] keyword_name_list, int timeOut = Config.TIME_OUT)
{
return ApiHandlerWapper.TryCommonApi(accessToken =>
{
string urlFormat = Config.ApiMpHost + "/cgi-bin/template/api_add_template?access_token={0}";
var msgData = new
{
template_id_short = template_id_short

template_id_short = template_id_short,
keyword_name_list = keyword_name_list
};
return CommonJsonSend.Send<AddtemplateJsonResult>(accessToken, urlFormat, msgData, CommonJsonSendType.POST, timeOut: timeOut);

}, accessTokenOrAppId);
}

/// <summary>
/// 获取模板列表
/// </summary>
/// <param name="accessTokenOrAppId">AccessToken或AppId(推荐使用AppId,需要先注册)</param>
/// <param name="timeOut"></param>
/// <returns></returns>

public static GetPrivateTemplateJsonResult GetPrivateTemplate(string accessTokenOrAppId, int timeOut = Config.TIME_OUT)
{
return ApiHandlerWapper.TryCommonApi(accessToken =>
Expand Down Expand Up @@ -364,7 +365,7 @@ public static async Task<GetIndustryJsonResult> GetIndustryAsync(string accessTo
/// <param name="template_id_short">模板库中模板的编号,有“TM**”和“OPENTMTM**”等形式</param>
/// <param name="timeOut"></param>
/// <returns></returns>
public static async Task<AddtemplateJsonResult> AddtemplateAsync(string accessTokenOrAppId, string template_id_short, int timeOut = Config.TIME_OUT)
public static async Task<AddtemplateJsonResult> AddTemplateAsync(string accessTokenOrAppId, string template_id_short, int timeOut = Config.TIME_OUT)
{
return await ApiHandlerWapper.TryCommonApiAsync(async accessToken =>
{
Expand All @@ -378,6 +379,7 @@ public static async Task<AddtemplateJsonResult> AddtemplateAsync(string accessTo

}, accessTokenOrAppId).ConfigureAwait(false);
}

/// <summary>
///【异步办法】 获取模板列表
/// </summary>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>net462;netstandard2.0;netstandard2.1</TargetFrameworks>
<Version>16.20.0-rc.2</Version>
<Version>16.20.1-rc.2</Version>
<AssemblyName>Senparc.Weixin.MP</AssemblyName>
<RootNamespace>Senparc.Weixin.MP</RootNamespace>
<GeneratePackageOnBuild Condition=" '$(Configuration)' == 'Release' ">true</GeneratePackageOnBuild>
Expand Down Expand Up @@ -526,7 +526,8 @@
v16.18.13 回退代码,修复菜单问题 #2843
v16.18.14 JSSDKHelper.GetNoncestr() 弃用 MD5 加密方法
v16.19.0 MessageHandler 和客服接口支持长文本自动切割后连续发送
</PackageReleaseNotes>
v16.20.1 添加 TemplateApi.AddTemplate() 参数
</PackageReleaseNotes>
<RepositoryUrl>https://github.com/JeffreySu/WeiXinMPSDK</RepositoryUrl>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)' == 'Release' ">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
<PackageReference Include="Moq" Version="4.18.2" />
<PackageReference Include="MSTest.TestAdapter" Version="2.2.10" />
<PackageReference Include="MSTest.TestFramework" Version="2.2.10" />
<PackageReference Include="Senparc.CO2NET.AspNet" Version="1.1.5.9" />
<PackageReference Include="Senparc.CO2NET.AspNet" Version="1.3.0-rc.2" />
<PackageReference Include="System.Text.Encoding.CodePages" Version="7.0.0" />
</ItemGroup>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -266,11 +266,12 @@ public static CodeResultJson ChangeVisitStatus(string accessToken, ChangVisitSta
/// <para>文档:https://developers.weixin.qq.com/doc/oplatform/Third-party_Platforms/2.0/api/code/get_history_version.html</para>
/// </summary>
/// <param name="accessToken">从第三方平台获取到的该小程序授权</param>
/// <param name="appVersion"></param>
/// <param name="timeOut"></param>
/// <returns></returns>
public static CodeResultJson RevertCodeRelease(string accessToken, int timeOut = Config.TIME_OUT)
public static CodeResultJson RevertCodeRelease(string accessToken, string appVersion, int timeOut = Config.TIME_OUT)
{
var url = string.Format(Config.ApiMpHost + "/wxa/revertcoderelease?access_token={0}", accessToken.AsUrlData());
var url = string.Format(Config.ApiMpHost + "/wxa/revertcoderelease?access_token={0}&app_version={1}", accessToken.AsUrlData(),appVersion.AsUrlData());

return CommonJsonSend.Send<CodeResultJson>(null, url, null, CommonJsonSendType.GET, timeOut);
}
Expand Down Expand Up @@ -618,9 +619,9 @@ public static async Task<CodeResultJson> ChangeVisitStatusAsync(string accessTok
/// <param name="accessToken">从第三方平台获取到的该小程序授权</param>
/// <param name="timeOut"></param>
/// <returns></returns>
public static async Task<CodeResultJson> RevertCodeReleaseAsync(string accessToken, int timeOut = Config.TIME_OUT)
public static async Task<CodeResultJson> RevertCodeReleaseAsync(string accessToken, string appVersion, int timeOut = Config.TIME_OUT)
{
var url = string.Format(Config.ApiMpHost + "/wxa/revertcoderelease?access_token={0}", accessToken.AsUrlData());
var url = string.Format(Config.ApiMpHost + "/wxa/revertcoderelease?access_token={0}&app_version={1}", accessToken.AsUrlData(), appVersion.AsUrlData());

return await CommonJsonSend.SendAsync<CodeResultJson>(null, url, null, CommonJsonSendType.GET, timeOut).ConfigureAwait(false);
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>net462;netstandard2.0;netstandard2.1</TargetFrameworks>
<Version>3.17.0-rc.2</Version>
<Version>3.17.1-rc.2</Version>
<LangVersion>9.0</LangVersion>
<AssemblyName>Senparc.Weixin.WxOpen</AssemblyName>
<RootNamespace>Senparc.Weixin.WxOpen</RootNamespace>
Expand Down Expand Up @@ -174,8 +174,9 @@
v3.15.15 添加物流服务相关接口和事件推送 PR #2834
v3.15.15.1 获取小程序服务GenerateScheme模型增加env_version字段 PR #2861
v3.16.0 客服接口支持长文本自动切割后连续发送
v3.16.4 微信已于2023 年 9 月 20 日收回下发统一消息接口,标注过时 PR #2921
</PackageReleaseNotes>
v3.16.4 微信已于2023 年 9 月 20 日收回下发统一消息接口,标注过时 PR #2921
v3.17.1 添加 CodeApi.RevertCodeRelease() 方法的 appVersion 参数
</PackageReleaseNotes>
<RepositoryUrl>https://github.com/JeffreySu/WeiXinMPSDK</RepositoryUrl>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)' == 'Release' ">
Expand Down

0 comments on commit f4712f7

Please sign in to comment.