|
|
@ -212,7 +212,7 @@ class HomeController extends BaseController |
|
|
$data['block'] = $this->userCenterBlockService->all($roles); |
|
|
$data['block'] = $this->userCenterBlockService->all($roles); |
|
|
|
|
|
|
|
|
// 返回用户是否已经关注公众号和查看时候跳转的文章地址
|
|
|
// 返回用户是否已经关注公众号和查看时候跳转的文章地址
|
|
|
if ($params['user_id'] == '207') { |
|
|
|
|
|
|
|
|
try { |
|
|
$config = config('wechat.official'); |
|
|
$config = config('wechat.official'); |
|
|
$app = Factory::officialAccount(['app_id' => $config['app_id'], 'secret' => $config['app_secret']]); |
|
|
$app = Factory::officialAccount(['app_id' => $config['app_id'], 'secret' => $config['app_secret']]); |
|
|
$app['guzzle_handler'] = CoroutineHandler::class; |
|
|
$app['guzzle_handler'] = CoroutineHandler::class; |
|
|
@ -238,6 +238,8 @@ class HomeController extends BaseController |
|
|
|
|
|
|
|
|
$subscribeInfo = !empty($subscribeInfo) ? json_decode($subscribeInfo, true) : []; |
|
|
$subscribeInfo = !empty($subscribeInfo) ? json_decode($subscribeInfo, true) : []; |
|
|
$data['subscribe_info'] = array_merge($fansInfo, $subscribeInfo); |
|
|
$data['subscribe_info'] = array_merge($fansInfo, $subscribeInfo); |
|
|
|
|
|
} catch (\Exception $e) { |
|
|
|
|
|
$data['subscribe_info'] = (object)[]; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
return $this->success($data); |
|
|
return $this->success($data); |
|
|
|