Add: Agent v2.1.2, WebSocket Live Shell, WebRTC Remote Desktop (Beta), Announcement Push
- Agent v2.1.2: WebSocket ShellService, ACK nach WS-Ankündigungen, shown_announcements Fix - Backend: shellServer.js mit WebSocket-Server (Shell + Announcement Push + RTC Signaling) - Backend: patch.controller.js Fix (command_id=0 Falsy-Bug beim Auto-Update) - Frontend: Remote Desktop Tab (WebRTC Beta) in AgentDetailPage für super_admin/admin - Frontend: PatchManagementPage auf v2.1.2 aktualisiert - WPF Notification: AllowsTransparency=False + kein DropShadowEffect (Dispatcher-Crash Fix) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -39,15 +39,38 @@ internal class Program
|
||||
|
||||
static void RunNotification(string base64Json)
|
||||
{
|
||||
const string errorLog = @"C:\ProgramData\IT Nexus Agent\notify-error.log";
|
||||
try
|
||||
{
|
||||
var json = Encoding.UTF8.GetString(Convert.FromBase64String(base64Json));
|
||||
File.AppendAllText(errorLog, $"{DateTime.Now:yyyy-MM-dd HH:mm:ss} START json={json}\n");
|
||||
|
||||
var ann = JsonConvert.DeserializeObject<Announcement>(json);
|
||||
if (ann == null) return;
|
||||
if (ann == null)
|
||||
{
|
||||
File.AppendAllText(errorLog, $"{DateTime.Now:yyyy-MM-dd HH:mm:ss} ERROR: Deserialization returned null\n");
|
||||
return;
|
||||
}
|
||||
|
||||
var app = new System.Windows.Application();
|
||||
app.Run(new NotificationWindow(ann));
|
||||
app.ShutdownMode = System.Windows.ShutdownMode.OnMainWindowClose;
|
||||
app.DispatcherUnhandledException += (s, e) =>
|
||||
{
|
||||
File.AppendAllText(errorLog, $"{DateTime.Now:yyyy-MM-dd HH:mm:ss} DISPATCHER ERROR: {e.Exception}\n");
|
||||
e.Handled = true;
|
||||
app.Shutdown();
|
||||
};
|
||||
|
||||
var win = new NotificationWindow(ann);
|
||||
win.Topmost = true;
|
||||
win.Show();
|
||||
win.Activate();
|
||||
app.Run();
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
File.AppendAllText(errorLog, $"{DateTime.Now:yyyy-MM-dd HH:mm:ss} ERROR: {ex}\n");
|
||||
}
|
||||
catch { }
|
||||
}
|
||||
|
||||
static void RunDashboard()
|
||||
|
||||
Reference in New Issue
Block a user