This commit is contained in:
root 2020-01-03 00:24:45 +08:00
parent c6461f0bdf
commit 54273a8f16

View File

@ -55,14 +55,12 @@ class TutorialController extends Controller
'tutorials' => $tutorial,
'safe_area_var' => [
'subscribe_url' => config('v2board.subscribe_url', config('v2board.app_url', env('APP_URL'))) . '/api/v1/client/subscribe?token=' . $user['token'],
'app_name' => config('v2board.app_name', 'V2board')
'app_name' => config('v2board.app_name', 'V2board'),
'apple_id' => $user->expired_at > time() ? config('v2board.apple_id', '管理员暂无提供AppleID信息') : '账号过期或未订阅',
'apple_id_password' => $user->expired_at > time() ? config('v2board.apple_id_password', '管理员暂无提供AppleID信息') : '账号过期或未订阅'
]
]
];
if ($user->expired_at > time()) {
$response['data']['safe_area_var']['apple_id'] = config('v2board.apple_id');
$response['data']['safe_area_var']['apple_id_password'] = config('v2board.apple_id_password');
}
return response($response);
}
}