{ "annotations": { "list": [ { "builtIn": 1, "datasource": { "type": "grafana", "uid": "-- Grafana --" }, "enable": true, "hide": true, "iconColor": "rgba(0, 211, 255, 1)", "name": "Annotations & Alerts", "type": "dashboard" } ] }, "description": "Supervisión SHADOW de máquina física, orden Odoo, sesión Shop Floor, sincronizador y calidad temporal. Presentación operativa v0.3.6.2. No alimenta el Ledger oficial.", "editable": true, "fiscalYearStartMonth": 0, "graphTooltip": 1, "id": null, "links": [], "liveNow": false, "panels": [ { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "fieldConfig": { "defaults": { "color": { "mode": "thresholds" }, "mappings": [ { "type": "value", "options": { "0": { "text": "HEALTHY", "color": "green", "index": 0 }, "1": { "text": "WARNING", "color": "orange", "index": 1 }, "2": { "text": "CRITICAL", "color": "red", "index": 2 }, "3": { "text": "UNKNOWN", "color": "red", "index": 3 } } } ], "thresholds": { "mode": "absolute", "steps": [ { "color": "green", "value": null }, { "color": "orange", "value": 1 }, { "color": "red", "value": 2 } ] }, "unit": "short" }, "overrides": [] }, "gridPos": { "h": 4, "w": 4, "x": 0, "y": 0 }, "id": 1, "options": { "colorMode": "background", "graphMode": "none", "justifyMode": "auto", "orientation": "auto", "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" ], "fields": "", "values": false }, "showPercentChange": false, "textMode": "value", "wideLayout": true }, "pluginVersion": "11.0.0", "targets": [ { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "editorMode": "code", "format": "table", "rawQuery": true, "rawSql": "SELECT\n CASE overall_health_status\n WHEN 'HEALTHY' THEN 0\n WHEN 'WARNING' THEN 1\n WHEN 'CRITICAL' THEN 2\n ELSE 3\n END AS \"Estado\"\nFROM\n mv_reports_ucepsa_prod\n .li_shopfloor_context_health_summary_v1", "refId": "A" } ], "title": "Salud general", "type": "stat" }, { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "fieldConfig": { "defaults": { "color": { "mode": "thresholds" }, "mappings": [ { "type": "value", "options": { "0": { "text": "HEALTHY", "color": "green", "index": 0 }, "1": { "text": "DELAYED", "color": "orange", "index": 1 }, "2": { "text": "STALE", "color": "red", "index": 2 }, "3": { "text": "ERROR", "color": "red", "index": 3 }, "4": { "text": "NOT INITIALIZED", "color": "red", "index": 4 } } } ], "thresholds": { "mode": "absolute", "steps": [ { "color": "green", "value": null }, { "color": "orange", "value": 1 }, { "color": "red", "value": 2 } ] }, "unit": "short" }, "overrides": [] }, "gridPos": { "h": 4, "w": 4, "x": 4, "y": 0 }, "id": 2, "options": { "colorMode": "background", "graphMode": "none", "justifyMode": "auto", "orientation": "auto", "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" ], "fields": "", "values": false }, "showPercentChange": false, "textMode": "value", "wideLayout": true }, "pluginVersion": "11.0.0", "targets": [ { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "editorMode": "code", "format": "table", "rawQuery": true, "rawSql": "SELECT\n CASE sync_health_status\n WHEN 'HEALTHY' THEN 0\n WHEN 'DELAYED' THEN 1\n WHEN 'STALE' THEN 2\n WHEN 'ERROR' THEN 3\n WHEN 'NOT_INITIALIZED' THEN 4\n ELSE 4\n END AS \"Estado\"\nFROM\n mv_reports_ucepsa_prod\n .li_shopfloor_context_health_summary_v1", "refId": "A" } ], "title": "Sincronizador", "type": "stat" }, { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "fieldConfig": { "defaults": { "color": { "mode": "thresholds" }, "mappings": [], "thresholds": { "mode": "absolute", "steps": [ { "color": "green", "value": null }, { "color": "orange", "value": 45 }, { "color": "red", "value": 120 } ] }, "unit": "s" }, "overrides": [] }, "gridPos": { "h": 4, "w": 4, "x": 8, "y": 0 }, "id": 3, "options": { "colorMode": "value", "graphMode": "none", "justifyMode": "auto", "orientation": "auto", "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" ], "fields": "", "values": false }, "showPercentChange": false, "textMode": "value", "wideLayout": true }, "pluginVersion": "11.0.0", "targets": [ { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "editorMode": "code", "format": "table", "rawQuery": true, "rawSql": "SELECT\n seconds_since_sync_success AS \"Segundos\"\nFROM\n mv_reports_ucepsa_prod\n .li_shopfloor_context_health_summary_v1", "refId": "A" } ], "title": "Segundos desde sync", "type": "stat" }, { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "fieldConfig": { "defaults": { "color": { "mode": "thresholds" }, "mappings": [], "thresholds": { "mode": "absolute", "steps": [ { "color": "green", "value": null } ] }, "unit": "short" }, "overrides": [] }, "gridPos": { "h": 4, "w": 4, "x": 12, "y": 0 }, "id": 4, "options": { "colorMode": "value", "graphMode": "none", "justifyMode": "auto", "orientation": "auto", "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" ], "fields": "", "values": false }, "showPercentChange": false, "textMode": "value", "wideLayout": true }, "pluginVersion": "11.0.0", "targets": [ { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "editorMode": "code", "format": "table", "rawQuery": true, "rawSql": "SELECT\n open_session_count AS \"Sesiones\"\nFROM\n mv_reports_ucepsa_prod\n .li_shopfloor_context_health_summary_v1", "refId": "A" } ], "title": "Sesiones abiertas", "type": "stat" }, { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "fieldConfig": { "defaults": { "color": { "mode": "thresholds" }, "mappings": [], "thresholds": { "mode": "absolute", "steps": [ { "color": "green", "value": null }, { "color": "orange", "value": 1 } ] }, "unit": "short" }, "overrides": [] }, "gridPos": { "h": 4, "w": 4, "x": 16, "y": 0 }, "id": 5, "options": { "colorMode": "value", "graphMode": "none", "justifyMode": "auto", "orientation": "auto", "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" ], "fields": "", "values": false }, "showPercentChange": false, "textMode": "value", "wideLayout": true }, "pluginVersion": "11.0.0", "targets": [ { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "editorMode": "code", "format": "table", "rawQuery": true, "rawSql": "SELECT\n warning_incident_count AS \"Advertencias\"\nFROM\n mv_reports_ucepsa_prod\n .li_shopfloor_context_health_summary_v1", "refId": "A" } ], "title": "Advertencias", "type": "stat" }, { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "fieldConfig": { "defaults": { "color": { "mode": "thresholds" }, "mappings": [], "thresholds": { "mode": "absolute", "steps": [ { "color": "green", "value": null }, { "color": "red", "value": 1 } ] }, "unit": "short" }, "overrides": [] }, "gridPos": { "h": 4, "w": 4, "x": 20, "y": 0 }, "id": 6, "options": { "colorMode": "value", "graphMode": "none", "justifyMode": "auto", "orientation": "auto", "percentChangeColorMode": "standard", "reduceOptions": { "calcs": [ "lastNotNull" ], "fields": "", "values": false }, "showPercentChange": false, "textMode": "value", "wideLayout": true }, "pluginVersion": "11.0.0", "targets": [ { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "editorMode": "code", "format": "table", "rawQuery": true, "rawSql": "SELECT\n critical_incident_count AS \"Críticas\"\nFROM\n mv_reports_ucepsa_prod\n .li_shopfloor_context_health_summary_v1", "refId": "A" } ], "title": "Críticas", "type": "stat" }, { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "fieldConfig": { "defaults": { "color": { "mode": "thresholds" }, "custom": { "align": "auto", "cellOptions": { "type": "auto" }, "filterable": true, "inspect": false }, "mappings": [], "thresholds": { "mode": "absolute", "steps": [ { "color": "green", "value": null } ] } }, "overrides": [ { "matcher": { "id": "byName", "options": "Máquina" }, "properties": [ { "id": "custom.width", "value": 95 } ] }, { "matcher": { "id": "byName", "options": "Marcha" }, "properties": [ { "id": "custom.width", "value": 75 } ] }, { "matcher": { "id": "byName", "options": "Telemetría" }, "properties": [ { "id": "custom.width", "value": 95 } ] }, { "matcher": { "id": "byName", "options": "Orden" }, "properties": [ { "id": "custom.width", "value": 145 } ] }, { "matcher": { "id": "byName", "options": "Workorder" }, "properties": [ { "id": "custom.width", "value": 95 } ] }, { "matcher": { "id": "byName", "options": "Operario" }, "properties": [ { "id": "custom.width", "value": 235 } ] }, { "matcher": { "id": "byName", "options": "Estado" }, "properties": [ { "id": "custom.width", "value": 300 } ] }, { "matcher": { "id": "byName", "options": "Severidad" }, "properties": [ { "id": "mappings", "value": [ { "type": "value", "options": { "OK": { "text": "OK", "color": "green", "index": 0 }, "INFO": { "text": "INFO", "color": "blue", "index": 1 }, "WARNING": { "text": "WARNING", "color": "orange", "index": 2 }, "CRITICAL": { "text": "CRITICAL", "color": "red", "index": 3 } } } ] }, { "id": "custom.cellOptions", "value": { "type": "color-text" } }, { "id": "custom.width", "value": 110 } ] } ] }, "gridPos": { "h": 9, "w": 24, "x": 0, "y": 4 }, "id": 7, "options": { "cellHeight": "sm", "footer": { "countRows": false, "fields": "", "reducer": [ "sum" ], "show": false }, "showHeader": true, "sortBy": [ { "desc": false, "displayName": "Máquina" } ] }, "pluginVersion": "11.0.0", "targets": [ { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "editorMode": "code", "format": "table", "rawQuery": true, "rawSql": "SELECT\n machine_id AS \"Máquina\",\n CASE\n WHEN machine_running THEN 'Sí'\n ELSE 'No'\n END AS \"Marcha\",\n CASE\n WHEN telemetry_fresh THEN 'Sí'\n ELSE 'No'\n END AS \"Telemetría\",\n COALESCE(\n published_production_order,\n '—'\n ) AS \"Orden\",\n COALESCE(\n odoo_workorder_id::text,\n NULLIF(published_workorder_id, ''),\n '—'\n ) AS \"Workorder\",\n COALESCE(\n operator_name,\n operator_candidate_name,\n '—'\n ) AS \"Operario\",\n CASE live_context_status\n WHEN 'HEALTHY_OPEN_SESSION'\n THEN 'Produciendo con sesión Shop Floor'\n WHEN 'TEMPORARY_STOP_INSIDE_SESSION'\n THEN 'Parada dentro de sesión'\n WHEN 'RUNNING_WITHOUT_SHOPFLOOR_SESSION'\n THEN 'En marcha sin sesión Shop Floor'\n WHEN 'RUNNING_WITH_ORDER_NO_SHOPFLOOR_SESSION'\n THEN 'En marcha con orden, sin sesión'\n WHEN 'ORDER_WITHOUT_SHOPFLOOR_SESSION'\n THEN 'Orden preparada, sesión no iniciada'\n WHEN 'RUNNING_SESSION_WITHOUT_PUBLISHED_ORDER'\n THEN 'Sesión activa sin orden publicada'\n WHEN 'OPEN_SESSION_WITHOUT_PUBLISHED_ORDER'\n THEN 'Sesión abierta sin orden publicada'\n WHEN 'OPEN_SESSION_ORDER_MISMATCH'\n THEN 'Orden y sesión no coinciden'\n WHEN 'MULTIPLE_OPEN_SESSIONS'\n THEN 'Varias sesiones abiertas'\n WHEN 'OPEN_SESSION_DATA_QUALITY_ERROR'\n THEN 'Error de calidad en sesión'\n WHEN 'IDLE_NO_ACTIVE_CONTEXT'\n THEN 'Inactiva sin contexto'\n ELSE live_context_status\n END AS \"Estado\",\n CASE live_severity\n WHEN 'OK' THEN 'OK'\n WHEN 'INFO' THEN 'INFO'\n WHEN 'WARNING' THEN 'WARNING'\n WHEN 'CRITICAL' THEN 'CRITICAL'\n ELSE live_severity\n END AS \"Severidad\"\nFROM\n mv_reports_ucepsa_prod\n .li_shopfloor_machine_live_context_v1\nORDER BY machine_id", "refId": "A" } ], "title": "Estado vivo por máquina", "type": "table" }, { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "fieldConfig": { "defaults": { "custom": { "align": "auto", "cellOptions": { "type": "auto" }, "filterable": true, "inspect": false }, "mappings": [], "thresholds": { "mode": "absolute", "steps": [ { "color": "green", "value": null } ] } }, "overrides": [ { "matcher": { "id": "byName", "options": "Hora" }, "properties": [ { "id": "custom.width", "value": 175 } ] }, { "matcher": { "id": "byName", "options": "Severidad" }, "properties": [ { "id": "mappings", "value": [ { "type": "value", "options": { "WARNING": { "text": "WARNING", "color": "orange", "index": 0 }, "CRITICAL": { "text": "CRITICAL", "color": "red", "index": 1 } } } ] }, { "id": "custom.cellOptions", "value": { "type": "color-background" } }, { "id": "custom.width", "value": 110 } ] }, { "matcher": { "id": "byName", "options": "Máquina" }, "properties": [ { "id": "custom.width", "value": 95 } ] }, { "matcher": { "id": "byName", "options": "Situación" }, "properties": [ { "id": "custom.width", "value": 420 } ] }, { "matcher": { "id": "byName", "options": "Orden" }, "properties": [ { "id": "custom.width", "value": 145 } ] }, { "matcher": { "id": "byName", "options": "Operario" }, "properties": [ { "id": "custom.width", "value": 220 } ] }, { "matcher": { "id": "byName", "options": "Acción" }, "properties": [ { "id": "custom.width", "value": 520 } ] } ] }, "gridPos": { "h": 10, "w": 24, "x": 0, "y": 13 }, "id": 8, "options": { "cellHeight": "sm", "footer": { "countRows": false, "fields": "", "reducer": [ "sum" ], "show": false }, "showHeader": true, "sortBy": [] }, "pluginVersion": "11.0.0", "targets": [ { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "editorMode": "code", "format": "table", "rawQuery": true, "rawSql": "SELECT\n observed_at AS \"Hora\",\n severity AS \"Severidad\",\n COALESCE(machine_id, '—') AS \"Máquina\",\n CASE incident_code\n WHEN 'RUNNING_WITHOUT_SHOPFLOOR_SESSION'\n THEN 'Máquina en marcha sin orden ni sesión Shop Floor'\n WHEN 'RUNNING_WITH_ORDER_NO_SHOPFLOOR_SESSION'\n THEN 'Máquina en marcha con orden, pero sin sesión Shop Floor'\n WHEN 'ORDER_WITHOUT_SHOPFLOOR_SESSION'\n THEN 'Orden publicada sin sesión Shop Floor'\n WHEN 'RUNNING_SESSION_WITHOUT_PUBLISHED_ORDER'\n THEN 'Sesión abierta y máquina en marcha, pero sin orden publicada'\n WHEN 'OPEN_SESSION_WITHOUT_PUBLISHED_ORDER'\n THEN 'Sesión abierta sin orden publicada'\n WHEN 'OPEN_SESSION_ORDER_MISMATCH'\n THEN 'La orden publicada no coincide con la sesión abierta'\n WHEN 'MULTIPLE_OPEN_SESSIONS'\n THEN 'Existen varias sesiones abiertas en la misma máquina'\n WHEN 'OPEN_SESSION_DATA_QUALITY_ERROR'\n THEN 'La sesión abierta presenta un error de calidad'\n WHEN 'SHOPFLOOR_SYNC_DELAYED'\n THEN 'La sincronización Shop Floor está retrasada'\n WHEN 'SHOPFLOOR_SYNC_STALE'\n THEN 'La sincronización Shop Floor está obsoleta'\n WHEN 'SHOPFLOOR_SYNC_ERROR'\n THEN 'El sincronizador Shop Floor ha registrado un error'\n WHEN 'SHOPFLOOR_SYNC_NOT_INITIALIZED'\n THEN 'El sincronizador Shop Floor no está inicializado'\n ELSE incident_code\n END AS \"Situación\",\n COALESCE(production_order, '—') AS \"Orden\",\n COALESCE(operator_name, '—') AS \"Operario\",\n recommended_action AS \"Acción\"\nFROM\n mv_reports_ucepsa_prod\n .li_shopfloor_context_incidents_v1\nORDER BY\n CASE severity\n WHEN 'CRITICAL' THEN 1\n WHEN 'WARNING' THEN 2\n ELSE 3\n END,\n machine_id NULLS FIRST,\n incident_code", "refId": "A" } ], "title": "Incidencias activas", "type": "table" }, { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "fieldConfig": { "defaults": { "custom": { "align": "auto", "cellOptions": { "type": "auto" }, "filterable": true, "inspect": false }, "mappings": [], "thresholds": { "mode": "absolute", "steps": [ { "color": "green", "value": null } ] } }, "overrides": [ { "matcher": { "id": "byName", "options": "Máquina" }, "properties": [ { "id": "custom.width", "value": 95 } ] }, { "matcher": { "id": "byName", "options": "Orden" }, "properties": [ { "id": "custom.width", "value": 145 } ] }, { "matcher": { "id": "byName", "options": "Workorder" }, "properties": [ { "id": "custom.width", "value": 95 } ] }, { "matcher": { "id": "byName", "options": "Operario" }, "properties": [ { "id": "custom.width", "value": 235 } ] }, { "matcher": { "id": "byName", "options": "Minutos abierta" }, "properties": [ { "id": "unit", "value": "m" }, { "id": "custom.width", "value": 125 } ] }, { "matcher": { "id": "byName", "options": "Paro abierto min" }, "properties": [ { "id": "unit", "value": "m" }, { "id": "custom.width", "value": 125 } ] }, { "matcher": { "id": "byName", "options": "Estado" }, "properties": [ { "id": "custom.width", "value": 300 } ] }, { "matcher": { "id": "byName", "options": "Severidad" }, "properties": [ { "id": "mappings", "value": [ { "type": "value", "options": { "OK": { "text": "OK", "color": "green", "index": 0 }, "INFO": { "text": "INFO", "color": "blue", "index": 1 }, "WARNING": { "text": "WARNING", "color": "orange", "index": 2 }, "CRITICAL": { "text": "CRITICAL", "color": "red", "index": 3 } } } ] }, { "id": "custom.cellOptions", "value": { "type": "color-text" } }, { "id": "custom.width", "value": 110 } ] } ] }, "gridPos": { "h": 9, "w": 24, "x": 0, "y": 23 }, "id": 9, "options": { "cellHeight": "sm", "footer": { "countRows": false, "fields": "", "reducer": [ "sum" ], "show": false }, "showHeader": true, "sortBy": [] }, "pluginVersion": "11.0.0", "targets": [ { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "editorMode": "code", "format": "table", "rawQuery": true, "rawSql": "SELECT\n machine_id AS \"Máquina\",\n production_order AS \"Orden\",\n odoo_workorder_id AS \"Workorder\",\n COALESCE(\n operator_name,\n operator_candidate_name,\n '—'\n ) AS \"Operario\",\n session_started_at AS \"Inicio\",\n session_age_min AS \"Minutos abierta\",\n CASE\n WHEN machine_running THEN 'Sí'\n ELSE 'No'\n END AS \"Marcha\",\n COALESCE(\n open_stop_duration_min,\n 0\n ) AS \"Paro abierto min\",\n CASE watch_status\n WHEN 'HEALTHY_OPEN_SESSION'\n THEN 'Produciendo con sesión Shop Floor'\n WHEN 'TEMPORARY_STOP_INSIDE_SESSION'\n THEN 'Parada dentro de sesión'\n WHEN 'RUNNING_SESSION_WITHOUT_PUBLISHED_ORDER'\n THEN 'Sesión activa sin orden publicada'\n WHEN 'OPEN_SESSION_WITHOUT_PUBLISHED_ORDER'\n THEN 'Sesión abierta sin orden publicada'\n WHEN 'OPEN_SESSION_ORDER_MISMATCH'\n THEN 'Orden y sesión no coinciden'\n WHEN 'MULTIPLE_OPEN_SESSIONS'\n THEN 'Varias sesiones abiertas'\n WHEN 'OPEN_SESSION_DATA_QUALITY_ERROR'\n THEN 'Error de calidad en sesión'\n ELSE watch_status\n END AS \"Estado\",\n watch_severity AS \"Severidad\"\nFROM\n mv_reports_ucepsa_prod\n .li_shopfloor_open_session_watch_v1\nORDER BY machine_id, session_started_at", "refId": "A" } ], "title": "Sesiones abiertas", "type": "table" }, { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "fieldConfig": { "defaults": { "custom": { "align": "auto", "cellOptions": { "type": "auto" }, "filterable": true, "inspect": false }, "mappings": [], "thresholds": { "mode": "absolute", "steps": [ { "color": "green", "value": null } ] } }, "overrides": [ { "matcher": { "id": "byName", "options": "Máquina" }, "properties": [ { "id": "custom.width", "value": 95 } ] }, { "matcher": { "id": "byName", "options": "Orden" }, "properties": [ { "id": "custom.width", "value": 145 } ] }, { "matcher": { "id": "byName", "options": "Workorder" }, "properties": [ { "id": "custom.width", "value": 95 } ] }, { "matcher": { "id": "byName", "options": "Operario" }, "properties": [ { "id": "custom.width", "value": 235 } ] }, { "matcher": { "id": "byName", "options": "Calidad" }, "properties": [ { "id": "mappings", "value": [ { "type": "value", "options": { "OK": { "text": "OK", "color": "green", "index": 0 }, "WARNING": { "text": "WARNING", "color": "orange", "index": 1 }, "CRITICAL": { "text": "CRITICAL", "color": "red", "index": 2 } } } ] }, { "id": "custom.cellOptions", "value": { "type": "color-text" } }, { "id": "custom.width", "value": 100 } ] }, { "matcher": { "id": "byName", "options": "Incidencias" }, "properties": [ { "id": "custom.width", "value": 280 } ] } ] }, "gridPos": { "h": 10, "w": 24, "x": 0, "y": 32 }, "id": 10, "options": { "cellHeight": "sm", "footer": { "countRows": false, "fields": "", "reducer": [ "sum" ], "show": false }, "showHeader": true, "sortBy": [] }, "pluginVersion": "11.0.0", "targets": [ { "datasource": { "type": "postgres", "uid": "bfnbcasbm6hhca" }, "editorMode": "code", "format": "table", "rawQuery": true, "rawSql": "SELECT\n machine_id AS \"Máquina\",\n production_order AS \"Orden\",\n odoo_workorder_id AS \"Workorder\",\n CASE session_status\n WHEN 'OPEN' THEN 'Abierta'\n WHEN 'CLOSED' THEN 'Cerrada'\n WHEN 'PENDING' THEN 'Pendiente'\n ELSE session_status\n END AS \"Sesión\",\n workorder_state AS \"Estado Odoo\",\n COALESCE(\n operator_name,\n operator_candidate_name,\n '—'\n ) AS \"Operario\",\n operator_confirmation_status\n AS \"Confirmación operario\",\n quantity_confirmation_status\n AS \"Confirmación cantidad\",\n confidence AS \"Confianza\",\n dq_status AS \"Calidad\",\n COALESCE(\n NULLIF(\n array_to_string(\n issue_codes,\n ', '\n ),\n ''\n ),\n 'Sin incidencias'\n ) AS \"Incidencias\"\nFROM\n mv_reports_ucepsa_prod\n .li_shopfloor_session_data_quality_v1\nORDER BY\n CASE dq_status\n WHEN 'CRITICAL' THEN 1\n WHEN 'WARNING' THEN 2\n ELSE 3\n END,\n COALESCE(ended_at, started_at) DESC NULLS LAST,\n odoo_workorder_id DESC\nLIMIT 50", "refId": "A" } ], "title": "Calidad de sesiones", "type": "table" } ], "refresh": "5s", "schemaVersion": 42, "tags": [ "mesavault", "ucepsa", "shop-floor", "context-health", "shadow", "presentation-v0362" ], "templating": { "list": [] }, "time": { "from": "now-12h", "to": "now" }, "timepicker": {}, "timezone": "browser", "title": "MESAVAULT — UCEPSA · Salud y contexto Shop Floor", "uid": "ucepsa-shopfloor-context-health", "version": 1, "weekStart": "" }