Abteilungs-Präfixe und RPA-Gruppen optional
Beide Felder sind nicht mehr pflichtmäßig in der Validierung. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
+1
-6
@@ -229,15 +229,10 @@ function Get-SettingsValidationErrors {
|
|||||||
$errs += "Mindestens ein Scope erforderlich."
|
$errs += "Mindestens ein Scope erforderlich."
|
||||||
}
|
}
|
||||||
$deptPrefixes = Get-DepartmentPrefixes -Settings $S
|
$deptPrefixes = Get-DepartmentPrefixes -Settings $S
|
||||||
if ($deptPrefixes.Count -eq 0) {
|
if ($deptPrefixes.Count -gt 0) {
|
||||||
$errs += "Mindestens ein Abteilungs-Praefix erforderlich."
|
|
||||||
} else {
|
|
||||||
$bad = @($deptPrefixes | Where-Object { $_.Trim().Length -lt 2 })
|
$bad = @($deptPrefixes | Where-Object { $_.Trim().Length -lt 2 })
|
||||||
if ($bad.Count -gt 0) { $errs += "Abteilungs-Praefixe muessen jeweils mindestens 2 Zeichen lang sein." }
|
if ($bad.Count -gt 0) { $errs += "Abteilungs-Praefixe muessen jeweils mindestens 2 Zeichen lang sein." }
|
||||||
}
|
}
|
||||||
if (-not $S.rpa.groupNames -or @($S.rpa.groupNames).Count -eq 0) {
|
|
||||||
$errs += "Mindestens eine RPA-Gruppe erforderlich."
|
|
||||||
}
|
|
||||||
$allowedUserFields = @('displayName','userPrincipalName','mail','department')
|
$allowedUserFields = @('displayName','userPrincipalName','mail','department')
|
||||||
$bad = @($S.userSearch.fields | Where-Object { $_ -notin $allowedUserFields })
|
$bad = @($S.userSearch.fields | Where-Object { $_ -notin $allowedUserFields })
|
||||||
if ($bad.Count -gt 0) { $errs += "Unbekannte User-Search-Felder: $($bad -join ', ')" }
|
if ($bad.Count -gt 0) { $errs += "Unbekannte User-Search-Felder: $($bad -join ', ')" }
|
||||||
|
|||||||
Reference in New Issue
Block a user