Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Developer #15

Merged
merged 213 commits into from
Jul 1, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
213 commits
Select commit Hold shift + click to select a range
4947431
Merge pull request #33 from JeffreySu/master
mc7246 Dec 30, 2020
779abc5
Merge pull request #2295 from JeffreySu/Developer
JeffreySu Jan 15, 2021
7ea9082
Merge pull request #2297 from JeffreySu/Developer-WxOpenLive
JeffreySu Jan 16, 2021
6bd5b76
Merge pull request #2300 from JeffreySu/Developer
JeffreySu Jan 17, 2021
610a861
Merge pull request #2301 from JeffreySu/Developer
JeffreySu Jan 18, 2021
3a5d6a0
Merge pull request #2304 from JeffreySu/Developer
JeffreySu Jan 19, 2021
6c11efe
Merge pull request #2305 from JeffreySu/Developer
JeffreySu Jan 19, 2021
16ef104
更新Sampple
JeffreySu Jan 20, 2021
69631ca
Work v3.8.102 “发送应用信息”接口添加 enable_duplicate_check、duplicate_check_int…
JeffreySu Jan 20, 2021
077a607
Merge pull request #2306 from JeffreySu/Developer
JeffreySu Jan 20, 2021
f9defc7
添加 Senparc.Weixin.TenPayV3 模块
JeffreySu Jan 23, 2021
b69b79e
添加单元测试项目 Senparc.Weixin.TenPayV3.Test
JeffreySu Jan 23, 2021
f0b66e6
TenPayDateTimeHelper.ToTenPayDateTime() 方法通过单元测试
JeffreySu Jan 23, 2021
b8b7a20
添加注释
JeffreySu Jan 27, 2021
5d10911
Senparc.Weixin v6.8.200 RegisterFuncCollection 改为 ConcurrentDictionar…
JeffreySu Jan 30, 2021
9169630
开始创建第一批TenpayV接口,先创建JSAPI基础支付接口
JeffreySu Jan 30, 2021
3ff063a
添加说明文件
JeffreySu Jan 30, 2021
9c12ac7
添加说明文件
JeffreySu Jan 30, 2021
514d625
添加 TenpayDateTime
JeffreySu Jan 30, 2021
00a816b
完善JsApi接口
JeffreySu Jan 30, 2021
8fe7f4c
修复:调用分账查询接口, 结果返回"验证签名失败"问题 #2309 感谢 @tausi0661
JeffreySu Feb 2, 2021
71e6931
Merge pull request #2310 from JeffreySu/Developer-TenpayV3
JeffreySu Feb 2, 2021
d57826a
更新注释
JeffreySu Feb 3, 2021
d73bf4a
删除多余文件
JeffreySu Feb 7, 2021
14404ad
升级 .NET 4.5 Sample 中的 SDK 包引用到最新版本
JeffreySu Feb 7, 2021
2254405
升级 .NET 4.5 Sample 中的 SDK 包引用到最新版本
JeffreySu Feb 7, 2021
f817335
更新 .NET 4.5 Sample,停用过期接口
JeffreySu Feb 7, 2021
be36fc7
Merge pull request #2312 from JeffreySu/Developer
JeffreySu Feb 8, 2021
fb8919e
Update readme.md
JeffreySu Feb 23, 2021
9f366b1
Merge pull request #2314 from JeffreySu/Developer
JeffreySu Feb 23, 2021
c286ba3
从 Azure 门户添加或更新应用服务部署工作流配置。
JeffreySu Feb 24, 2021
e2bb07d
Update master_SenparcWeixinSampleNetCore3.yml
JeffreySu Feb 24, 2021
d94b805
Update master_SenparcWeixinSampleNetCore3.yml
JeffreySu Feb 24, 2021
4eb680c
Update master_SenparcWeixinSampleNetCore3.yml
JeffreySu Feb 24, 2021
55b8292
Update master_SenparcWeixinSampleNetCore3.yml
JeffreySu Feb 24, 2021
62a0403
Update master_SenparcWeixinSampleNetCore3.yml
JeffreySu Feb 24, 2021
cc0f735
Update master_SenparcWeixinSampleNetCore3.yml
JeffreySu Feb 24, 2021
4d1e98e
Web 项目引用 TenPayV3
JeffreySu Feb 24, 2021
fe4dfc4
Merge pull request #2315 from JeffreySu/Developer-TenpayV3
JeffreySu Feb 24, 2021
1dc57be
Sample v5.611.2
JeffreySu Feb 24, 2021
0e6d9fb
Merge pull request #2316 from JeffreySu/Developer-TenpayV3
JeffreySu Feb 25, 2021
2860e69
Merge pull request #2317 from JeffreySu/Developer
JeffreySu Feb 25, 2021
23ca503
Open v4.8.200.1,添加 netstandard2.1 支持,删除 aspnetcore3_0
JeffreySu Feb 25, 2021
0fbd3c1
Merge pull request #2318 from JeffreySu/Developer-TenpayV3
JeffreySu Feb 25, 2021
93f7e99
Merge pull request #2319 from JeffreySu/Developer
JeffreySu Feb 25, 2021
b7a46b0
Update master_SenparcWeixinSampleNetCore3.yml
JeffreySu Feb 25, 2021
c9a63c5
Update master_SenparcWeixinSampleNetCore3.yml
JeffreySu Feb 25, 2021
bea2bf1
Update master_SenparcWeixinSampleNetCore3.yml
JeffreySu Feb 25, 2021
ec39bad
Update master_SenparcWeixinSampleNetCore3.yml
JeffreySu Feb 25, 2021
a3307b7
服务号订阅通知相关接口&补充小程序[获取小程序账号的类目]接口
ccccccmd Mar 2, 2021
885516e
CommonJsonSend.postFailAction公共请求失败处理抛错问题
WangDrama Mar 4, 2021
896cdb4
Work v3.8.103 添加“配置客户联系「联系我」方式”接口 #2325 感谢@mrouyuanyi
JeffreySu Mar 21, 2021
0e61401
解决冲突,合并提交
JeffreySu Mar 21, 2021
35688bf
v3.8.201 添加“配置客户联系「联系我」方式”接口 #2325
JeffreySu Mar 21, 2021
ab161b8
Merge pull request #2329 from JeffreySu/Developer
JeffreySu Mar 21, 2021
d816898
Work v3.8.202 解决且有微信消息时间返回为 null 的问题 #2331 感谢 @zxz524
JeffreySu Mar 23, 2021
fe77d8d
Sample v5.611.3
JeffreySu Mar 23, 2021
cd8ea33
Merge pull request #2332 from JeffreySu/Developer
JeffreySu Mar 23, 2021
2bf3dc1
Merge pull request #2323 from ccccccmd/Developer
JeffreySu Mar 29, 2021
0c3ede0
MP v16.11.201 服务号订阅通知相关接口&补充小程序[获取小程序账号的类目]接口 #2323 感谢 @ccccccmd
JeffreySu Mar 29, 2021
34cdfab
添加注释
JeffreySu Mar 29, 2021
5e044b3
Open v4.8.201 服务号订阅通知相关接口&补充小程序[获取小程序账号的类目]接口 #2323 感谢 @ccccccmd
JeffreySu Mar 29, 2021
14eaaf1
增加服务号订阅通知事件
ccccccmd Mar 30, 2021
80a71e2
属性值和NeuChar统一,增加单元测试
ccccccmd Mar 30, 2021
a21bb66
Merge pull request #34 from JeffreySu/master
mc7246 Mar 31, 2021
434dbfe
代小程序实现业务-提交审核接口添加UGC参数,修正截屏附件字段类型
mc7246 Mar 31, 2021
dd9d90d
升级 NeuChar,发布新版本
JeffreySu Mar 31, 2021
a79575a
merge-dev
ccccccmd Apr 2, 2021
f3f46ea
Sample v5.620.0,更新小程序最新授权接口:https://developers.weixin.qq.com/communit…
JeffreySu Apr 3, 2021
284e2f4
Merge pull request #2338 from JeffreySu/Developer
JeffreySu Apr 10, 2021
4645dcd
升级CO2NET,解决缓存问题
JeffreySu Apr 13, 2021
d4304aa
更新NeuChar,解决缓存问题
JeffreySu Apr 13, 2021
263b24a
更新版本号 https://github.com/Senparc/Senparc.CO2NET/commit/fe362a20e1856a…
JeffreySu Apr 13, 2021
b0806a4
更新Sample版本号,Cache常规测试通过 https://github.com/Senparc/Senparc.CO2NET/com…
JeffreySu Apr 13, 2021
b4b8b97
Merge pull request #2333 from ccccccmd/Developer
JeffreySu Apr 13, 2021
cc10046
合并 #2333 感谢 @ccccccmd @dupeng0811
JeffreySu Apr 13, 2021
9baa454
Merge pull request #2324 from WangDrama/master
JeffreySu Apr 13, 2021
e6be409
Merge pull request #2334 from mc7246/master
JeffreySu Apr 13, 2021
c3db66a
v6.8.400 修复 CommonJsonSend.PostFailAction 公共请求失败处理抛错问题 感谢 @WangDrama …
JeffreySu Apr 13, 2021
d38a899
Open v4.8.400 代小程序实现业务-提交审核接口添加UGC参数,修正截屏附件字段类型 #2334 感谢 @mc7246
JeffreySu Apr 13, 2021
70e6e08
Merge pull request #2340 from JeffreySu/Developer
JeffreySu Apr 13, 2021
cae0ddb
调整发布日志格式
JeffreySu Apr 21, 2021
ba3473f
WxOpen v3.10.401 升级 MessageApi.SendSubscribe() 方法参数 #2342 感谢 @niltor
JeffreySu Apr 21, 2021
9017f8e
Merge pull request #2343 from JeffreySu/Developer
JeffreySu Apr 21, 2021
d28268c
注释无效代码 #2344 感谢 @JimReal
JeffreySu Apr 23, 2021
69cd2e1
Merge pull request #2345 from JeffreySu/Developer
JeffreySu Apr 23, 2021
f8c52d8
添加 .NET 6 分支
JeffreySu Apr 23, 2021
4f18c51
删除已废弃项目
JeffreySu Apr 23, 2021
bedd1b0
更改.NET 6项目文件名
JeffreySu Apr 23, 2021
cd1ef7a
更新引用
JeffreySu Apr 24, 2021
938f6cb
更新 NET6_0
JeffreySu Apr 24, 2021
ea35883
修改 net6.0 编译结果目录
JeffreySu Apr 24, 2021
8cf9caa
升级 CO2NET,支持 .NET 6
JeffreySu Apr 24, 2021
c0206c0
CO2NET
JeffreySu Apr 24, 2021
8e50545
modify
JeffreySu Apr 24, 2021
a027db3
升级NeuChar
JeffreySu Apr 24, 2021
f823ac1
更新引用
JeffreySu Apr 24, 2021
1095810
使用命令行在 VS v16.4 中完成 Sample 运行
JeffreySu Apr 24, 2021
79d5a7b
更新 NeuChar 版本
JeffreySu Apr 24, 2021
cb31a80
Merge pull request #2347 from JeffreySu/NET6
JeffreySu Apr 24, 2021
08cd113
Sample v6.0.0-preview3
JeffreySu Apr 24, 2021
445f46b
Merge pull request #2348 from JeffreySu/NET6
JeffreySu Apr 24, 2021
6739dc4
更新Sample解决方案文件名
JeffreySu Apr 26, 2021
ad32843
Merge pull request #2349 from JeffreySu/NET6
JeffreySu Apr 26, 2021
e1a8add
升级到 .NET 6.0,更新版本号
JeffreySu Apr 27, 2021
52a9919
Merge pull request #2350 from JeffreySu/Developer
JeffreySu Apr 27, 2021
cc2494d
Sample v6.0.0.1-preview3,全面支持 .NET 6, Live Demo:https://sdk.weixin.se…
JeffreySu Apr 27, 2021
ac436f5
升级小程序Demo
JeffreySu Apr 30, 2021
43dc8e1
更新小程序
JeffreySu Apr 30, 2021
ba76d97
更新小程序Sample
JeffreySu Apr 30, 2021
67fd1b2
升级 MessageHandler 中间件,提供 IServiceProvider 参数
JeffreySu May 1, 2021
e0020c8
更新MessageHandler中间件
JeffreySu May 1, 2021
7fd40d9
更新 NeuChar 包
JeffreySu May 1, 2021
42b3ae5
更新MessageHandler中间件
JeffreySu May 1, 2021
5ead613
升级 NeuChar,采用异步方法读取请求,并传入 MessageHandler 中间件
JeffreySu May 1, 2021
271a0d9
升级Demo,测试 ServiceProvider 载入
JeffreySu May 1, 2021
bf4fc0e
Merge pull request #2353 from JeffreySu/Developer
JeffreySu May 1, 2021
0fc237d
更新Sample
JeffreySu May 1, 2021
2ddecc0
更新Sample,加入多服务器缓存测试
JeffreySu May 1, 2021
441c582
Work 发布新版本,使用新的MessageHandler中间件和基础构造函数
JeffreySu May 1, 2021
cd6bfb6
Merge pull request #2354 from JeffreySu/Developer
JeffreySu May 1, 2021
ae150d2
更新 .NET Framework 4.5 Sample,更新最新nuget包,并使用心得多服务器测试案例
JeffreySu May 1, 2021
d93842d
小程序发布新版本,支持新版本MessageHandler中间件
JeffreySu May 1, 2021
a51c852
更新 .NET Framework 4.5 Sample,更新最新nuget包,并使用心得多服务器测试案例
JeffreySu May 1, 2021
84fb21e
更新 .NET Framework 4.5 Sample,更新最新nuget包,并使用心得多服务器测试案例
JeffreySu May 1, 2021
7e1b617
Merge branch 'Developer' of https://github.com/JeffreySu/WeiXinMPSDK …
JeffreySu May 1, 2021
b860af6
更新 .NET 4.5 Sample
JeffreySu May 1, 2021
ceaf50f
更新 .NET 4.5 Sample,实现多服务器、不同 .NET 版本站点的信息同步
JeffreySu May 1, 2021
8a56b1f
Merge pull request #2355 from JeffreySu/Developer
JeffreySu May 1, 2021
e795356
update
JeffreySu May 1, 2021
37857dc
同意修改 nuget 输出目录
JeffreySu May 1, 2021
ae76399
modify
JeffreySu May 2, 2021
246cc02
modify
JeffreySu May 2, 2021
60bda61
Delete Senparc.Weixin.Sample.Net6.vs2019.sln
JeffreySu May 2, 2021
d5d0178
Merge branch 'Developer' of https://github.com/JeffreySu/WeiXinMPSDK …
JeffreySu May 2, 2021
006a73c
更新 readme,更新 Demo
JeffreySu May 2, 2021
05de662
Merge pull request #2356 from JeffreySu/Developer
JeffreySu May 2, 2021
01df20f
update readme.md
JeffreySu May 2, 2021
7853efc
update readme
JeffreySu May 2, 2021
6ba3a2f
Merge pull request #2357 from JeffreySu/Developer
JeffreySu May 2, 2021
2274215
更新项目介绍
JeffreySu May 4, 2021
fa17710
Merge pull request #2358 from JeffreySu/Developer
JeffreySu May 4, 2021
b80fb87
Work v3.9.101 添加“获取配置了客户联系功能的成员列表”接口 感谢 @JasonZhou https://gitee.com/…
JeffreySu May 4, 2021
90dfafd
Senparc.Weixin v6.9.101 修改 ReturnCode 枚举类型,添加公众号“addTemplate选用模板”接口错误代码
JeffreySu May 4, 2021
8439549
MP v16.12.101 调整"addTemplate选用模板"方法参数提交方式 #2323 感谢 @Buzy https://gite…
JeffreySu May 4, 2021
22da879
Merge pull request #2359 from JeffreySu/Developer
JeffreySu May 4, 2021
0dfeaf3
更正 .NET Core 3.1 的 Sample 项目引用
JeffreySu May 6, 2021
e157d66
Merge pull request #2360 from JeffreySu/Developer
JeffreySu May 6, 2021
e393392
Update GetExternalContactInfoBatchResult.cs
ShyUncle May 8, 2021
2fcec17
补充获取客户群详情结果字段
ccccccmd May 13, 2021
e975c11
Merge pull request #2363 from ccccccmd/Developer
JeffreySu May 13, 2021
5382eda
更新 .NET6 发布配置文件名
JeffreySu May 13, 2021
ddfff0f
Work v3.9.102 补充获取客户群详情结果字段 #2363 感谢 @ccccccmd
JeffreySu May 13, 2021
7fb9bd7
Merge pull request #2361 from ShyUncle/patch-1
JeffreySu May 13, 2021
6563197
Work v3.9.102 修复“批量获取客户详情 返回结果”参数名称 #2361 感谢 @ShyUncle
JeffreySu May 13, 2021
91b8396
Merge remote-tracking branch 'origin/master' into Developer
JeffreySu May 13, 2021
6dfffed
Merge pull request #2364 from JeffreySu/Developer
JeffreySu May 13, 2021
79dcea4
升级 .NET Core 3.1 Demo及源码引用
JeffreySu May 15, 2021
f796496
升级 Memcached 依赖库
JeffreySu May 15, 2021
b43cfee
Merge pull request #2365 from JeffreySu/Developer
JeffreySu May 15, 2021
efde94d
完善小程序Demo
JeffreySu May 20, 2021
d9d37aa
更新小程序demo
JeffreySu May 20, 2021
18c307e
NeuChar
JeffreySu May 20, 2021
519fade
更新小程序相关
JeffreySu May 20, 2021
c2c1c0b
更新NeuChar
JeffreySu May 20, 2021
3f521e4
添加 Enlightener 中的 NewRequestMessageMiniProgramPage 重写
JeffreySu May 20, 2021
2cfbd50
Sample v6.0.0.9 小程序客服接口更新
JeffreySu May 20, 2021
9eeff45
Merge pull request #2366 from JeffreySu/Developer
JeffreySu May 20, 2021
83c0365
补充企微获取客户详情接口返回值字段
ccccccmd May 25, 2021
ed5d61f
Merge pull request #2368 from ccccccmd/Developer
JeffreySu May 27, 2021
77788b2
Merge pull request #37 from JeffreySu/master
mc7246 May 28, 2021
605401a
修改完善 附近的小程序API接口
mc7246 May 28, 2021
5aae21b
更新 .NET 4.5 Sample 的引用包版本
JeffreySu May 29, 2021
bffbc53
v3.9.102.2 补充企微获取客户详情接口返回值字段 #2368 感谢 @ccccccmd
JeffreySu May 29, 2021
9fc9293
Merge pull request #2370 from mc7246/master
JeffreySu May 29, 2021
922ef94
WxOpen v3.11.100.3 修改完善“附近的小程序”接口 #2370 感谢 @mc7246
JeffreySu May 29, 2021
581b161
Merge pull request #2371 from JeffreySu/Developer
JeffreySu May 29, 2021
d646b9b
更新 .NET 4.5 Sample 的 nuget 包引用
JeffreySu May 29, 2021
8edb593
Merge branch 'Developer' of https://github.com/JeffreySu/WeiXinMPSDK …
JeffreySu May 29, 2021
0eb7759
Merge pull request #2372 from JeffreySu/Developer
JeffreySu May 29, 2021
34adb54
modify
JeffreySu May 29, 2021
4e19941
Merge pull request #2373 from JeffreySu/Developer
JeffreySu May 29, 2021
4463ea7
添加注释
JeffreySu Jun 2, 2021
1bcdabd
Merge branch 'Developer' of https://github.com/JeffreySu/WeiXinMPSDK …
JeffreySu Jun 2, 2021
cd9df50
升级 CO2NET、NeuChar 包(稳定版),发布稳定版
JeffreySu Jun 9, 2021
5ff39a8
升级 CO2NET、NeuChar 包(稳定版),发布稳定版
JeffreySu Jun 9, 2021
f669857
Merge pull request #2378 from JeffreySu/Developer
JeffreySu Jun 9, 2021
05d653d
.NET Core 3.1 项目默认不生成 nguet 包,生成操作集中到 .NET 6.
JeffreySu Jun 9, 2021
09cf020
更新 .NET Core 3.0 Demo
JeffreySu Jun 9, 2021
293e73c
1.新增外部联系人 统计管理接口
WangDrama Jun 16, 2021
da3c7b0
Merge branch 'master' of https://github.com/JeffreySu/WeiXinMPSDK
WangDrama Jun 16, 2021
2efc817
Sample v6.0.1
JeffreySu Jun 17, 2021
66e7f0e
添加CLI
JeffreySu Jun 17, 2021
33fd832
开始添加“客户标签管理”
JeffreySu Jun 17, 2021
7c5db15
添加 Senparc.Weixin.CLI 项目,提供命令行工具
JeffreySu Jun 17, 2021
31b1947
modify
JeffreySu Jun 17, 2021
b6d79a4
modify
JeffreySu Jun 17, 2021
bac18e0
更新文档下载
JeffreySu Jun 19, 2021
1c301cd
*.500 更改 IList 或 IEnumerable -> List
JeffreySu Jun 19, 2021
073002c
Merge pull request #2384 from JeffreySu/Developer
JeffreySu Jun 19, 2021
13bf5b5
*.501 更改 IList -> List
JeffreySu Jun 19, 2021
5450d7d
MP v16.12.501.1
JeffreySu Jun 19, 2021
a05f5b1
Merge pull request #2385 from JeffreySu/Developer
JeffreySu Jun 19, 2021
4d24610
更新注释
JeffreySu Jun 22, 2021
28c1f34
添加更多功能
JeffreySu Jun 24, 2021
dd4e47b
modify
JeffreySu Jun 24, 2021
7390674
modify
JeffreySu Jun 24, 2021
3f41d3c
modify
JeffreySu Jun 24, 2021
c0a932a
Merge pull request #2386 from JeffreySu/Developer
JeffreySu Jun 25, 2021
707bf8a
合并 ExternalApi 冲突
WangDrama Jun 30, 2021
29a780f
合并 提交ExternalApi
WangDrama Jun 30, 2021
257c06a
Merge pull request #2382 from WangDrama/master
JeffreySu Jun 30, 2021
6d7b532
v6.9.600 + Work v3.9.600 添加:外部联系人 - 客户群统计+联系客户+群直播+客户群事件 相关功能 #2382 感…
JeffreySu Jun 30, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
3 changes: 3 additions & 0 deletions .github/ISSUE_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@
- [ ] Senparc.Weixin.WxOpen 版本:
- [ ] Senparc.Weixin.Cache.Redis 版本:
- [ ] Senparc.Weixin.Cache.Memcached 版本:
- [ ] Senparc.Weixin.Tenpay 版本:
- [ ] Senparc.WebSocket 版本:
- [ ] 其他模块:


Expand All @@ -38,6 +40,7 @@
- [ ] .net core 1.x
- [ ] .net core 2.x
- [x] .net core 3.x
- [ ] .net 5.x / 6.x

##### 开发环境

Expand Down
55 changes: 55 additions & 0 deletions .github/workflows/master_SenparcWeixinSampleNetCore3.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
# Docs for the Azure Web Apps Deploy action: https://github.com/Azure/webapps-deploy
# More GitHub Actions for Azure: https://github.com/Azure/actions

name: Build and deploy ASP app to Azure Web App - senparcweixinsamplenetcore3(senparcweixinsamplenet5)

on:
push:
branches:
- master
workflow_dispatch:

jobs:
build-and-deploy:
runs-on: 'windows-latest'

steps:
- uses: actions/checkout@master

- name: Setup MSBuild path
uses: microsoft/setup-msbuild@v1.0.2

- name: Setup NuGet
uses: NuGet/setup-nuget@v1.0.5

- name: Set up .NET Core 2.1
uses: actions/setup-dotnet@v1
with:
dotnet-version: '2.1.807'


- name: Set up .NET Core 3.1
uses: actions/setup-dotnet@v1
with:
dotnet-version: '3.1.301'

- name: CMD1
run: dir

- name: CMD2
run: cd ./samples/netcore3.0-mvc/

- name: Restore NuGet packages
run: nuget restore
#-SolutionDirectory ./samples/netcore3.0-mvc/

- name: Publish to folder
run: msbuild /nologo /verbosity:m /t:Build /t:pipelinePreDeployCopyAllFilesToOneFolder /p:_PackageTempDir="\published\"

- name: Deploy to Azure Web App
uses: azure/webapps-deploy@v2
with:
app-name: 'senparcweixinsamplenetcore3'
slot-name: 'senparcweixinsamplenet5'
publish-profile: ${{ secrets.AzureAppService_PublishProfile_3ee3a42f0a324bf7be968d8c232a8555 }}
package: \published\
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -88,3 +88,6 @@ packages/
/Samples/netcore3.0-mvc/Senparc.Weixin.Sample.NetCore3/appsettings.Development.json
/Samples/netcore3.0-mvc/Senparc.Weixin.Sample.NetCore3/App_Data/WeChat_OfficialAccount
/Samples/netcore3.0-mvc/.idea
/Samples/net6-mvc/Senparc.Weixin.Sample.Net6/App_Data/SenparcTraceLog
/Samples/net6-mvc/Senparc.Weixin.Sample.Net6/App_Data/WeChat_OfficialAccount
/src/BuildOutPut
Original file line number Diff line number Diff line change
Expand Up @@ -35,13 +35,16 @@
using System.Threading;
using System.Threading.Tasks;
using System.Xml.Linq;
using Senparc.CO2NET.Cache;

#if NET45
using System.Web;
using System.Configuration;
using System.Web.Configuration;
using Senparc.Weixin.MP.Sample.CommonService.Utilities;
#else
using Microsoft.Extensions.DependencyInjection;
using Microsoft.AspNetCore.Http;
#endif

namespace Senparc.Weixin.MP.Sample.CommonService.CustomMessageHandler
Expand All @@ -59,7 +62,7 @@ public partial class CustomMessageHandler : MessageHandler<CustomMessageContext>
*/


#if !DEBUG || NETSTANDARD2_0 || NETCOREAPP2_0 || NETCOREAPP2_1 || NETCOREAPP2_2 || NETCOREAPP3_1
#if !DEBUG || NETSTANDARD2_0 || NETCOREAPP2_0 || NETCOREAPP2_1 || NETCOREAPP2_2 || NETCOREAPP3_1 || NET6_0
string agentUrl = "http://localhost:12222/App/Weixin/4";
string agentToken = "27C455F496044A87";
string wiweihiKey = "CNadjJuWzyX5bz5Gn+/XoyqiqMa5DjXQ";
Expand All @@ -73,20 +76,23 @@ public partial class CustomMessageHandler : MessageHandler<CustomMessageContext>
private string appId = Config.SenparcWeixinSetting.WeixinAppId;
private string appSecret = Config.SenparcWeixinSetting.WeixinAppSecret;

/// <summary>
/// 模板消息集合(Key:checkCode,Value:OpenId)
/// 注意:这里只做测试,只适用于单服务器
/// </summary>
public static Dictionary<string, string> TemplateMessageCollection = new Dictionary<string, string>();

/// <summary>
/// 为中间件提供生成当前类的委托
/// </summary>
public static Func<Stream, PostModel, int, CustomMessageHandler> GenerateMessageHandler = (stream, postModel, maxRecordCount)
=> new CustomMessageHandler(stream, postModel, maxRecordCount, false /* 是否只允许处理加密消息,以提高安全性 */);
public static Func<Stream, PostModel, int, IServiceProvider, CustomMessageHandler> GenerateMessageHandler = (stream, postModel, maxRecordCount, serviceProvider)
=> new CustomMessageHandler(stream, postModel, maxRecordCount, false /* 是否只允许处理加密消息,以提高安全性 */, serviceProvider: serviceProvider);

public CustomMessageHandler(Stream inputStream, PostModel postModel, int maxRecordCount = 0, bool onlyAllowEncryptMessage = false)
: base(inputStream, postModel, maxRecordCount, onlyAllowEncryptMessage)
/// <summary>
/// 自定义 MessageHandler
/// </summary>
/// <param name="provider">.NET Framework 可忽略</param>
/// <param name="inputStream"></param>
/// <param name="postModel"></param>
/// <param name="maxRecordCount"></param>
/// <param name="onlyAllowEncryptMessage"></param>
public CustomMessageHandler(Stream inputStream, PostModel postModel, int maxRecordCount = 0, bool onlyAllowEncryptMessage = false, IServiceProvider serviceProvider = null)
: base(inputStream, postModel, maxRecordCount, onlyAllowEncryptMessage, serviceProvider: serviceProvider)
{
//这里设置仅用于测试,实际开发可以在外部更全局的地方设置,
//比如MessageHandler<MessageContext>.GlobalGlobalMessageContext.ExpireMinutes = 3。
Expand Down Expand Up @@ -208,7 +214,7 @@ public override async Task<IResponseMessageBase> OnTextRequestAsync(RequestMessa
#if NET45
null,
#else
Senparc.CO2NET.SenparcDI.GetServiceProvider(),
Senparc.CO2NET.SenparcDI.GetServiceProvider(),
#endif
agentUrl, agentToken, agentXml);
//获取返回的XML
Expand Down Expand Up @@ -312,7 +318,13 @@ public override async Task<IResponseMessageBase> OnTextRequestAsync(RequestMessa
{
var openId = requestMessage.FromUserName;
var checkCode = Guid.NewGuid().ToString("n").Substring(0, 3);//为了防止openId泄露造成骚扰,这里启用验证码
TemplateMessageCollection[checkCode] = openId;

Task.Factory.StartNew(async () =>
{
var currentCache = CacheStrategyFactory.GetObjectCacheStrategyInstance();
await currentCache.SetAsync($"TestCheckCode:{checkCode}", openId, TimeSpan.FromHours(1));//使用缓存,如果多台服务器可以使用分布式缓存共享
}).Wait();

defaultResponseMessage.Content = string.Format(@"新的验证码为:{0},请在网页上输入。网址:https://sdk.weixin.senparc.com/AsyncMethods", checkCode);
return defaultResponseMessage;
})
Expand Down Expand Up @@ -392,6 +404,24 @@ public override async Task<IResponseMessageBase> OnTextRequestAsync(RequestMessa
defaultResponseMessage.Content = string.Format("您输入了:{0},符合正则表达式:^\\d+#\\d+$", requestMessage.Content);
return defaultResponseMessage;
})
//ServiceProvider
.Keyword("SP", () =>
{
if (base.ServiceProvider == null)
{
defaultResponseMessage.Content = "ServiceProvider 为 null";
}
else
{
#if !NET45
var httpContextAccessor = base.ServiceProvider.GetService<IHttpContextAccessor>();
defaultResponseMessage.Content = $"ServiceProvider 载入成功,从 IHttpContextAccessor 读取当前服务器协议:{httpContextAccessor.HttpContext.Request.Scheme}";
#endif
}


return defaultResponseMessage;
})

//当 Default 使用异步方法时,需要写在最后一个,且 requestMessage.StartHandler() 前需要使用 await 等待异步方法执行;
//当 Default 使用同步方法,不一定要在最后一个,并且不需要使用 await
Expand All @@ -403,7 +433,7 @@ public override async Task<IResponseMessageBase> OnTextRequestAsync(RequestMessa
var currentMessageContext = await base.GetCurrentMessageContext();
if (currentMessageContext.RequestMessages.Count > 1)
{
result.AppendFormat("您刚才还发送了如下消息({0}/{1}):\r\n", currentMessageContext.RequestMessages.Count,
result.AppendFormat("您此前还发送了如下消息({0}/{1}):\r\n", currentMessageContext.RequestMessages.Count,
currentMessageContext.StorageData);
for (int i = currentMessageContext.RequestMessages.Count - 2; i >= 0; i--)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ private string GetWelcomeInfo()
SDK Demo:https://sdk.weixin.senparc.com
源代码及Demo下载地址:https://github.com/JeffreySu/WeiXinMPSDK
Nuget地址:https://www.nuget.org/packages/Senparc.Weixin.MP
QQ群:289181996
QQ群:377815480

===============
更多:
Expand Down Expand Up @@ -96,6 +96,8 @@ private string GetWelcomeInfo()
格式:【数字#数字】,如2010#0102,调用正则表达式匹配

【订阅】 测试“一次性订阅消息”接口

【SP】 测试 ServiceProvider
",
version);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,9 @@ public override async Task OnMessageReceiced(WebSocketHelper webSocketHandler, R
keyword6 = new TemplateDataItem("400-031-8816"),
};

var tmResult = Senparc.Weixin.WxOpen.AdvancedAPIs.Template.TemplateApi.SendTemplateMessage(appId, openId, "Ap1S3tRvsB8BXsWkiILLz93nhe7S8IgAipZDfygy9Bg", data, receivedMessage.FormId, "pages/websocket/websocket", "websocket",
null);
//微信官方已停用此接口
//var tmResult = Senparc.Weixin.WxOpen.AdvancedAPIs.Template.TemplateApi.SendTemplateMessage(appId, openId, "Ap1S3tRvsB8BXsWkiILLz93nhe7S8IgAipZDfygy9Bg", data, receivedMessage.FormId, "pages/websocket/websocket", "websocket",
// null);
}
catch (Exception ex)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,12 @@ public class WorkCustomMessageHandler : WorkMessageHandler<WorkCustomMessageCont
/// <summary>
/// 为中间件提供生成当前类的委托
/// </summary>
public static Func<Stream, PostModel, int, WorkCustomMessageHandler> GenerateMessageHandler = (stream, postModel, maxRecordCount) => new WorkCustomMessageHandler(stream, postModel, maxRecordCount);
public static Func<Stream, PostModel, int, IServiceProvider, WorkCustomMessageHandler> GenerateMessageHandler =
(stream, postModel, maxRecordCount, serviceProvider) => new WorkCustomMessageHandler(stream, postModel, maxRecordCount, serviceProvider);


public WorkCustomMessageHandler(Stream inputStream, PostModel postModel, int maxRecordCount = 0)
: base(inputStream, postModel, maxRecordCount)
public WorkCustomMessageHandler(Stream inputStream, PostModel postModel, int maxRecordCount = 0, IServiceProvider serviceProvider = null)
: base(inputStream, postModel, maxRecordCount, serviceProvider: serviceProvider)
{
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using Senparc.CO2NET.Helpers;
using Senparc.CO2NET.Extensions;

#if NET45
using System.Web.Configuration;
Expand All @@ -44,11 +46,12 @@ public partial class CustomWxOpenMessageHandler : WxOpenMessageHandler<CustomWxO
/// <summary>
/// 为中间件提供生成当前类的委托
/// </summary>
public static Func<Stream, PostModel, int, CustomWxOpenMessageHandler> GenerateMessageHandler = (stream, postModel, maxRecordCount) => new CustomWxOpenMessageHandler(stream, postModel, maxRecordCount);
public static Func<Stream, PostModel, int, IServiceProvider, CustomWxOpenMessageHandler> GenerateMessageHandler =
(stream, postModel, maxRecordCount, serviceProvider) => new CustomWxOpenMessageHandler(stream, postModel, maxRecordCount, serviceProvider);


public CustomWxOpenMessageHandler(Stream inputStream, PostModel postModel, int maxRecordCount = 0)
: base(inputStream, postModel, maxRecordCount)
public CustomWxOpenMessageHandler(Stream inputStream, PostModel postModel, int maxRecordCount = 0, IServiceProvider serviceProvider = null)
: base(inputStream, postModel, maxRecordCount, serviceProvider: serviceProvider)
{
//这里设置仅用于测试,实际开发可以在外部更全局的地方设置,
//比如MessageHandler<MessageContext>.GlobalGlobalMessageContext.ExpireMinutes = 3。
Expand Down Expand Up @@ -86,8 +89,15 @@ public override async Task OnExecutingAsync(CancellationToken cancellationToken)
public override async Task OnExecutedAsync(CancellationToken cancellationToken)
{
await base.OnExecutedAsync(cancellationToken);
var currentMessageContext = await base.GetCurrentMessageContext();
currentMessageContext.StorageData = ((int)currentMessageContext.StorageData) + 1;
try
{
var currentMessageContext = await base.GetCurrentMessageContext();
currentMessageContext.StorageData = ((int)currentMessageContext.StorageData) + 1;
}
catch (Exception ex)
{
Senparc.CO2NET.Trace.SenparcTrace.SendCustomLog("小程序 OnExecutedAsync 常规跟踪(开发者请忽略)", ex.ToString());
}
}


Expand Down Expand Up @@ -205,12 +215,22 @@ public override async Task<IResponseMessageBase> OnEvent_UserEnterTempSessionReq
1、发送任意文字,返回上下文消息记录
2、发送图片,返回同样的图片
3、发送文字“link”,返回图文链接
4、发送文字“card”,发送小程序卡片";
4、发送文字“card”,发送小程序卡片
5、点击右下角出现的小程序浮窗,发送小程序页面信息";
await Senparc.Weixin.WxOpen.AdvancedAPIs.CustomApi.SendTextAsync(appId, OpenId, msg);

return await DefaultResponseMessageAsync(requestMessage);
}

public override async Task<IResponseMessageBase> OnMiniProgramPageRequestAsync(RequestMessageMiniProgramPage requestMessage)
{
var msg = $"您从某个小程序页面来到客服,并且发送了小程序卡片。\r\nTitle:{requestMessage.Title}\r\nAppId:{requestMessage.AppId.Substring(1,5)}...\r\nPagePath:{requestMessage.PagePath}\r\n附带照片:";
await Senparc.Weixin.WxOpen.AdvancedAPIs.CustomApi.SendTextAsync(appId, OpenId, msg);
await Senparc.Weixin.WxOpen.AdvancedAPIs.CustomApi.SendImageAsync(appId, OpenId, requestMessage.ThumbMediaId);
return await DefaultResponseMessageAsync(requestMessage);
}


public override IResponseMessageBase DefaultResponseMessage(IRequestMessageBase requestMessage)
{
//所有没有被处理的消息会默认返回这里的结果
Expand Down
Loading