refactor(studio): Automatisch aktualisieren raus aus dem Startdialog
Die Wahl war keine Startaktion, sondern eine Einstellung, die nebenbei einen Lauf auslöste. Damit stand sie neben zwei echten Alternativen und beantwortete eine andere Frage als die gestellte. Das Intervall samt Startzeit steht im Reiter Einstellungen des Falls, dort gehört es hin und dort lässt es sich auch wieder ändern. Im Startdialog bleiben zwei Alternativen, die sich wirklich ausschließen. Den Fall aus dem Netz aufbauen oder mit eigenem Material beginnen. Fünf Prüfungen halten das fest, darunter der Nachweis, dass die automatische Aktualisierung im Einstellungen-Reiter erreichbar bleibt. Cache-Buster auf 20260802d. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Dieser Commit ist enthalten in:
@@ -13,7 +13,7 @@
|
|||||||
<link rel="stylesheet" href="/static/vendor/leaflet.css">
|
<link rel="stylesheet" href="/static/vendor/leaflet.css">
|
||||||
<link rel="stylesheet" href="/static/vendor/MarkerCluster.css">
|
<link rel="stylesheet" href="/static/vendor/MarkerCluster.css">
|
||||||
<link rel="stylesheet" href="/static/vendor/MarkerCluster.Default.css">
|
<link rel="stylesheet" href="/static/vendor/MarkerCluster.Default.css">
|
||||||
<link rel="stylesheet" href="/static/css/style.css?v=20260802c">
|
<link rel="stylesheet" href="/static/css/style.css?v=20260802d">
|
||||||
<style>
|
<style>
|
||||||
/* Export Modal Radio */
|
/* Export Modal Radio */
|
||||||
.export-radio { display:flex; align-items:center; gap:10px; padding:8px 12px; cursor:pointer; border-radius:var(--radius-sm); transition:background 0.15s; border:1px solid transparent; margin-bottom:4px; }
|
.export-radio { display:flex; align-items:center; gap:10px; padding:8px 12px; cursor:pointer; border-radius:var(--radius-sm); transition:background 0.15s; border:1px solid transparent; margin-bottom:4px; }
|
||||||
@@ -858,11 +858,11 @@
|
|||||||
<script src="/static/js/i18n.js?v=20260513a"></script>
|
<script src="/static/js/i18n.js?v=20260513a"></script>
|
||||||
<script src="/static/js/api.js?v=20260725b"></script>
|
<script src="/static/js/api.js?v=20260725b"></script>
|
||||||
<script src="/static/js/ws.js?v=20260316b"></script>
|
<script src="/static/js/ws.js?v=20260316b"></script>
|
||||||
<script src="/static/js/components.js?v=20260802c"></script>
|
<script src="/static/js/components.js?v=20260802d"></script>
|
||||||
<script src="/static/js/layout.js?v=20260513f"></script>
|
<script src="/static/js/layout.js?v=20260513f"></script>
|
||||||
<script src="/static/js/pipeline.js?v=20260513d"></script>
|
<script src="/static/js/pipeline.js?v=20260513d"></script>
|
||||||
<script src="/static/js/a11y.js?v=20260725a"></script>
|
<script src="/static/js/a11y.js?v=20260725a"></script>
|
||||||
<script src="/static/js/app.js?v=20260802c"></script>
|
<script src="/static/js/app.js?v=20260802d"></script>
|
||||||
<script src="/static/js/cluster-data.js?v=20260322f"></script>
|
<script src="/static/js/cluster-data.js?v=20260322f"></script>
|
||||||
<script src="/static/js/tutorial.js?v=20260316z"></script>
|
<script src="/static/js/tutorial.js?v=20260316z"></script>
|
||||||
<script src="/static/js/chat.js?v=20260514e"></script>
|
<script src="/static/js/chat.js?v=20260514e"></script>
|
||||||
|
|||||||
@@ -354,12 +354,6 @@ const Studio = {
|
|||||||
? 'Tiefenrecherche in drei Durchläufen (Breite Erfassung, Vertiefung, Konsolidierung), danach Analyse und Faktencheck. Dauert deutlich länger als ein einzelner Lauf.'
|
? 'Tiefenrecherche in drei Durchläufen (Breite Erfassung, Vertiefung, Konsolidierung), danach Analyse und Faktencheck. Dauert deutlich länger als ein einzelner Lauf.'
|
||||||
: 'Artikel holen, Lagebild schreiben, Fakten prüfen und Orte erkennen, nacheinander. Am Ende steht ein fertiges Lagebild.';
|
: 'Artikel holen, Lagebild schreiben, Fakten prüfen und Orte erkennen, nacheinander. Am Ende steht ein fertiges Lagebild.';
|
||||||
}
|
}
|
||||||
const auto = document.getElementById('sp-auto-desc');
|
|
||||||
if (auto) {
|
|
||||||
auto.textContent = inc.refresh_mode === 'auto'
|
|
||||||
? 'Ist für diesen Fall bereits eingeschaltet - der erste Lauf startet von selbst innerhalb einer Minute.'
|
|
||||||
: `Der Fall läuft ab jetzt selbstständig (alle ${inc.refresh_interval || 15} Minuten). Der erste Lauf beginnt sofort.`;
|
|
||||||
}
|
|
||||||
this._checkSearchStatus();
|
this._checkSearchStatus();
|
||||||
},
|
},
|
||||||
|
|
||||||
@@ -398,20 +392,9 @@ const Studio = {
|
|||||||
document.getElementById('ingest-add-btn').focus();
|
document.getElementById('ingest-add-btn').focus();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (kind === 'auto') {
|
// Bleibt 'full'. Einzelne Schritte lassen sich nicht mehr starten, und
|
||||||
try {
|
// die automatische Aktualisierung ist eine Einstellung, keine Startaktion.
|
||||||
await API.updateIncident(inc.id, { refresh_mode: 'auto' });
|
// Sie steht im Reiter Einstellungen des Falls.
|
||||||
inc.refresh_mode = 'auto';
|
|
||||||
await this.loadIncidents();
|
|
||||||
UI.showToast('Automatische Aktualisierung eingeschaltet - der erste Lauf startet gleich.', 'success');
|
|
||||||
} catch (e) {
|
|
||||||
UI.showToast((e && e.message) || 'Umstellen fehlgeschlagen', 'error');
|
|
||||||
localStorage.removeItem('studio_start_' + inc.id);
|
|
||||||
panel.hidden = false;
|
|
||||||
}
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
// Bleibt 'full'. Einzelne Schritte lassen sich nicht mehr starten.
|
|
||||||
this.runStage('full');
|
this.runStage('full');
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|||||||
@@ -12,8 +12,8 @@
|
|||||||
<link rel="stylesheet" href="/static/vendor/leaflet.css">
|
<link rel="stylesheet" href="/static/vendor/leaflet.css">
|
||||||
<link rel="stylesheet" href="/static/vendor/MarkerCluster.css">
|
<link rel="stylesheet" href="/static/vendor/MarkerCluster.css">
|
||||||
<link rel="stylesheet" href="/static/vendor/MarkerCluster.Default.css">
|
<link rel="stylesheet" href="/static/vendor/MarkerCluster.Default.css">
|
||||||
<link rel="stylesheet" href="/static/css/style.css?v=20260802c">
|
<link rel="stylesheet" href="/static/css/style.css?v=20260802d">
|
||||||
<link rel="stylesheet" href="/static/css/studio.css?v=20260802c">
|
<link rel="stylesheet" href="/static/css/studio.css?v=20260802d">
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div class="studio">
|
<div class="studio">
|
||||||
@@ -208,13 +208,6 @@
|
|||||||
</span>
|
</span>
|
||||||
</button>
|
</button>
|
||||||
|
|
||||||
<button class="sp-opt" onclick="Studio.startChoice('auto')">
|
|
||||||
<span class="sp-ico"><svg xmlns="http://www.w3.org/2000/svg" width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><circle cx="12" cy="12" r="10"/><polyline points="12 6 12 12 16 14"/></svg></span>
|
|
||||||
<span class="sp-text">
|
|
||||||
<span class="sp-name">Automatisch aktualisieren</span>
|
|
||||||
<span class="sp-desc" id="sp-auto-desc">Der Fall läuft ab jetzt selbstständig im eingestellten Intervall. Der erste Lauf startet sofort.</span>
|
|
||||||
</span>
|
|
||||||
</button>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -648,9 +641,9 @@
|
|||||||
<script src="/static/js/i18n.js?v=20260513a"></script>
|
<script src="/static/js/i18n.js?v=20260513a"></script>
|
||||||
<script src="/static/js/api.js?v=20260725b"></script>
|
<script src="/static/js/api.js?v=20260725b"></script>
|
||||||
<script src="/static/js/ws.js?v=20260316b"></script>
|
<script src="/static/js/ws.js?v=20260316b"></script>
|
||||||
<script src="/static/js/components.js?v=20260802c"></script>
|
<script src="/static/js/components.js?v=20260802d"></script>
|
||||||
<script src="/static/js/a11y.js?v=20260725a"></script>
|
<script src="/static/js/a11y.js?v=20260725a"></script>
|
||||||
<script src="/static/js/ai-disclaimer.js?v=20260725a"></script>
|
<script src="/static/js/ai-disclaimer.js?v=20260725a"></script>
|
||||||
<script src="/static/js/studio.js?v=20260802c"></script>
|
<script src="/static/js/studio.js?v=20260802d"></script>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
@@ -105,6 +105,18 @@ for name, js_quelle, html_quelle in [("studio", studio_js, studio_html),
|
|||||||
if bekannt:
|
if bekannt:
|
||||||
print(f" bekannte Altlast, abgesichert: {', '.join(bekannt)}")
|
print(f" bekannte Altlast, abgesichert: {', '.join(bekannt)}")
|
||||||
|
|
||||||
|
print("\nB3) Der Startdialog bietet nur echte Startaktionen")
|
||||||
|
wahlen = re.findall(r"startChoice\('([a-z]+)'\)", studio_html)
|
||||||
|
pruefe("B3a genau zwei Alternativen", len(wahlen) == 2, wahlen)
|
||||||
|
pruefe("B3b aus dem Netz aufbauen oder mit eigenem Material",
|
||||||
|
sorted(wahlen) == ["full", "ingest"], sorted(wahlen))
|
||||||
|
pruefe("B3c die automatische Aktualisierung steht nicht mehr darin",
|
||||||
|
"auto" not in wahlen and "sp-auto-desc" not in studio_html)
|
||||||
|
pruefe("B3d und auch nicht mehr in der Logik",
|
||||||
|
"kind === 'auto'" not in studio_js)
|
||||||
|
pruefe("B3e sie ist aber im Einstellungen-Reiter erreichbar",
|
||||||
|
'id="set-refresh-mode"' in studio_html and 'value="auto"' in studio_html)
|
||||||
|
|
||||||
print("\nC) Jedes onclick zeigt auf eine vorhandene Methode")
|
print("\nC) Jedes onclick zeigt auf eine vorhandene Methode")
|
||||||
for name, html, js, praefix in [
|
for name, html, js, praefix in [
|
||||||
("studio", studio_html, studio_js, "Studio"),
|
("studio", studio_html, studio_js, "Studio"),
|
||||||
|
|||||||
In neuem Issue referenzieren
Einen Benutzer sperren