Web: Chargenseite - Spalte "Art" (Lebensmittel/Gegenstand)

Neue sortier-/filterbare Spalte zeigt je Charge, ob es ein Lebensmittel oder ein
Gegenstand (Verbrauchsgegenstand) ist.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
Scarriffle
2026-07-29 14:13:22 +02:00
parent 012e3461ae
commit 18c07eaf3a

View File

@@ -103,6 +103,12 @@ export default function Charges() {
{l.product_brand && <span className="muted small">{l.product_brand}</span>} {l.product_brand && <span className="muted small">{l.product_brand}</span>}
</span> </span>
) }, ) },
{ key: "art", header: "Art", width: 130,
filterText: (l) => (l.tracking === "object" ? "Gegenstand" : "Lebensmittel"),
filterValues: (l) => [l.tracking === "object" ? "Gegenstand" : "Lebensmittel"],
render: (l) => (
<span className="badge nowrap">{l.tracking === "object" ? "Gegenstand" : "Lebensmittel"}</span>
) },
{ key: "menge", header: "Menge", width: 150, align: "num", { key: "menge", header: "Menge", width: 150, align: "num",
sortValue: (l) => l.quantity / artFactor(l), render: mengeText }, sortValue: (l) => l.quantity / artFactor(l), render: mengeText },
{ key: "mhd", header: "MHD", width: 150, { key: "mhd", header: "MHD", width: 150,