From f8874a3e95486553252ce25fe45ea95f74816a33 Mon Sep 17 00:00:00 2001 From: Johannes Baumeister Date: Sat, 2 May 2026 11:34:28 +0200 Subject: [PATCH] Compact legend and expanded owner management table (Nachname, Vorname, Adresse) --- app.js | 23 ++++++++++++++++++++--- index.html | 4 +++- style.css | 30 +++++++++++++++--------------- 3 files changed, 38 insertions(+), 19 deletions(-) diff --git a/app.js b/app.js index bb476f4..faf216f 100644 --- a/app.js +++ b/app.js @@ -1511,8 +1511,20 @@ document.addEventListener('DOMContentLoaded', async () => { const last = p[state.ownerMapping.lastName] || ''; const fullName = `${first} ${last}`.trim() || "Unbekannt"; + // Adress-Felder extrahieren (STR, HSN, PLZ, ORP) + const str = p.STR || ''; + const hsn = p.HSN || ''; + const plz = p.PLZ || ''; + const ort = p.ORP || ''; + const address = `${str} ${hsn}, ${plz} ${ort}`.trim().replace(/^,/, '').trim(); + if (!owners[fullName]) { - owners[fullName] = { count: 0, first, last }; + owners[fullName] = { + count: 0, + first, + last, + address: address || 'Keine Adresse' + }; } owners[fullName].count++; }); @@ -1523,7 +1535,10 @@ document.addEventListener('DOMContentLoaded', async () => { const query = ownerSearch.value.toLowerCase(); const filtered = {}; for (let name in owners) { - if (name.toLowerCase().includes(query)) filtered[name] = owners[name]; + const o = owners[name]; + if (name.toLowerCase().includes(query) || (o.address && o.address.toLowerCase().includes(query))) { + filtered[name] = o; + } } renderOwnerRows(filtered); }; @@ -1539,7 +1554,9 @@ document.addEventListener('DOMContentLoaded', async () => { const row = document.createElement('tr'); row.innerHTML = ` - ${name} + ${data.last} + ${data.first} + ${data.address} ${data.count} Flurstücke