EmailProviders-Settings: Input "Bezeichnung im UI" für customerEmailLabel
Das customerEmailLabel-Feld existierte im Backend (samt Update-Logik und Public-Endpoint), war aber im UI nicht erreichbar – das Label wurde immer nur aus der Domain abgeleitet. Neuer optionaler Input "Bezeichnung im UI" unter dem Domain-Hinweis. Leer = automatisch aus Domain ableiten (bisheriges Verhalten), ausgefüllt = überschreibt die Ableitung (z.B. "interne Kunden Email Adressen" als Tab-Label). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -31,6 +31,11 @@ interface ProviderFormData {
|
||||
username: string;
|
||||
password: string;
|
||||
domain: string;
|
||||
// Optional: Bezeichnung im UI. Wenn leer, wird sie aus der Domain abgeleitet
|
||||
// (z.B. "stressfrei-wechseln.de" → "Stressfrei-Wechseln"). Hier kann ein
|
||||
// freier Override gesetzt werden (z.B. "interne Kunden Email Adressen"),
|
||||
// ohne die echte Domain zu ändern.
|
||||
customerEmailLabel: string;
|
||||
defaultForwardEmail: string;
|
||||
// Verschlüsselungs-Einstellungen
|
||||
imapEncryption: MailEncryption;
|
||||
@@ -51,6 +56,7 @@ const emptyForm: ProviderFormData = {
|
||||
username: '',
|
||||
password: '',
|
||||
domain: 'stressfrei-wechseln.de',
|
||||
customerEmailLabel: '',
|
||||
defaultForwardEmail: '',
|
||||
imapEncryption: 'SSL',
|
||||
smtpEncryption: 'SSL',
|
||||
@@ -140,6 +146,7 @@ export default function EmailProviders() {
|
||||
username: config.username || '',
|
||||
password: '', // Passwort wird nicht geladen
|
||||
domain: config.domain,
|
||||
customerEmailLabel: config.customerEmailLabel || '',
|
||||
defaultForwardEmail: config.defaultForwardEmail || '',
|
||||
imapEncryption: config.imapEncryption ?? 'SSL',
|
||||
smtpEncryption: config.smtpEncryption ?? 'SSL',
|
||||
@@ -288,6 +295,7 @@ export default function EmailProviders() {
|
||||
apiKey: formData.apiKey, // Leerer String wird im Backend zu null
|
||||
username: formData.username,
|
||||
domain: formData.domain,
|
||||
customerEmailLabel: formData.customerEmailLabel.trim() || null,
|
||||
defaultForwardEmail: formData.defaultForwardEmail,
|
||||
imapEncryption: formData.imapEncryption,
|
||||
smtpEncryption: formData.smtpEncryption,
|
||||
@@ -572,6 +580,20 @@ export default function EmailProviders() {
|
||||
und als Bezeichnung im UI angezeigt ("{formData.domain ? formData.domain.split('.')[0].split('-').map(s => s.charAt(0).toUpperCase() + s.slice(1)).join('-') : 'Meine-Domain'}").
|
||||
</p>
|
||||
|
||||
<div>
|
||||
<Input
|
||||
label="Bezeichnung im UI (optional)"
|
||||
value={formData.customerEmailLabel}
|
||||
onChange={(e) => setFormData({ ...formData, customerEmailLabel: e.target.value })}
|
||||
placeholder={formData.domain ? formData.domain.split('.')[0].split('-').map(s => s.charAt(0).toUpperCase() + s.slice(1)).join('-') : 'aus Domain ableiten'}
|
||||
maxLength={60}
|
||||
/>
|
||||
<p className="text-xs text-gray-500 mt-1">
|
||||
Überschreibt die aus der Domain abgeleitete Bezeichnung – z.B.
|
||||
"interne Kunden Email Adressen". Leer lassen für Auto-Ableitung.
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<Input
|
||||
label="Standard-Weiterleitungsadresse"
|
||||
value={formData.defaultForwardEmail}
|
||||
|
||||
Reference in New Issue
Block a user