How to properly define items to be rendered on a page?

Hi there, I currently try to migrate a website to Zola that has a number of services listed on the landing page. Some do directly link to their domain, some have their own subpages with explainers.

So my current approach was to add the content for the landingpage entries to each page meta and add content to those who … well … intend have content. I’ve put them all into ./content/services. That way I’d have everything in one place and can just add content if needed in the future – or if applicable already.

./content/services/bookwyrm.md

+++
title = "Bookwyrm"
[extra]
categories = ["Social"]
quick_desc = "Soziales Lesen und Bewerten"
link = "https://theservice.domain.xyz/"
+++

Because I can’t use get_section in ./content, the landingpage has its dedicated template containing:

{% block services %}
    {% set services = get_section(path="services/_index.md") %}
    {% for p in services.pages %}
        {% if p.extra.is_playground is not defined or p.extra.is_playground != "true" %}       
            <div class='col-xs-12 col-sm-6 col-md-4'>
                <div class="{{p.title | lower}}-index service-index">
                    <img class="index-logo-sm" src="/images/logos/{{p.title | lower}}.png" />
                    <h4>{{p.title}}</h4>
                    <p class=apps>{{p.extra.quick_desc}}</p>
                    {% if p.content %}
                        <a class="btn btn-small btn-hosted" href="{{p.permalink}}" target='_blank' type="button">Über den Dienst</a>
                    {% else %}
                        {% if p.extra.link %}
                            <a class="btn btn-small btn-hosted" href="{{p.extra.link}}" target='_blank' type="button">Direkt zum Dienst</a>
                        {% endif %}
                    {% endif %}
                </div>
            </div>
        {% endif %}
    {% endfor %}
{% endblock services %}

However this causes blank pages to be rendered, which I do not want.
I then added render=false for those without content, but this prevents Zola from accessing the metadata. :frowning:

…so then I tried to adjust my section.html template to add a placeholder if there is no content… this is currently broken as the check for no content is not working as intended…

Snippet of the not working section.html template

{% block content %}
  {% if not section.content %}
    <div id="card" class=service-list>
      {% if section.title %}
        <h1>{{section.title}} : {{config.title}}</h1>
      {% endif %}
      <p>Oh, eine Seite ohne Inhalt. Ja sowas... .</p>
      <a href="/" class="btn"><i class="fa fa-house" aria-hidden="true"></i> zurück zur Startseite</a>
      {% if section.extra.link %}
        Hier geht's direkt zum Dienst: {{ section.extra.link }}
      {% endif %}
    </div>
  {% endif %}
  {% if section.extra.link %}
    Hier geht's direkt zum Dienst: {{ section.extra.link }}
  {% endif %}
{% endblock content %}

Well I suppose the check is content?^^ However neither is null or is empty works because “Test not found”.

…Anyway, this still does not feel that clean to me. Is this even a sense making approach? Could there be a better way to do this? Or maybe a better way not to render those empty pages? I was hoping not to have to do duplicate definitions of the items that are rendered on the landing page.