docs(flows): DoD obligatorio con user-facing surface + abrir issues 0100-0103 (taxonomia, frontmatter migration, dev_console, work dashboard)
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
#include "tabs.h"
|
||||
#include "viz/data_table.h"
|
||||
#include "data_table/data_table.h"
|
||||
#include "core/data_table_types.h"
|
||||
#include "core/icons_tabler.h"
|
||||
#include "core/empty_state.h"
|
||||
@@ -127,7 +127,7 @@ void draw_dag_list(const std::string& api_url,
|
||||
ti.rows = static_cast<int>(dags.size());
|
||||
ti.cols = static_cast<int>(ti.headers.size());
|
||||
|
||||
// BadgeRule set: shared by Status (Badge) and Recent (Dots).
|
||||
// BadgeRule set: shared by Recent (Dots).
|
||||
auto run_status_badges = [](){
|
||||
std::vector<data_table::BadgeRule> rules;
|
||||
rules.push_back({"success", "#22c55e", ""}); // verde
|
||||
@@ -137,14 +137,24 @@ void draw_dag_list(const std::string& api_url,
|
||||
rules.push_back({"cancelled", "#6b7280", ""}); // gris
|
||||
return rules;
|
||||
};
|
||||
// ChipRule set: Status (CategoricalChip — dot izquierda + texto, siempre visible).
|
||||
auto run_status_chips = [](){
|
||||
std::vector<data_table::ChipRule> rules;
|
||||
rules.push_back({"success", "#22c55e"});
|
||||
rules.push_back({"failed", "#ef4444"});
|
||||
rules.push_back({"running", "#eab308"});
|
||||
rules.push_back({"pending", "#94a3b8"});
|
||||
rules.push_back({"cancelled", "#6b7280"});
|
||||
return rules;
|
||||
};
|
||||
|
||||
// ColumnSpec per column.
|
||||
ti.column_specs.resize(ti.cols);
|
||||
for (int i = 0; i < ti.cols; i++) ti.column_specs[i].id = ti.headers[i];
|
||||
|
||||
// idx 2 — "Status": Badge renderer for the single last-run status string.
|
||||
ti.column_specs[2].renderer = data_table::CellRenderer::Badge;
|
||||
ti.column_specs[2].badges = run_status_badges();
|
||||
// idx 2 — "Status": CategoricalChip (dot izquierda + texto, always visible).
|
||||
ti.column_specs[2].renderer = data_table::CellRenderer::CategoricalChip;
|
||||
ti.column_specs[2].chips = run_status_chips();
|
||||
|
||||
// idx 3 — "Recent": Dots renderer — each dot = one of the last 5 runs.
|
||||
ti.column_specs[3].renderer = data_table::CellRenderer::Dots;
|
||||
@@ -953,29 +963,29 @@ void draw_all_runs(const std::string& /*api_url*/,
|
||||
ti.rows = static_cast<int>(sorted.size());
|
||||
ti.cols = static_cast<int>(ti.headers.size());
|
||||
|
||||
auto status_badges = [](){
|
||||
std::vector<data_table::BadgeRule> rules;
|
||||
rules.push_back({"success", "#22c55e", ""});
|
||||
rules.push_back({"failed", "#ef4444", ""});
|
||||
rules.push_back({"running", "#eab308", ""});
|
||||
rules.push_back({"pending", "#94a3b8", ""});
|
||||
rules.push_back({"cancelled", "#6b7280", ""});
|
||||
auto status_chips = [](){
|
||||
std::vector<data_table::ChipRule> rules;
|
||||
rules.push_back({"success", "#22c55e"});
|
||||
rules.push_back({"failed", "#ef4444"});
|
||||
rules.push_back({"running", "#eab308"});
|
||||
rules.push_back({"pending", "#94a3b8"});
|
||||
rules.push_back({"cancelled", "#6b7280"});
|
||||
return rules;
|
||||
};
|
||||
auto trigger_badges = [](){
|
||||
std::vector<data_table::BadgeRule> rules;
|
||||
rules.push_back({"manual", "#3b82f6", ""});
|
||||
rules.push_back({"cron", "#a855f7", ""});
|
||||
rules.push_back({"api", "#06b6d4", ""});
|
||||
auto trigger_chips = [](){
|
||||
std::vector<data_table::ChipRule> rules;
|
||||
rules.push_back({"manual", "#3b82f6"});
|
||||
rules.push_back({"cron", "#a855f7"});
|
||||
rules.push_back({"api", "#06b6d4"});
|
||||
return rules;
|
||||
};
|
||||
|
||||
ti.column_specs.resize(ti.cols);
|
||||
for (int i = 0; i < ti.cols; i++) ti.column_specs[i].id = ti.headers[i];
|
||||
ti.column_specs[2].renderer = data_table::CellRenderer::Badge;
|
||||
ti.column_specs[2].badges = status_badges();
|
||||
ti.column_specs[3].renderer = data_table::CellRenderer::Badge;
|
||||
ti.column_specs[3].badges = trigger_badges();
|
||||
ti.column_specs[2].renderer = data_table::CellRenderer::CategoricalChip;
|
||||
ti.column_specs[2].chips = status_chips();
|
||||
ti.column_specs[3].renderer = data_table::CellRenderer::CategoricalChip;
|
||||
ti.column_specs[3].chips = trigger_chips();
|
||||
|
||||
// Helper: duracion humana entre started_at y finished_at (best-effort).
|
||||
auto duration_str = [](const std::string& s, const std::string& f) -> std::string {
|
||||
|
||||
Reference in New Issue
Block a user