diff --git a/frontend/src/components/LoaderModal.js b/frontend/src/components/LoaderModal.js index 58fbf5a..cbe23ca 100644 --- a/frontend/src/components/LoaderModal.js +++ b/frontend/src/components/LoaderModal.js @@ -94,12 +94,16 @@ export default function LoaderModal({ isOpen, onClose, initialDevices }) { setValidationWarnings([]); }, [isOpen, initialDevices]); - // Auto-select required columns when operation type changes + // Auto-select required columns + useful defaults when operation type changes useEffect(() => { const required = getRequiredColumns(operationType); setSelectedColumns(prev => { const next = new Set(prev); required.forEach(id => next.add(id)); + // Always include these useful columns by default + next.add('IPV4_ADDRESS'); + next.add('EQUIP_NAME'); + next.add('RESPONSIBLE_TEAM'); return next; }); }, [operationType]); diff --git a/frontend/src/components/pages/ReportingPage.js b/frontend/src/components/pages/ReportingPage.js index f4a7e17..1952dcb 100644 --- a/frontend/src/components/pages/ReportingPage.js +++ b/frontend/src/components/pages/ReportingPage.js @@ -1669,7 +1669,8 @@ function QueuePanel({ open, items, onClose, onUpdate, onDelete, onDeleteMany, on }); const data = await res.json(); if (!res.ok) { - setCardActionError(data.error || `${actionType} failed.`); + const errorMsg = data.error || data.message || (typeof data === 'string' ? data : `${actionType} failed.`); + setCardActionError(errorMsg); setCardActionLoading(false); return; } @@ -1703,7 +1704,8 @@ function QueuePanel({ open, items, onClose, onUpdate, onDelete, onDeleteMany, on }); const data = await res.json(); if (!res.ok) { - setCardActionError(data.error || 'Redirect failed.'); + const errorMsg = data.error || data.message || (typeof data === 'string' ? data : JSON.stringify(data)); + setCardActionError(errorMsg); setCardActionLoading(false); return; }