Skip to content

Commit

Permalink
Closes #16943: Expand navigation breadcrumbs on job view to include p…
Browse files Browse the repository at this point in the history
…arent object
  • Loading branch information
jeremystretch committed Jul 19, 2024
1 parent 11cadf3 commit 3028f26
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions netbox/templates/core/job.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,18 @@
{% load perms %}
{% load i18n %}

{% block breadcrumbs %}
{{ block.super }}
<li class="breadcrumb-item">
<a href="{% url 'core:job_list' %}?object_type={{ object.object_type_id }}">{{ object.object|meta:"verbose_name_plural"|bettertitle }}</a>
</li>
{% with parent_jobs_viewname=object.object|viewname:"jobs" %}
<li class="breadcrumb-item">
<a href="{% url parent_jobs_viewname pk=object.object.pk %}">{{ object.object }}</a>
</li>
{% endwith %}
{% endblock breadcrumbs %}

{% block control-buttons %}
{% if request.user|can_delete:object %}
{% delete_button object %}
Expand Down

0 comments on commit 3028f26

Please sign in to comment.