获取飞书配置
This commit is contained in:
@@ -19,6 +19,28 @@ class FeishuController
|
||||
*/
|
||||
protected $noNeedLogin = ['auth', 'send', 'show'];
|
||||
|
||||
/**
|
||||
* 获取应用信息
|
||||
* @return \support\Response
|
||||
*/
|
||||
public function getinfo(Request $request)
|
||||
{
|
||||
$config = Util::getParam($request, 'config');
|
||||
if (Util::isEmpty($config)) {
|
||||
$config = $this->config;
|
||||
}
|
||||
|
||||
// 获取凭证
|
||||
$certificate = config($config);
|
||||
$arr = [
|
||||
'app_id' => $certificate['appId'],
|
||||
'redirect_uri' => $certificate['rUrl'],
|
||||
'scope' => $certificate['scope'],
|
||||
'state' => $certificate['state'].'_'. $request->user['id']
|
||||
];
|
||||
return Util::success($arr,trans('success'));
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取飞书code
|
||||
* @return \support\Response
|
||||
|
||||
Reference in New Issue
Block a user