{% extends 'generic/object.html' %}
{% load buttons %}
{% load helpers %}
{% load perms %}

{% block title %}
  {{ object.mux }} / {{ object.port.name }} → {{ object.wavelength.value }} nm
{% endblock %}

{% block breadcrumbs %}
    <li><a href="{% url 'plugins:netbox_optics:muxwavelengthmap_list' %}">Mux Wavelength Maps</a></li>
    <li>{{ object.mux }} / {{ object.port.name }} → {{ object.wavelength.value }} nm</li>
{% endblock %}

{% block buttons %}
    {% if perms.netbox_optics.change_muxwavelengthmap %}
    <a href="{% url 'plugins:netbox_optics:muxwavelengthmap_edit' pk=object.pk %}" class="btn btn-warning">
        <span class="mdi mdi-pencil" aria-hidden="true"></span> Edit
    </a>    
    {% endif %}
    {% if perms.netbox_optics.delete_muxwavelengthmap %}
    <a href="{% url 'plugins:netbox_optics:muxwavelengthmap_delete' pk=object.pk %}" class="btn btn-danger">
        <span class="mdi mdi-trash-can-outline" aria-hidden="true"></span> Delete
    </a>    
    {% endif %}    
{% endblock %}

{% block content %}
<div class="row">
    <div class="col-md-12">
<div class="row">
    <div class="col-md-6">
        <div class="panel panel-default">
            <div class="panel-heading">
                <strong>{{ object.mux }} / {{ object.port.name }} → {{ object.wavelength.value }} nm</strong>
            </div>
            <table class="table table-hover panel-body attr-table">
                <tr>
                    <td>Mux Device</td>
                    <td>
                        <a href="{{ object.mux.get_absolute_url }}">{{ object.mux }}</a>
                    </td>
                </tr>
                <tr>
                    <td>Port</td>
                    <td>
                        <a href="{{ object.port.get_absolute_url }}">{{ object.port }}</a>
                    </td>
                </tr>
                <tr>
                    <td>Wavelength</td>
                    <td>
                        <a href="{{ object.wavelength.get_absolute_url }}">{{ object.wavelength.value }} nm</a>
                    </td>
                </tr>
                <tr>
                    <td>Grid</td>
                    <td>
                        <td><a href="{{ object.wavelength.grid.get_absolute_url }}">{{ object.wavelength.grid }}</a></td>
                    </td>
                </tr>
            </table>
        </div>
    </div>
</div>
    </div>
</div>
{% endblock %} 