feat(bulk-edit): add i18n keys, error mapping, and regenerate api types
- 14 new Paraglide keys in de/en/es for the bulk-edit UI strings (selection
bar, callout, badges, save progress, retry, error)
- BULK_EDIT_TOO_MANY_IDS added to errors.ts type union and getErrorMessage()
- Regenerated api.ts now includes /api/documents/{bulk,batch-metadata,ids}
and the DocumentBulkEditDTO / BulkEditResult / DocumentBatchSummary schemas
Refs #225
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -873,5 +873,19 @@
|
|||||||
"bulk_drop_zone_label": "Dateien ablegen",
|
"bulk_drop_zone_label": "Dateien ablegen",
|
||||||
"bulk_remove_file": "Entfernen",
|
"bulk_remove_file": "Entfernen",
|
||||||
"bulk_title_single": "Neues Dokument",
|
"bulk_title_single": "Neues Dokument",
|
||||||
"bulk_title_multi": "Neue Dokumente"
|
"bulk_title_multi": "Neue Dokumente",
|
||||||
|
"bulk_edit_button": "Massenbearbeitung",
|
||||||
|
"bulk_edit_n_selected": "{count} Dokumente ausgewählt",
|
||||||
|
"bulk_edit_clear_all": "Alles aufheben",
|
||||||
|
"bulk_edit_all_x": "Alle {count} editieren",
|
||||||
|
"bulk_edit_select_document": "Dokument {title} auswählen",
|
||||||
|
"bulk_edit_hint": "Nur ausgefüllte Felder werden angewendet. Tags und Empfänger werden hinzugefügt, nicht ersetzt.",
|
||||||
|
"bulk_edit_badge_additive": "+ wird hinzugefügt",
|
||||||
|
"bulk_edit_badge_replace": "wird ersetzt",
|
||||||
|
"bulk_edit_save_progress": "Batch {done} von {total} verarbeitet",
|
||||||
|
"bulk_edit_save_partial": "{done} von {total} gespeichert",
|
||||||
|
"bulk_edit_retry": "Erneut versuchen",
|
||||||
|
"bulk_edit_title": "Massenbearbeitung",
|
||||||
|
"bulk_edit_save_button": "Anwenden",
|
||||||
|
"error_bulk_edit_too_many_ids": "Maximal 500 Dokumente pro Anfrage."
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -873,5 +873,19 @@
|
|||||||
"bulk_drop_zone_label": "Drop files here",
|
"bulk_drop_zone_label": "Drop files here",
|
||||||
"bulk_remove_file": "Remove",
|
"bulk_remove_file": "Remove",
|
||||||
"bulk_title_single": "New Document",
|
"bulk_title_single": "New Document",
|
||||||
"bulk_title_multi": "New Documents"
|
"bulk_title_multi": "New Documents",
|
||||||
|
"bulk_edit_button": "Bulk edit",
|
||||||
|
"bulk_edit_n_selected": "{count} documents selected",
|
||||||
|
"bulk_edit_clear_all": "Clear all",
|
||||||
|
"bulk_edit_all_x": "Edit all {count}",
|
||||||
|
"bulk_edit_select_document": "Select document {title}",
|
||||||
|
"bulk_edit_hint": "Only filled fields are applied. Tags and receivers are added, not replaced.",
|
||||||
|
"bulk_edit_badge_additive": "+ added",
|
||||||
|
"bulk_edit_badge_replace": "replaced",
|
||||||
|
"bulk_edit_save_progress": "Batch {done} of {total} processed",
|
||||||
|
"bulk_edit_save_partial": "{done} of {total} saved",
|
||||||
|
"bulk_edit_retry": "Retry",
|
||||||
|
"bulk_edit_title": "Bulk edit",
|
||||||
|
"bulk_edit_save_button": "Apply",
|
||||||
|
"error_bulk_edit_too_many_ids": "Maximum 500 documents per request."
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -873,5 +873,19 @@
|
|||||||
"bulk_drop_zone_label": "Soltar archivos aquí",
|
"bulk_drop_zone_label": "Soltar archivos aquí",
|
||||||
"bulk_remove_file": "Eliminar",
|
"bulk_remove_file": "Eliminar",
|
||||||
"bulk_title_single": "Nuevo Documento",
|
"bulk_title_single": "Nuevo Documento",
|
||||||
"bulk_title_multi": "Nuevos Documentos"
|
"bulk_title_multi": "Nuevos Documentos",
|
||||||
|
"bulk_edit_button": "Edición masiva",
|
||||||
|
"bulk_edit_n_selected": "{count} documentos seleccionados",
|
||||||
|
"bulk_edit_clear_all": "Limpiar todo",
|
||||||
|
"bulk_edit_all_x": "Editar los {count}",
|
||||||
|
"bulk_edit_select_document": "Seleccionar documento {title}",
|
||||||
|
"bulk_edit_hint": "Solo se aplican los campos rellenados. Las etiquetas y los destinatarios se añaden, no se reemplazan.",
|
||||||
|
"bulk_edit_badge_additive": "+ se añade",
|
||||||
|
"bulk_edit_badge_replace": "se reemplaza",
|
||||||
|
"bulk_edit_save_progress": "Lote {done} de {total} procesado",
|
||||||
|
"bulk_edit_save_partial": "{done} de {total} guardado",
|
||||||
|
"bulk_edit_retry": "Reintentar",
|
||||||
|
"bulk_edit_title": "Edición masiva",
|
||||||
|
"bulk_edit_save_button": "Aplicar",
|
||||||
|
"error_bulk_edit_too_many_ids": "Máximo 500 documentos por solicitud."
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -42,6 +42,7 @@ export type ErrorCode =
|
|||||||
| 'FORBIDDEN'
|
| 'FORBIDDEN'
|
||||||
| 'VALIDATION_ERROR'
|
| 'VALIDATION_ERROR'
|
||||||
| 'BATCH_TOO_LARGE'
|
| 'BATCH_TOO_LARGE'
|
||||||
|
| 'BULK_EDIT_TOO_MANY_IDS'
|
||||||
| 'INTERNAL_ERROR';
|
| 'INTERNAL_ERROR';
|
||||||
|
|
||||||
export interface BackendError {
|
export interface BackendError {
|
||||||
@@ -142,6 +143,8 @@ export function getErrorMessage(code: ErrorCode | string | undefined): string {
|
|||||||
return m.error_validation_error();
|
return m.error_validation_error();
|
||||||
case 'BATCH_TOO_LARGE':
|
case 'BATCH_TOO_LARGE':
|
||||||
return m.error_batch_too_large();
|
return m.error_batch_too_large();
|
||||||
|
case 'BULK_EDIT_TOO_MANY_IDS':
|
||||||
|
return m.error_bulk_edit_too_many_ids();
|
||||||
default:
|
default:
|
||||||
return m.error_internal_error();
|
return m.error_internal_error();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -484,6 +484,22 @@ export interface paths {
|
|||||||
patch?: never;
|
patch?: never;
|
||||||
trace?: never;
|
trace?: never;
|
||||||
};
|
};
|
||||||
|
"/api/documents/batch-metadata": {
|
||||||
|
parameters: {
|
||||||
|
query?: never;
|
||||||
|
header?: never;
|
||||||
|
path?: never;
|
||||||
|
cookie?: never;
|
||||||
|
};
|
||||||
|
get?: never;
|
||||||
|
put?: never;
|
||||||
|
post: operations["batchMetadata"];
|
||||||
|
delete?: never;
|
||||||
|
options?: never;
|
||||||
|
head?: never;
|
||||||
|
patch?: never;
|
||||||
|
trace?: never;
|
||||||
|
};
|
||||||
"/api/auth/reset-password": {
|
"/api/auth/reset-password": {
|
||||||
parameters: {
|
parameters: {
|
||||||
query?: never;
|
query?: never;
|
||||||
@@ -676,6 +692,22 @@ export interface paths {
|
|||||||
patch: operations["updateAnnotation"];
|
patch: operations["updateAnnotation"];
|
||||||
trace?: never;
|
trace?: never;
|
||||||
};
|
};
|
||||||
|
"/api/documents/bulk": {
|
||||||
|
parameters: {
|
||||||
|
query?: never;
|
||||||
|
header?: never;
|
||||||
|
path?: never;
|
||||||
|
cookie?: never;
|
||||||
|
};
|
||||||
|
get?: never;
|
||||||
|
put?: never;
|
||||||
|
post?: never;
|
||||||
|
delete?: never;
|
||||||
|
options?: never;
|
||||||
|
head?: never;
|
||||||
|
patch: operations["patchBulk"];
|
||||||
|
trace?: never;
|
||||||
|
};
|
||||||
"/api/users/search": {
|
"/api/users/search": {
|
||||||
parameters: {
|
parameters: {
|
||||||
query?: never;
|
query?: never;
|
||||||
@@ -1156,6 +1188,22 @@ export interface paths {
|
|||||||
patch?: never;
|
patch?: never;
|
||||||
trace?: never;
|
trace?: never;
|
||||||
};
|
};
|
||||||
|
"/api/documents/ids": {
|
||||||
|
parameters: {
|
||||||
|
query?: never;
|
||||||
|
header?: never;
|
||||||
|
path?: never;
|
||||||
|
cookie?: never;
|
||||||
|
};
|
||||||
|
get: operations["getDocumentIds"];
|
||||||
|
put?: never;
|
||||||
|
post?: never;
|
||||||
|
delete?: never;
|
||||||
|
options?: never;
|
||||||
|
head?: never;
|
||||||
|
patch?: never;
|
||||||
|
trace?: never;
|
||||||
|
};
|
||||||
"/api/documents/conversation": {
|
"/api/documents/conversation": {
|
||||||
parameters: {
|
parameters: {
|
||||||
query?: never;
|
query?: never;
|
||||||
@@ -1707,6 +1755,15 @@ export interface components {
|
|||||||
filename?: string;
|
filename?: string;
|
||||||
code?: string;
|
code?: string;
|
||||||
};
|
};
|
||||||
|
BatchMetadataRequest: {
|
||||||
|
ids: string[];
|
||||||
|
};
|
||||||
|
DocumentBatchSummary: {
|
||||||
|
/** Format: uuid */
|
||||||
|
id: string;
|
||||||
|
title: string;
|
||||||
|
pdfUrl: string;
|
||||||
|
};
|
||||||
ResetPasswordRequest: {
|
ResetPasswordRequest: {
|
||||||
token?: string;
|
token?: string;
|
||||||
newPassword?: string;
|
newPassword?: string;
|
||||||
@@ -1782,6 +1839,26 @@ export interface components {
|
|||||||
/** Format: double */
|
/** Format: double */
|
||||||
height?: number;
|
height?: number;
|
||||||
};
|
};
|
||||||
|
DocumentBulkEditDTO: {
|
||||||
|
documentIds?: string[];
|
||||||
|
tagNames?: string[];
|
||||||
|
/** Format: uuid */
|
||||||
|
senderId?: string;
|
||||||
|
receiverIds?: string[];
|
||||||
|
documentLocation?: string;
|
||||||
|
archiveBox?: string;
|
||||||
|
archiveFolder?: string;
|
||||||
|
};
|
||||||
|
BulkEditError: {
|
||||||
|
/** Format: uuid */
|
||||||
|
id: string;
|
||||||
|
message: string;
|
||||||
|
};
|
||||||
|
BulkEditResult: {
|
||||||
|
/** Format: int32 */
|
||||||
|
updated: number;
|
||||||
|
errors: components["schemas"]["BulkEditError"][];
|
||||||
|
};
|
||||||
TranscriptionWeeklyStatsDTO: {
|
TranscriptionWeeklyStatsDTO: {
|
||||||
/** Format: int64 */
|
/** Format: int64 */
|
||||||
segmentationCount: number;
|
segmentationCount: number;
|
||||||
@@ -1833,7 +1910,6 @@ export interface components {
|
|||||||
/** Format: uuid */
|
/** Format: uuid */
|
||||||
id?: string;
|
id?: string;
|
||||||
displayName?: string;
|
displayName?: string;
|
||||||
personType?: string;
|
|
||||||
firstName?: string;
|
firstName?: string;
|
||||||
lastName?: string;
|
lastName?: string;
|
||||||
/** Format: int64 */
|
/** Format: int64 */
|
||||||
@@ -1844,6 +1920,7 @@ export interface components {
|
|||||||
deathYear?: number;
|
deathYear?: number;
|
||||||
alias?: string;
|
alias?: string;
|
||||||
notes?: string;
|
notes?: string;
|
||||||
|
personType?: string;
|
||||||
};
|
};
|
||||||
SenderModel: {
|
SenderModel: {
|
||||||
/** Format: uuid */
|
/** Format: uuid */
|
||||||
@@ -3242,6 +3319,30 @@ export interface operations {
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
batchMetadata: {
|
||||||
|
parameters: {
|
||||||
|
query?: never;
|
||||||
|
header?: never;
|
||||||
|
path?: never;
|
||||||
|
cookie?: never;
|
||||||
|
};
|
||||||
|
requestBody: {
|
||||||
|
content: {
|
||||||
|
"application/json": components["schemas"]["BatchMetadataRequest"];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
responses: {
|
||||||
|
/** @description OK */
|
||||||
|
200: {
|
||||||
|
headers: {
|
||||||
|
[name: string]: unknown;
|
||||||
|
};
|
||||||
|
content: {
|
||||||
|
"*/*": components["schemas"]["DocumentBatchSummary"][];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
resetPassword: {
|
resetPassword: {
|
||||||
parameters: {
|
parameters: {
|
||||||
query?: never;
|
query?: never;
|
||||||
@@ -3578,6 +3679,30 @@ export interface operations {
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
patchBulk: {
|
||||||
|
parameters: {
|
||||||
|
query?: never;
|
||||||
|
header?: never;
|
||||||
|
path?: never;
|
||||||
|
cookie?: never;
|
||||||
|
};
|
||||||
|
requestBody: {
|
||||||
|
content: {
|
||||||
|
"application/json": components["schemas"]["DocumentBulkEditDTO"];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
responses: {
|
||||||
|
/** @description OK */
|
||||||
|
200: {
|
||||||
|
headers: {
|
||||||
|
[name: string]: unknown;
|
||||||
|
};
|
||||||
|
content: {
|
||||||
|
"*/*": components["schemas"]["BulkEditResult"];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
search: {
|
search: {
|
||||||
parameters: {
|
parameters: {
|
||||||
query?: {
|
query?: {
|
||||||
@@ -4244,6 +4369,36 @@ export interface operations {
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
getDocumentIds: {
|
||||||
|
parameters: {
|
||||||
|
query?: {
|
||||||
|
q?: string;
|
||||||
|
from?: string;
|
||||||
|
to?: string;
|
||||||
|
senderId?: string;
|
||||||
|
receiverId?: string;
|
||||||
|
tag?: string[];
|
||||||
|
tagQ?: string;
|
||||||
|
status?: "PLACEHOLDER" | "UPLOADED" | "TRANSCRIBED" | "REVIEWED" | "ARCHIVED";
|
||||||
|
tagOp?: string;
|
||||||
|
};
|
||||||
|
header?: never;
|
||||||
|
path?: never;
|
||||||
|
cookie?: never;
|
||||||
|
};
|
||||||
|
requestBody?: never;
|
||||||
|
responses: {
|
||||||
|
/** @description OK */
|
||||||
|
200: {
|
||||||
|
headers: {
|
||||||
|
[name: string]: unknown;
|
||||||
|
};
|
||||||
|
content: {
|
||||||
|
"*/*": string[];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
getConversation: {
|
getConversation: {
|
||||||
parameters: {
|
parameters: {
|
||||||
query: {
|
query: {
|
||||||
|
|||||||
Reference in New Issue
Block a user