Hello everyone and a little bit late Merry Christmas!
So, I’m having some trouble sorting my structure entries in the panel.
According to the guide I should be able to sort asc or desc using one field, but it doesn’t seem to work for me.
Here’s my blueprint:
title: Lista degli eventi
icon: calendar
preset: pages
pages: event
files: false
options:
delete: false
status: false
url: false
title: false
duplicate: false
fields:
description:
label: Testo introduttivo
type: markdown
size: small
events:
label: Prossimi eventi
type: structure
columns:
dateBegins:
width: 1/8
dateEnds:
width: 1/8
eventName:
width: 2/8
eventDescription:
width: 4/8
# sortBy: dateBegins asc
fields:
eventName:
label: Nome dell'evento
type: text
dateBegins:
label: Data di inizio
type: date
default: today
width: 1/2
dateEnds:
label: Data di fine
type: date
width: 1/2
help: Se il campo viene lasciato vuoto l'evento ha la durata di un solo giorno
dates:
label: Date aggiuntive
type: structure
fields:
dateBegins:
label: Data di inizio
type: date
default: today
width: 1/2
dateEnds:
label: Data di fine
type: date
width: 1/2
help: Se il campo viene lasciato vuoto l'evento ha la durata di un solo giorno
eventDescription:
label: Descrizione dell'evento
type: markdown
size: small
required: true
eventSubscription:
label: Informazione sulle iscrizioni
type: markdown
size: small
eventNotes:
label: Note aggiuntive
type: markdown
size: small
If I try to sort by dateBegins
(but also by another field) I get the error t.items is undefined
.
Any idea on what could be the problem? I can’t figure it out and I would really like to sort the entries!
Thanks a lot and have a nice evening!
Sara