1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

Add model doc modal to object add/edit template

This commit is contained in:
Jeremy Stretch
2020-03-05 13:56:03 -05:00
parent 9f42bce16a
commit 25f4cae3ff

View File

@ -1,5 +1,6 @@
{% extends '_base.html' %}
{% load form_helpers %}
{% load helpers %}
{% block content %}
<form action="" method="post" enctype="multipart/form-data" class="form form-horizontal">
@ -9,7 +10,12 @@
{% endfor %}
<div class="row">
<div class="col-md-6 col-md-offset-3">
<h3>{% block title %}{% if obj.pk %}Editing {{ obj_type }} {{ obj }}{% else %}Add a new {{ obj_type }}{% endif %}{% endblock %}</h3>
<h3>
<div class="pull-right">
<button type="button" class="btn btn-primary btn-xs" data-toggle="modal" data-target="#docs_modal"><i class="fa fa-question"></i></button>
</div>
{% block title %}{% if obj.pk %}Editing {{ obj_type }} {{ obj }}{% else %}Add a new {{ obj_type }}{% endif %}{% endblock %}
</h3>
{% block tabs %}{% endblock %}
{% if form.non_field_errors %}
<div class="panel panel-danger">
@ -43,4 +49,5 @@
</div>
</div>
</form>
{% include 'inc/modal.html' with name='docs' title='Documentation' content=obj|get_docs %}
{% endblock %}