]> ToastFreeware Gitweb - philipp/winterrodeln/wrpylib.git/commitdiff
Details for sled rental and newline tuning for public transport.
authorPhilipp Spitzer <philipp@spitzer.priv.at>
Thu, 9 Jun 2022 21:48:42 +0000 (23:48 +0200)
committerPhilipp Spitzer <philipp@spitzer.priv.at>
Thu, 9 Jun 2022 21:48:42 +0000 (23:48 +0200)
wrpylib/templates/sledrun_wikitext.txt

index 3b1e80848c09722e605e708c77253354375a0441..98f10253e9ad82fbf0615cb41f511638e3293026 100644 (file)
 * {{Gehzeit}}
 {% endraw -%}
 * '''Beleuchtung''': {{ nightlight_description | default( nightlight_possible | default("''Unbekannt''") ) | trim }}
 * {{Gehzeit}}
 {% endraw -%}
 * '''Beleuchtung''': {{ nightlight_description | default( nightlight_possible | default("''Unbekannt''") ) | trim }}
-* '''Rodelverleih''': {{ sled_rental_description | default( sled_rental_direct | german_bool | default("''Unbekannt''") ) | trim }}
+* '''Rodelverleih''': {% if sled_rental_description -%}
+{{ sled_rental_description | trim }}
+{%- else -%}
+{% if sled_rental -%}
+{% if sled_rental|length == 0 %}Nein{% endif %}
+{%- else -%}
+{{ sled_rental_direct | german_bool | default("''Unbekannt''") }}
+{%- endif %}
+{%- endif -%}
+{% for rental in sled_rental %}
+** {{ rental.name }}{%if rental.note %} ({{ rental.note }}){% endif %}{% if rental.wr_page %}{{ wr_page(info) }}{% endif %}
+{%- endfor %}
 * '''Schneelage - Auskunft''':
 {%- for info in info_phone %}
 ** {{ info.phone }} ({{ info.name }})
 * '''Schneelage - Auskunft''':
 {%- for info in info_phone %}
 ** {{ info.phone }} ({{ info.name }})
 {%- endfor -%}
 {% if public_transport_lines|length + public_transport_links|length > 0 -%}
 * '''Fahrplan''':
 {%- endfor -%}
 {% if public_transport_lines|length + public_transport_links|length > 0 -%}
 * '''Fahrplan''':
-{% endif -%}
 {% for pt_line in public_transport_lines -%}
 ** {% if pt_line.timetable_template is defined %}{{ h.json_template(pt_line.timetable_template) }}
    {%- else %}{{ pt_line.name }}{% endif %}
 {% endfor -%}
 {% for link in public_transport_links -%}
 ** {{ weblink(link) }}
 {% for pt_line in public_transport_lines -%}
 ** {% if pt_line.timetable_template is defined %}{{ h.json_template(pt_line.timetable_template) }}
    {%- else %}{{ pt_line.name }}{% endif %}
 {% endfor -%}
 {% for link in public_transport_links -%}
 ** {{ weblink(link) }}
-{%- endfor %}
-
-
+{% endfor %}
+{% endif %}
 == Anreise mit dem Auto ==
 {% if car_description -%}
 {{ car_description | trim }}
 == Anreise mit dem Auto ==
 {% if car_description -%}
 {{ car_description | trim }}