{% with breadcrumbs = request.path.split("/") %} {% set breadcrumbs_ns = namespace(working_url="") %} {% for breadcrumb in breadcrumbs %} {% set breadcrumb_prefix = "" %} {% set breadcrumb_url = url_for(breadcrumb.replace('_', '-')) %} {% if breadcrumb == current_endpoint %} {% set breadcrumb_url = breadcrumbs_url %} {% endif %} {% if breadcrumb_url == "#" %} {% set breadcrumb_url = breadcrumbs_ns.working_url %} {% else %} {% set breadcrumbs_ns.working_url = breadcrumb_url %} {% endif %} {% if current_endpoint != "configs" and "configs" in request.path %} {% set breadcrumb_url = url_for("configs") %} {% if loop.index == 3 %} {% set breadcrumb_prefix = "?service=" + breadcrumb %} {% elif loop.index == 4 %} {% set breadcrumb_prefix = "?type=" + breadcrumb %} {% endif %} {% endif %} {% if current_endpoint != "cache" and "cache" in request.path %} {% set breadcrumb_url = url_for("cache") %} {% if loop.index == 3 %} {% set breadcrumb_prefix = "?service=" + breadcrumb %} {% elif loop.index == 4 %} {% set breadcrumb_prefix = "?plugin=" + breadcrumb %} {% elif loop.index == 5 %} {% set breadcrumb_prefix = "?job_name=" + breadcrumb %} {% endif %} {% endif %}
  1. {{ breadcrumb }}
  2. {% endfor %} {% endwith %}