From e55595be5fae727ebc07dda5a13bc8610da8f42f Mon Sep 17 00:00:00 2001 From: inter Date: Mon, 8 Sep 2025 16:36:28 +0800 Subject: [PATCH] Add File --- frontend/src/api/assistant.ts | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 frontend/src/api/assistant.ts diff --git a/frontend/src/api/assistant.ts b/frontend/src/api/assistant.ts new file mode 100644 index 0000000..bb955e0 --- /dev/null +++ b/frontend/src/api/assistant.ts @@ -0,0 +1,11 @@ +import { request } from '@/utils/request' + +export const assistantApi = { + queryAll: (keyword?: string) => + request.get('/system/assistant', { params: keyword ? { keyword } : {} }), + add: (data: any) => request.post('/system/assistant', data), + edit: (data: any) => request.put('/system/assistant', data), + delete: (id: number) => request.delete(`/system/assistant/${id}`), + query: (id: number) => request.get(`/system/assistant/${id}`), + validate: (data: any) => request.get('/system/assistant/validator', { params: data }), +}