OMG - it is very difficult to find the right title
I want to create employee data (photo, name. contact) on the /panel/site.
I would like to select and display individual employees on the subpages.
On my site.yml i created a structure field for employee data.
site.yml:
mitarbeiter:
label: Mitarbeiter
type: structure
fields:
ma_foto:
label: Bild
type: files
max: 1
layout: cards
ma_name:
label: Name
type: text
ma_telefon:
label: Telefon
type: text
ma_mail:
label: E-Mail
type: text
On my page.yml i created a multiselect field to select individual employees.
page.yml
kontakt:
label: Mitarbeiter
type: multiselect
options: query
query:
fetch: site.mitarbeiter.toStructure
text: "{{ structureItem.ma_name }}"
value: "{{ structureItem.ma_name }}"
How can I output the employee data on page.php?
Thank you for your help!