1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859 |
- <tr class="consoleserverport{% if csp.connected_console and not csp.connected_console.connection_status %} info{% endif %}">
- {% if selectable and perms.dcim.change_consoleserverport or perms.dcim.delete_consoleserverport %}
- <td class="pk">
- <input name="pk" type="checkbox" value="{{ csp.pk }}" />
- </td>
- {% endif %}
- <td>
- <i class="fa fa-fw fa-keyboard-o"></i> {{ csp.name }}
- </td>
- <td></td>
- {% if csp.connected_console %}
- <td>
- <a href="{% url 'dcim:device' pk=csp.connected_console.device.pk %}">{{ csp.connected_console.device }}</a>
- </td>
- <td>
- {{ csp.connected_console.name }}
- </td>
- {% else %}
- <td colspan="2">
- <span class="text-muted">Not connected</span>
- </td>
- {% endif %}
- <td colspan="2" class="text-right">
- {% if perms.dcim.change_consoleserverport %}
- {% if csp.connected_console %}
- {% if csp.connected_console.connection_status %}
- <a href="#" class="btn btn-warning btn-xs consoleport-toggle connected" data="{{ csp.connected_console.pk }}">
- <i class="glyphicon glyphicon-ban-circle" aria-hidden="true" title="Mark planned"></i>
- </a>
- {% else %}
- <a href="#" class="btn btn-success btn-xs consoleport-toggle" data="{{ csp.connected_console.pk }}">
- <i class="fa fa-plug" aria-hidden="true" title="Mark connected"></i>
- </a>
- {% endif %}
- <a href="{% url 'dcim:consoleserverport_disconnect' pk=csp.pk %}" class="btn btn-danger btn-xs">
- <i class="glyphicon glyphicon-resize-full" aria-hidden="true" title="Delete connection"></i>
- </a>
- {% else %}
- <a href="{% url 'dcim:consoleserverport_connect' pk=csp.pk %}" class="btn btn-success btn-xs">
- <i class="glyphicon glyphicon-resize-small" aria-hidden="true" title="Connect"></i>
- </a>
- {% endif %}
- <a href="{% url 'dcim:consoleserverport_edit' pk=csp.pk %}" class="btn btn-info btn-xs">
- <i class="glyphicon glyphicon-pencil" aria-hidden="true" title="Edit port"></i>
- </a>
- {% endif %}
- {% if perms.dcim.delete_consoleserverport %}
- {% if csp.connected_console %}
- <button class="btn btn-danger btn-xs" disabled="disabled">
- <i class="glyphicon glyphicon-trash" aria-hidden="true"></i>
- </button>
- {% else %}
- <a href="{% url 'dcim:consoleserverport_delete' pk=csp.pk %}" class="btn btn-danger btn-xs">
- <i class="glyphicon glyphicon-trash" aria-hidden="true" title="Delete port"></i>
- </a>
- {% endif %}
- {% endif %}
- </td>
- </tr>
|