分享参数bug

main
ztt 8 months ago
parent 28df9dcce7
commit edfb2ff3d6
  1. 3
      addons/shopro/controller/third/Wechat.php
  2. 1
      addons/shopro/listener/Commission.php

@ -36,6 +36,9 @@ class Wechat extends Common
// 微信登陆(小程序+公众号+开放平台) // 微信登陆(小程序+公众号+开放平台)
public function login() public function login()
{ {
$shareInfo = $this->request->param('shareInfo');
$shareInfo = htmlspecialchars_decode($shareInfo);
\think\Log::info('分享参数:'.$shareInfo);
$result = Db::transaction(function () { $result = Db::transaction(function () {
return $this->wechat->login(); return $this->wechat->login();
}); });

@ -21,6 +21,7 @@ class Commission
{ {
// $shareInfo = request()->param('shareInfo/a'); // $shareInfo = request()->param('shareInfo/a');
$shareInfo = request()->param('shareInfo'); $shareInfo = request()->param('shareInfo');
$shareInfo = json_decode(htmlspecialchars_decode($shareInfo), true);
\think\Log::info('分享参数:'.$shareInfo['shareId']); \think\Log::info('分享参数:'.$shareInfo['shareId']);
if ($shareInfo) { if ($shareInfo) {

Loading…
Cancel
Save