mirror of
https://gitee.com/apiadmin/ApiAdmin.git
synced 2025-04-06 03:58:00 +08:00
modified 添加接口登出
This commit is contained in:
parent
53934cbacd
commit
af58f51603
@ -153,4 +153,12 @@ class Api extends Base {
|
|||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function logout() {
|
||||||
|
$ApiAuth = $this->request->header('ApiAuth');
|
||||||
|
cache('WikiLogin:' . $ApiAuth, null);
|
||||||
|
cache('WikiLogin:' . $this->appInfo['id'], null);
|
||||||
|
|
||||||
|
return $this->buildSuccess([], '登出成功');
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -20,9 +20,13 @@ Route::group('wiki', function() {
|
|||||||
'wiki/Api/groupList',
|
'wiki/Api/groupList',
|
||||||
['method' => 'get']
|
['method' => 'get']
|
||||||
],
|
],
|
||||||
'detail' => [
|
'detail' => [
|
||||||
'wiki/Api/detail',
|
'wiki/Api/detail',
|
||||||
['method' => 'get']
|
['method' => 'get']
|
||||||
|
],
|
||||||
|
'logout' => [
|
||||||
|
'wiki/Api/logout',
|
||||||
|
['method' => 'get']
|
||||||
]
|
]
|
||||||
])->middleware(['WikiAuth']);
|
])->middleware(['WikiAuth']);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user