2026-05-20-14-53-31 逆向结果复核与用户管理修复

This commit is contained in:
2026-05-20 15:08:20 +08:00
parent 2a599695e9
commit fd7f3387f7
12 changed files with 886 additions and 111 deletions

View File

@@ -89,6 +89,20 @@ export const api = {
request<DicomFusionVolume>(`/api/projects/${projectId}/dicom-fusion-volume?start=${start}&end=${end}&mode=${mode}`),
getDicomInfo: (projectId: string) => request<DicomInfo>(`/api/projects/${projectId}/dicom-info`),
getUsers: () => request<UserRecord[]>('/api/users'),
createUser: (payload: { name: string; account: string; department: string; password: string }) =>
request<UserRecord>('/api/users', {
method: 'POST',
body: JSON.stringify(payload),
}),
updateUser: (userId: number, payload: { name: string; account: string; department: string; password?: string }) =>
request<UserRecord>(`/api/users/${userId}`, {
method: 'PATCH',
body: JSON.stringify(payload),
}),
deleteUser: (userId: number) =>
request<{ ok: boolean; deletedId: number }>(`/api/users/${userId}`, {
method: 'DELETE',
}),
resetDemo: () =>
request<{ ok: boolean; projects: Project[]; users: UserRecord[] }>('/api/demo/reset', {
method: 'POST',