fix(aihr): recover stalled media processing
This commit is contained in:
@@ -75,6 +75,13 @@ export type ProcessingOverview = {
|
||||
rules: ProcessingRules;
|
||||
};
|
||||
|
||||
export type ProcessingRetryResponse = {
|
||||
itemId: number;
|
||||
batchId: string;
|
||||
fileName: string;
|
||||
status: string;
|
||||
};
|
||||
|
||||
export type LocalImportRequest = {
|
||||
directory: string;
|
||||
category: string;
|
||||
@@ -113,6 +120,14 @@ export function getProcessingOverview(): Promise<ApiResult<ProcessingOverview>>
|
||||
});
|
||||
}
|
||||
|
||||
export function retryProcessingTask(id: number): Promise<ApiResult<ProcessingRetryResponse>> {
|
||||
return request({
|
||||
url: `/api/knowledge/doc/processing-tasks/${id}/retry`,
|
||||
method: 'post',
|
||||
headers: { repeatSubmit: false }
|
||||
});
|
||||
}
|
||||
|
||||
export function importLocalKnowledgeDocs(data: LocalImportRequest): Promise<ApiResult<LocalImportResponse>> {
|
||||
return request({
|
||||
url: '/api/knowledge/doc/import-local',
|
||||
|
||||
Reference in New Issue
Block a user