feat: wire sse_client_cpp_core for live updates from /api/boards/issues/stream

This commit is contained in:
agent
2026-05-18 20:05:14 +02:00
parent 264c5939f3
commit 4f5e9f6fbe
16 changed files with 726 additions and 44 deletions
+8 -1
View File
@@ -8,6 +8,7 @@
#include <imgui.h>
#include <ctime>
#include <mutex>
namespace kanban_cpp {
@@ -32,6 +33,12 @@ void draw_calendar(AppState& s, bool* p_open) {
ImGui::TextDisabled("(MVP estatico — TODO: navegacion + filtros)");
ImGui::Separator();
std::vector<Card> cards_snap;
{
std::lock_guard<std::mutex> lock(s.mu);
cards_snap = s.cards;
}
// First day of current month + days in month
std::tm tm_first = tm_now;
tm_first.tm_mday = 1;
@@ -68,7 +75,7 @@ void draw_calendar(AppState& s, bool* p_open) {
ImGui::Text("%d", day);
// Count cards whose due_date falls in this day.
int hits = 0;
for (const auto& card : s.cards) {
for (const auto& card : cards_snap) {
if (card.due_date == 0) continue;
std::time_t cd = (std::time_t)card.due_date;
std::tm tmc;