Filter default modifiers from KDS display
Only show customized modifiers on the Kitchen Display System, hiding default/unaltered selections to reduce clutter. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
fe383f40d0
commit
ef6efa0762
1 changed files with 6 additions and 2 deletions
|
|
@ -343,8 +343,12 @@ function renderAllModifiers(modifiers, allItems) {
|
||||||
function collectLeafModifiers(mods, depth = 0) {
|
function collectLeafModifiers(mods, depth = 0) {
|
||||||
console.log(` collectLeafModifiers depth=${depth}, processing ${mods.length} mods:`, mods.map(m => m.ItemName));
|
console.log(` collectLeafModifiers depth=${depth}, processing ${mods.length} mods:`, mods.map(m => m.ItemName));
|
||||||
mods.forEach(mod => {
|
mods.forEach(mod => {
|
||||||
// Show ALL selected modifiers - don't skip defaults
|
// Skip default modifiers - only show customizations
|
||||||
// The customer made a choice and it should be visible on the KDS
|
if (mod.ItemIsCheckedByDefault) {
|
||||||
|
console.log(` Skipping default modifier: ${mod.ItemName}`);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
const children = allItems.filter(item => item.OrderLineItemParentOrderLineItemID === mod.OrderLineItemID);
|
const children = allItems.filter(item => item.OrderLineItemParentOrderLineItemID === mod.OrderLineItemID);
|
||||||
console.log(` Mod: ${mod.ItemName} (ID: ${mod.OrderLineItemID}) has ${children.length} children`);
|
console.log(` Mod: ${mod.ItemName} (ID: ${mod.OrderLineItemID}) has ${children.length} children`);
|
||||||
if (children.length === 0) {
|
if (children.length === 0) {
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue