version complete de config.yaml

This commit is contained in:
Quentin 2023-03-02 11:39:37 +01:00
parent 8ddc3807a5
commit 457e3bde70
Signed by untrusted user: quentin
GPG key ID: E9602264D639FF68

View file

@ -229,3 +229,52 @@ collections:
- label: Corps - label: Corps
name: body name: body
widget: markdown widget: markdown
- name: 'operations'
label: 'Opérations'
description: "Base de connaissance technique à destination des operateur-ices"
folder: 'content/operations'
editor:
preview: false
create: true
view_filters:
- label: 'Brouillons'
field: draft
pattern: true
view_groups:
- label: 'Section'
field: 'extra.parent'
pattern: '.*'
fields:
- label: Titre
name: title
widget: string
- label: Poids
default: 50
name: weight
widget: number
- label: Brouillon (ne pas publier encore)
name: draft
widget: boolean
default: false
- label: Date
name: date
widget: datetime
date_format: 'dd/MM/yyyy' # e.g. 24/12/2022
time_format: false
format: 'yyyy-MM-dd' # e.g. 2022-12-24
- label: Extra
name: extra
widget: object
fields:
- name: parent
label: Parent
widget: relation
collection: 'operations'
value_field: 'operations/{{filename}}.{{extension}}'
search_fields: [ 'title', 'filename', 'slug' ]
default: 'operations/_index.md'
display_fields: ['{{title}} ({{filename}})', 'filename']
- label: Corps
name: body
widget: markdown