I like to set a default page when a new “article” is create. See screenshot attached.
author:
label: Author
type: pages
min: 1
max: 1
query: site.index(true).template("single-author")
default: <What do I put here?>
width: 1/3
I like to set a default page when a new “article” is create. See screenshot attached.
author:
label: Author
type: pages
min: 1
max: 1
query: site.index(true).template("single-author")
default: <What do I put here?>
width: 1/3
The id of a page:
author:
label: Author
type: pages
min: 1
max: 1
query: site.index(true).template("single-author")
default:
- notes/through-the-desert
width: 1/3
@pixelijn Thanks. This is perfect!
does it accept a collection as well? It is not working for me I need a set of subpages and the IDs can obviously change. I am trying:
materials:
label: Materialien
type: pages
default: site.children.filterBy('intendedTemplate','material')
but it is not working
Queries for default values are not supported: Support query templates in `default` field property · Kirby Feedback