|
@@ -49,7 +49,6 @@ class AuthController extends Controller
|
|
];
|
|
];
|
|
$app = Factory::officialAccount($config);
|
|
$app = Factory::officialAccount($config);
|
|
$oauth = $app->oauth;
|
|
$oauth = $app->oauth;
|
|
-// 获取 OAuth 授权结果用户信息
|
|
|
|
$user = $oauth->user()->toArray();
|
|
$user = $oauth->user()->toArray();
|
|
$check_user = AlbumUserModel::where([['store_id',$store_id],['wechat_union_id',$user['original']['unionid']]])->first();
|
|
$check_user = AlbumUserModel::where([['store_id',$store_id],['wechat_union_id',$user['original']['unionid']]])->first();
|
|
if ($check_user) {
|
|
if ($check_user) {
|
|
@@ -80,9 +79,6 @@ class AuthController extends Controller
|
|
];
|
|
];
|
|
|
|
|
|
$app = Factory::officialAccount($config);
|
|
$app = Factory::officialAccount($config);
|
|
- \Log::info(111);
|
|
|
|
- //
|
|
|
|
- //如果有$echoStr说明是对接
|
|
|
|
if (isset($_GET["echostr"])) {
|
|
if (isset($_GET["echostr"])) {
|
|
$echoStr = $_GET["echostr"];
|
|
$echoStr = $_GET["echostr"];
|
|
//对接规则
|
|
//对接规则
|
|
@@ -101,8 +97,6 @@ class AuthController extends Controller
|
|
exit;
|
|
exit;
|
|
}
|
|
}
|
|
} else {
|
|
} else {
|
|
- // \Log::info($GLOBALS);
|
|
|
|
- \Log::info(file_get_contents("php://input"));
|
|
|
|
$postStr = file_get_contents("php://input");
|
|
$postStr = file_get_contents("php://input");
|
|
if (!empty($postStr)) {
|
|
if (!empty($postStr)) {
|
|
$postObj = simplexml_load_string($postStr, 'SimpleXMLElement', LIBXML_NOCDATA);
|
|
$postObj = simplexml_load_string($postStr, 'SimpleXMLElement', LIBXML_NOCDATA);
|
|
@@ -145,7 +139,6 @@ class AuthController extends Controller
|
|
} else {
|
|
} else {
|
|
$contentStr = "绑定失败";
|
|
$contentStr = "绑定失败";
|
|
}
|
|
}
|
|
- \Log::info($user);
|
|
|
|
} else {
|
|
} else {
|
|
$contentStr = "回复 绑定 即可绑定用户";
|
|
$contentStr = "回复 绑定 即可绑定用户";
|
|
}
|
|
}
|
|
@@ -190,9 +183,4 @@ class AuthController extends Controller
|
|
{
|
|
{
|
|
return view('welcome');
|
|
return view('welcome');
|
|
}
|
|
}
|
|
-
|
|
|
|
-
|
|
|
|
-
|
|
|
|
-
|
|
|
|
-
|
|
|
|
}
|
|
}
|