feat: add takeover config UI to authorization management page
- Added updateTakeoverConfig API function (PUT /api/avatar/{id}/authorizations/takeover)
- Added expandable takeover config section per auth card with toggle switch, mode selector (immediate/delayed), and delay seconds input
- Added takeover summary badge showing current config when not editing
- Styles follow existing light theme with indigo (#6366F1) accent
This commit is contained in:
@@ -299,4 +299,13 @@ export const getCurrentUser = () =>
|
||||
export const logoutUser = () =>
|
||||
request.post('/huihui/logout')
|
||||
|
||||
// 更新接管配置
|
||||
export const updateTakeoverConfig = (avatarId: string, data: {
|
||||
authorizationId: string
|
||||
takeoverEnabled: boolean
|
||||
takeoverMode?: 'immediate' | 'delayed'
|
||||
takeoverDelaySeconds?: number
|
||||
}) =>
|
||||
request.put(`/avatar/${avatarId}/authorizations/takeover`, data)
|
||||
|
||||
export default request
|
||||
|
||||
Reference in New Issue
Block a user