diff --git a/src/api/system/oauth2/token.ts b/src/api/system/oauth2/token.ts index dc7c44f5..b7d41dcc 100644 --- a/src/api/system/oauth2/token.ts +++ b/src/api/system/oauth2/token.ts @@ -23,6 +23,6 @@ export const getAccessTokenPageApi = (params: OAuth2TokenPageReqVO) => { } // 删除 token -export const deleteAccessTokenApi = (accessToken: number) => { +export const deleteAccessTokenApi = (accessToken: string) => { return request.delete({ url: '/system/oauth2-token/delete?accessToken=' + accessToken }) } diff --git a/src/views/system/oauth2/token/index.vue b/src/views/system/oauth2/token/index.vue index f0dfbd9c..e9a41ee3 100644 --- a/src/views/system/oauth2/token/index.vue +++ b/src/views/system/oauth2/token/index.vue @@ -10,7 +10,7 @@ preIcon="ep:delete" :title="t('action.logout')" v-hasPermi="['system:oauth2-token:delete']" - @click="handleForceLogout(row.id)" + @click="handleForceLogout(row.accessToken)" /> @@ -49,11 +49,11 @@ const handleDetail = async (row: TokenApi.OAuth2TokenVO) => { } // 强退操作 -const handleForceLogout = (rowId: number) => { +const handleForceLogout = (accessToken: string) => { message .confirm('是否要强制退出用户') .then(async () => { - await TokenApi.deleteAccessTokenApi(rowId) + await TokenApi.deleteAccessTokenApi(accessToken) message.success(t('common.success')) }) .finally(async () => {