I’m working on a project were i have a blueprint for a page template called “Event”. The template is used to create pages that represent an event and its related information.
The “event_location” field allows the user to choose a location from a list of options fetched using a query. The “event_venue” field allows the user to choose one or more venues for the event based on the location selected in the “event_location” field. The options for the “event_venue” field are fetched from a structure field from another page.
columns:
main:
width: 2/3
sections:
content:
type: fields
fields:
event_location:
label: Location
width: 1/2
type: select
options: query
query:
fetch: site.find("locations").children.unlisted
text: "{{ page.location_name }}"
value: "{{ page.id }}"
event_venue:
label: Venue
width: 1/2
type: checkboxes
options: query
query:
fetch: site.find(page.event_location).location_venues.toStructure
text: "{{ structureItem.name }}"
value: "{{ structureItem.code}}"
Everything works fine but when the “event_location” field changes, the checkboxes of the “event_venue” field do not update unless you reload the page.
Is there a way to reload the panel when a field changes? Or to trigger the query fetch again to update the “event_location” variable?
Thank you in advance! Help is much appreciated