export const statusText = (s: string) => ({ processing: '计算中', created: '待处理', done: '计算完成', blocked: '诊断结果', error: '处理失败', review: '待确认点云' })[s] || s || '—' export const dateText = (value: any) => value == null ? '—' : typeof value === 'number' ? new Date(value).toLocaleString() : String(value).replace('T', ' ').slice(0, 19) export const inputName = (row: any, role: string) => { try { return JSON.parse(row.inputsJson || '{}')[role]?.name || '—' } catch { return '—' } } export const fileSize = (n: number) => (n ? `${(n / 1024 / 1024).toFixed(2)} MB` : '—')