working relation

This commit is contained in:
Quentin 2023-03-02 10:03:46 +01:00
parent 58951873b2
commit 1aac795ba7
Signed by untrusted user: quentin
GPG key ID: E9602264D639FF68

View file

@ -1,14 +1,14 @@
backend: backend:
name: gitea name: gitea
repo: foobar/guide.web.vimaire.machine.dufour.io repo: deuxfleurs/guide.deuxfleurs.fr
base_url: http://teabag.vimaire.machine.dufour.io base_url: https://teabag.deuxfleurs.fr
api_root: http://git.vimaire.machine.dufour.io/api/v1 api_root: https://git.deuxfleurs.fr/api/v1
branch: main branch: cms
media_folder: 'static/img/' media_folder: 'static/img/'
site_url: http://guide.web.vimaire.machine.dufour.io site_url: http://guide.web.vimaire.machine.dufour.io
display_url: http://guide.web.vimaire.machine.dufour.io display_url: http://guide.web.vimaire.machine.dufour.io
locale: 'en' locale: 'fr'
collections: collections:
- name: 'accueil' - name: 'accueil'
@ -34,24 +34,30 @@ collections:
- name: 'prise_en_main' - name: 'prise_en_main'
label: 'Prise en main' label: 'Prise en main'
folder: 'content/prise_en_main' folder: 'content/prise_en_main'
#summary: '{{title}} ({{dirname}})'
editor: editor:
preview: false preview: false
create: true create: true
#nested:
# depth: 3
# summary: '{{title}}'
fields: fields:
- label: Title - label: Titre
name: title name: title
widget: string widget: string
- label: Weight - label: Poids
name: weight name: weight
widget: number widget: number
- label: Body - label: Extra
name: extra
widget: object
fields:
- name: parent
label: Parent
widget: relation
collection: 'prise_en_main'
value_field: 'prise_en_main/{{filename}}.{{extension}}'
search_fields: [ 'title', 'filename', 'slug' ]
display_fields: ['{{title}} ({{filename}})', 'filename']
- label: Corps
name: body name: body
widget: markdown widget: text
#meta: { path: { widget: string, label: 'Path', index_file: '_index' } }
- name: 'formations' - name: 'formations'
label: 'Se former' label: 'Se former'