feat(0035d): doble click en Group abre tableview filtrado por group_id

- entity_ops: EntityRowSnapshot.group_id + SQL con COALESCE(group_id,'')
  + deteccion via PRAGMA para BDs viejas sin la columna.
- views.h: TableRow.group_id + AppState.table_filter_group_id /
  table_filter_group_name (RAM-only).
- main.cpp: dispatch en want_open_note — si type_ref == "Group", setea
  filtro de grupo + abre panel Table en vez de Note. Reset de search
  buf y col_filters al entrar al drill-in para que el usuario vea todo
  el contenido del grupo.
- views.cpp: build_visible compone group_id con search/tabs/col_filters
  (AND). types_present se reduce a tipos presentes en el grupo cuando
  hay drill-in activo. Header pintado en amarillo con TI_FOLDER +
  contador + boton "Clear group filter". Al cerrarse el panel se
  limpia el filtro automaticamente.

Tests: pytest 35 passed (WSL) / 24 passed + 11 skipped (Windows).

Refs: issues/0035d-tableview-drill-in.md
This commit is contained in:
2026-05-03 14:57:20 +02:00
parent eff273a2d4
commit b67da92e18
5 changed files with 99 additions and 8 deletions
+7
View File
@@ -210,6 +210,7 @@ struct AppState {
std::string type_ref;
std::string status;
std::string updated_at;
std::string group_id; // si pertenece a un Group, su sql id; "" si no
int neighbors = 0;
int node_idx = -1;
};
@@ -225,6 +226,12 @@ struct AppState {
std::unordered_map<int, std::string> table_col_filters;
char table_filter_input[96] = {}; // buffer del popup activo
int table_filter_pending_col = -1; // col_user_id en edicion
// Drill-in por grupo (issue 0035d): cuando esta seteado, la tabla solo
// muestra filas cuyo `group_id` coincida. Header muestra "Group: <name>
// (N)" + boton "Clear group filter". RAM-only — al cerrar el panel se
// limpia.
std::string table_filter_group_id; // "" = sin filtro
std::string table_filter_group_name; // label legible
// ---- Type Editor (issue 0007) ------------------------------------------
// Draft del editor de tipos. Se inicializa con una copia de parsed_types