Offboarding: Autopilot-Geräte mitdurchsuchen

Die Offboarding-Suche fand bisher nur managedDevices (Intune). Reine
Autopilot-Geräte (registriert, aber nicht/nicht mehr in Intune enrolled)
tauchten nie auf. Jetzt wird zusätzlich windowsAutopilotDeviceIdentities
durchsucht (Serial: contains(serialNumber), Name: startswith(displayName),
Fehler still ignoriert) und die Treffer werden — dedupliziert per Serial/
Autopilot-Id — gemergt. Für Autopilot-only-Treffer wird das Entra-Objekt per
azureAdDeviceId nachgeladen. offKey nutzt jetzt eine Fallback-Kette, da
Autopilot-only-Geräte keine intuneDeviceId haben.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
2026-09-16 11:21:24 +02:00
co-authored by Claude Opus 4.8
parent 0f8fc7b159
commit a78c29744e
2 changed files with 90 additions and 3 deletions
+3 -1
View File
@@ -7077,7 +7077,9 @@ document.querySelectorAll('#polTable th.sortable').forEach(th => {
// OFFBOARDING: Geräte aus Intune / Autopilot / Entra entfernen
// =============================================================
const OffState = { items: [], selected: new Set(), pending: [] };
function offKey(d) { return d.intuneDeviceId; }
// Eindeutiger Zeilen-Key: Intune-Geräte haben eine intuneDeviceId, reine
// Autopilot-Geräte nicht -> auf Autopilot-/Entra-Id bzw. Seriennummer ausweichen.
function offKey(d) { return d.intuneDeviceId || d.autopilotId || d.azureADDeviceId || d.entraObjectId || d.serialNumber || ''; }
function offSelectedDevices() { return OffState.items.filter(d => OffState.selected.has(offKey(d))); }
async function offSearch() {