Frontend output for multiselect and selects in structure field

I have more or less a simple structure field (see below):

title: Site
fields: 
    expenses: 
      type: structure
      columns:
            captions:
            account:
            value:
    fields:
      month:
            type: multiselect
            options:
              - Jan
              - Feb
              - Mar
              - ...
            required: true
            sort: true
      captions: 
            type: select
            options:
              - Children
              - Entertainment
              - ...
      expenses_children: 
            type: select
            options:
              - Health
              - School
              - ...
            when:
              captions: Children
      expenses_entertainment:
            type: select
            options:
              - Netflix
              - Sports
              - ...
            when:
              captions: Entertainment
      account:
            type: select
            options:
              - Woman
              - Man
      value:
            type: number
            min: 0
            after: €
            required: true
            step: .01

In Kirby everything ist working fine as expected.
But I´ve no idea how get the output in frontend as shown in the table below (screenshot).

Can anybody help me if you can see what want to achieve?

31

I’m not so sure your data model is ideal for what you want to achieve.

Having said that, to achieve want you want you probably want to first filter your structure collection by account (woman/man) and captions. Then the question is if you always want to output all months or only those months that contain data. And then take it from there.

You could also group the collection but that might get too complicated, so I’d rather do the filtering for the different groups first

Hello Sonja,

thank you for your reply. I would be thankful for better suggestions on how to reach my goal.