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

Question: 请问对于微信子商户支付,除了要在Options参数中额外提供SubAppId和SubMchId应当如何使用呢? #67

Closed
Anduin2017 opened this issue Apr 2, 2020 · 5 comments
Labels

Comments

@Anduin2017
Copy link

Question: 请问对于微信子商户支付,除了要在Options参数中额外提供SubAppId和SubMchId应当如何使用呢?

现在我的使用方法是:

https://github.com/essensoft/payment/blob/015d4a58814c2ac5212a361bbc384d0afb80f841/samples/WebApplicationSample/Controllers/WeChatPayController.cs#L165

对于这里的Value,额外给其赋值子商户Appid和商户Id。看起来似乎没问题。但是这样是正确的使用方法吗?

App端的开发人员说,他们收到的签名是错误的。

@roc916
Copy link
Contributor

roc916 commented Apr 2, 2020

具体的可以看一下微信的开发文档:https://pay.weixin.qq.com/wiki/doc/api/app/app_sl.php?chapter=8_5

@Anduin2017
Copy link
Author

好的。明白了。我们自己试试改改。

不过,我建议保持此issue open,直到完全支持子商户支付。

@roc916
Copy link
Contributor

roc916 commented Apr 2, 2020

我又翻了下微信文档:https://pay.weixin.qq.com/wiki/doc/api/app/app_sl.php?chapter=8_3

服务商后台主要交互说明:

1.接收到下单请求后,服务商系统调用微信支付【统一下单API】,微信返回prepay_id等参数,如图步骤2-4所示。

2.服务商系统获取到prepay_id后,按照【调起支付API】列表中的参数进行签名(服务商开发注意,appid和partnerid都不是服务商的参数,appid是子商户的应用APPID,partnerid是子商户的商户号),将数据返回给商户APP端,如图中步骤5-6所示。

似乎是在服务端做的,我尝试实现下

@roc916
Copy link
Contributor

roc916 commented Apr 2, 2020

nuget 已发布 3.1.5-beta.1,如果方便 希望能协助测试下

@roc916 roc916 added the bug label Apr 2, 2020
@roc916 roc916 closed this as completed Apr 2, 2020
@Anduin2017
Copy link
Author

试了一下,完全没毛病! 💯 非常棒! 👍👍👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants