demo seed change
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import React from 'react';
|
||||
import { Clock, Timer, CheckCircle, AlertCircle, Package, Play, Pause, X, Eye } from 'lucide-react';
|
||||
import { Clock, Timer, CheckCircle, AlertCircle, Package, Play, Pause, X, Eye, Info } from 'lucide-react';
|
||||
import { StatusCard, StatusIndicatorConfig } from '../../ui/StatusCard/StatusCard';
|
||||
import { statusColors } from '../../../styles/colors';
|
||||
import { ProductionBatchResponse, ProductionStatus, ProductionPriority } from '../../../api/types/production';
|
||||
@@ -258,6 +258,39 @@ export const ProductionStatusCard: React.FC<ProductionStatusCardProps> = ({
|
||||
metadata.push(safeText(qualityInfo, qualityInfo, 50));
|
||||
}
|
||||
|
||||
// Add reasoning information if available
|
||||
if (batch.reasoning_data) {
|
||||
const { trigger_type, trigger_description, factors, consequence, confidence_score, variance, prediction_details } = batch.reasoning_data;
|
||||
|
||||
// Add trigger information
|
||||
if (trigger_type) {
|
||||
let triggerLabel = t(`reasoning:triggers.${trigger_type.toLowerCase()}`);
|
||||
if (triggerLabel === `reasoning:triggers.${trigger_type.toLowerCase()}`) {
|
||||
triggerLabel = trigger_type;
|
||||
}
|
||||
metadata.push(`Causa: ${triggerLabel}`);
|
||||
}
|
||||
|
||||
// Add factors
|
||||
if (factors && Array.isArray(factors) && factors.length > 0) {
|
||||
const factorLabels = factors.map(factor => {
|
||||
const factorLabel = t(`reasoning:factors.${factor.toLowerCase()}`);
|
||||
return factorLabel === `reasoning:factors.${factor.toLowerCase()}` ? factor : factorLabel;
|
||||
}).join(', ');
|
||||
metadata.push(`Factores: ${factorLabels}`);
|
||||
}
|
||||
|
||||
// Add confidence score
|
||||
if (confidence_score) {
|
||||
metadata.push(`Confianza: ${confidence_score}%`);
|
||||
}
|
||||
|
||||
// Add variance information
|
||||
if (variance) {
|
||||
metadata.push(`Varianza: ${variance}%`);
|
||||
}
|
||||
}
|
||||
|
||||
if (batch.priority === ProductionPriority.URGENT) {
|
||||
metadata.push('⚡ Orden urgente');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user