Policies-Tab: Export/Import (Settings Catalog, Compliance, Config)
Build & Release MSI / build-msi (push) Canceled after 0s

Neuer Tab "Policies" zum Sichern und Wiederherstellen von Intune-Policies.

- Backend src/PolicyIO.ps1: typ-getrieben fuer configurationPolicies
  (Settings Catalog), deviceCompliancePolicies und deviceConfigurations
- Export als JSON-Download (einzeln/Bundle) + Server-Archiv unter %APPDATA%
- Import per Datei-Upload, immer Neuanlage (nie ueberschreiben), robust fuer
  Hashtable (PS7) und PSCustomObject (PS5.1); im Read-Only-Modus ausgeblendet
- Routen in src/Api.ps1; Config-Scope DeviceManagementConfiguration.* auch
  nach Settings-Save sichergestellt
- Frontend: Tab + View, Suche/Typ-Filter/Sortierung, Auswahl, Download/Upload
- Version 0.1.25 (Start.ps1, CHANGELOG, README)
- build-local.ps1: x64-.NET-Runtime fuer wix auf ARM64-Windows + echter
  Desktop-Pfad

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
2026-08-19 14:25:29 +02:00
co-authored by Claude Opus 4.8
parent e63ae28cb1
commit ea51bac772
9 changed files with 898 additions and 7 deletions
+48
View File
@@ -36,6 +36,7 @@
<button class="nav-tab" data-view="groups" aria-selected="false">Group Management</button>
<button class="nav-tab" data-view="report" aria-selected="false">App Report</button>
<button class="nav-tab" data-view="devices" aria-selected="false">Geräte</button>
<button class="nav-tab" data-view="policies" aria-selected="false">Policies</button>
</nav>
<div class="header-actions">
@@ -558,6 +559,53 @@
</div>
</section>
<!-- POLICIES VIEW -->
<section class="pol-view hidden" id="policiesView">
<div class="pol-toolbar">
<div class="search-wrap">
<svg class="search-ico" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><circle cx="11" cy="11" r="7"/><path d="M21 21l-4.3-4.3"/></svg>
<input type="search" id="polSearch" class="input input-search" placeholder="Policy suchen…" autocomplete="off">
</div>
<span id="polCount" class="count-badge">0</span>
<select id="polTypeFilter" class="input" style="height:34px;max-width:220px;">
<option value="">Alle Typen</option>
<option value="settingscatalog">Settings Catalog</option>
<option value="compliance">Compliance</option>
<option value="configuration">Konfigurationsprofil</option>
</select>
<span class="pol-toolbar-spacer" style="flex:1;"></span>
<button class="btn btn-secondary btn-sm" id="btnPolRefresh" title="Policies neu laden">
<svg width="13" height="13" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M21 12a9 9 0 1 1-3-6.7L21 8"/><path d="M21 3v5h-5"/></svg>
Neu laden
</button>
<button class="btn btn-secondary btn-sm pol-write" id="btnPolImport" title="Policies aus JSON-Datei(en) importieren (Neuanlage)">
<svg width="13" height="13" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"/><polyline points="17 8 12 3 7 8"/><line x1="12" y1="3" x2="12" y2="15"/></svg>
Import…
</button>
<input type="file" id="polImportFile" accept=".json,application/json" multiple style="display:none;">
<button class="btn btn-primary btn-sm" id="btnPolExport" disabled title="Ausgewählte Policies als JSON exportieren">
<svg width="13" height="13" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"/><polyline points="7 10 12 15 17 10"/><line x1="12" y1="15" x2="12" y2="3"/></svg>
Export (<span id="polSelCount">0</span>)
</button>
</div>
<div class="pol-table-wrap">
<table class="pol-table" id="polTable">
<thead>
<tr>
<th class="pol-col-check"><input type="checkbox" id="polCheckAll" title="Alle auswählen"></th>
<th class="sortable" data-col="name">Name <span class="sort-ico"></span></th>
<th class="sortable" data-col="typeLabel">Typ <span class="sort-ico"></span></th>
<th class="sortable" data-col="platform">Plattform <span class="sort-ico"></span></th>
<th class="sortable" data-col="lastModifiedDateTime">Geändert <span class="sort-ico"></span></th>
</tr>
</thead>
<tbody id="polBody">
<tr><td colspan="5" class="pol-hint">Klicke auf „Neu laden" um Policies zu laden.</td></tr>
</tbody>
</table>
</div>
</section>
<!-- MODAL: Wipe -->
<div class="modal-backdrop hidden" id="wipeModalBackdrop">
<div class="modal" style="max-width:420px;">