Fix: Elektro-Input Remount, Bestellungen Ladeschleife durch kalkulator3d API-Format

This commit is contained in:
2026-05-31 14:41:21 +02:00
parent 9955fc77b7
commit 70fac26709
2 changed files with 58 additions and 47 deletions

View File

@@ -47,7 +47,7 @@ function BestellungDetail({ id, toast, onBack }) {
const [form, setForm] = useState({ name:'', bemerkung:'', custom_price:'', status:'warteliste' });
useEffect(() => {
api('/tools/kalkulator3d').then(setArchiv).catch(()=>{});
api('/tools/kalkulator3d').then(d => setArchiv(d.own || d || [])).catch(()=>{});
if (id) {
api(`/tools/bestellungen/${id}`)
.then(o => { setOrder(o); setForm({ name:o.name, bemerkung:o.bemerkung, custom_price:o.custom_price??'', status:o.status }); })