{% load humanize %}
{% if ports.count > 0 %}
{% if content == "Category" %}
Your search "{{ query }}" in category "{{ search_in }}" matched {{ ports|length|intcomma }} ports.
{% elif content == "Maintainer" %}
Your search "{{ query }}" in ports maintained by "{{ search_in }}" matched {{ ports|length|intcomma }} ports.
{% elif content == "Variant" %}
Your search "{{ query }}" in variant "{{ search_in }}" matched {{ ports|length|intcomma }} ports.
{% else %}
Showing results for "{{ query }}".
{% endif %}
{% if content == "Variant" %}
| Name |
Version |
Description |
{% for port in ports %}
| {{ port.port.name }} |
{{ port.port.version }} |
{{ port.port.description }} |
{% endfor %}
{% else %}
| Name |
Version |
Description |
{% for port in ports %}
| {{ port.name }} |
{{ port.version }} |
{{ port.description }} |
{% endfor %}
{% endif %}
{% else %}
{% if content == "Category" %}
Sorry, no matching ports found for "{{ query }}" in category "{{ search_in }}".
{% elif content == "Maintainer" %}
Sorry, no matching ports found for "{{ query }}" in the ports maintained by "{{ search_in }}".
{% elif content == "Variant" %}
Sorry, no matching ports found for "{{ query }}" in the variant "{{ search_in }}".
{% else %}
Sorry, no matching ports found for "{{ query }}"
{% endif %}
{% endif %}