Add guard for FilterModifierWidget with no lookups

This commit is contained in:
Jason Novinger 2025-12-03 18:47:03 -06:00
parent 575dcea478
commit 197f94a6ef

View File

@ -1,4 +1,5 @@
<div class="d-flex filter-modifier-group">
{% if widget.lookups %}
{# Modifier dropdown - NO name attribute, just a UI control #}
<select class="form-select modifier-select"
data-field="{{ widget.field_name }}"
@ -8,6 +9,7 @@
<option value="{{ lookup }}"{% if widget.current_modifier == lookup %} selected{% endif %}>{{ label }}</option>
{% endfor %}
</select>
{% endif %}
{# Original widget - rendered exactly as it would be without our wrapper #}
<div class="ms-2 flex-grow-1 filter-value-container">