fix: IMAP-Konto bearbeiten + Löschen auch bei sync_running
- Store: UpdateCredentials() — Zugangsdaten + Passwort neu verschlüsseln,
setzt status='idle', error_msg='', sync_running=false zurück
- Handler: PATCH /api/imap/{id} unterstützt nun Credential-Update
(name/host/username vorhanden = Credential-Update, sonst sync_interval)
- Frontend: "Bearbeiten"-Button öffnet Edit-Dialog mit allen Feldern;
Passwort-Feld leer = unverändertes Passwort
- Frontend: Löschen-Button nicht mehr durch sync_running blockiert
(nur noch bei status=running gesperrt)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -392,6 +392,16 @@ export async function updateImapInterval(id: number, intervalMin: number): Promi
|
||||
});
|
||||
}
|
||||
|
||||
export async function updateImapAccount(
|
||||
id: number,
|
||||
data: { name: string; host: string; port: number; tls: string; username: string; password?: string }
|
||||
): Promise<ImapAccount> {
|
||||
return request<ImapAccount>(`/api/imap/${id}`, {
|
||||
method: "PATCH",
|
||||
body: JSON.stringify(data),
|
||||
});
|
||||
}
|
||||
|
||||
// ── POP3 ──────────────────────────────────────────────────────────────────
|
||||
|
||||
export interface Pop3Account {
|
||||
|
||||
Reference in New Issue
Block a user