feat: Add Telegram bot integration and task detail/delete UI
- Wire up Telegram bot with token, allowed users and username from .env - Fix TaskBeat to handle direct tasks (Telegram/email) without sub_tasks - Fix send_telegram_message to use run_coroutine_threadsafe (avoid event loop clash) - Add TaskBeat watchdog thread for auto-restart on crash - Reset stuck in_progress tasks on startup - Add task detail page (/tasks/<id>) with full response/log view and auto-refresh - Add task delete route (/tasks/delete/<id>) with confirmation - Include agent sender info in Telegram task prompts - Orchestrator self-updated knowledge base with Telegram contact info
This commit is contained in:
parent
5b4b698064
commit
99df910497
4 changed files with 237 additions and 34 deletions
|
|
@ -25,7 +25,7 @@
|
|||
<th>Agent</th>
|
||||
<th>Status</th>
|
||||
<th>Erstellt</th>
|
||||
<th>Aktion</th>
|
||||
<th>Aktionen</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
|
@ -66,16 +66,11 @@
|
|||
{% endif %}
|
||||
</td>
|
||||
<td style="color:var(--text-muted);font-size:.75rem;">{{ task.created }}</td>
|
||||
<td>
|
||||
{% if task.status == 'pending' %}
|
||||
<span style="color:var(--text-muted);font-size:.75rem;">⏳ Wartend</span>
|
||||
{% elif task.status == 'in_progress' %}
|
||||
<span style="color:var(--info);font-size:.75rem;">🔄 Läuft...</span>
|
||||
{% elif task.status == 'completed' %}
|
||||
<span style="color:var(--success);font-size:.75rem;">✓ Auto</span>
|
||||
{% else %}
|
||||
<span style="color:var(--text-muted);font-size:.75rem;">—</span>
|
||||
{% endif %}
|
||||
<td class="d-flex gap-2 align-items-center flex-wrap">
|
||||
<a href="{{ url_for('task_detail', task_id=task.id) }}" class="btn btn-sm btn-outline-secondary" title="Details">Details</a>
|
||||
<form method="POST" action="{{ url_for('delete_task', task_id=task.id) }}" onsubmit="return confirm('Task #{{ task.id }} wirklich löschen?')" style="display:inline;">
|
||||
<button type="submit" class="btn btn-sm btn-outline-danger" title="Löschen">Löschen</button>
|
||||
</form>
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue