-
Notifications
You must be signed in to change notification settings - Fork 1k
chore: 优化服务商模式小程序下单场景 #487
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
Conversation
| $config = get_wechat_config($rocket->getParams()); | ||
|
|
||
| if (Pay::MODE_SERVICE == $config->get('mode')) { | ||
| return $rocket->getPayload()->get('sub_appid') ?? $config->get('mini_app_id'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| return $rocket->getPayload()->get('sub_appid') ?? $config->get('mini_app_id'); | |
| return $rocket->getPayload()->get('sub_appid', $config->get('mini_app_id')); |
| if (Pay::MODE_SERVICE == $config->get('mode')) { | ||
| return [ | ||
| 'sp_appid' => $config->get('app_id', ''), | ||
| 'sp_appid' => $config->get('mini_app_id', '') ?: $config->get('mp_app_id', ''), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
同上
| self::assertArrayHasKey('paySign', $contents->all()); | ||
| } | ||
|
|
||
| public function testPartner() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
最好也覆盖一下 从 config 获取数据的情况
| self::assertEquals('1600314070', $payload->get('sub_mchid')); | ||
| } | ||
|
|
||
| public function testWechatIdPartnerDirect2() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
覆盖下 mini_app_id 的情况
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
优化了下,可以看看
本次优化服务商模式小程序支付,考虑3种场景
交易场景1:
交易场景2:
交易场景3: