Lint / JS (eslint) (push) Successful in 7s
Lint / Python (flake8) (push) Successful in 50s
Lint / Notify on failure (push) Skipped
Lint / Deploy (push) Skipped
Security / Python Security (bandit) (push) Successful in 50s
Test / Python Tests (pytest) (push) Successful in 1m2s
Lint / Python (flake8) (pull_request) Successful in 52s
Lint / JS (eslint) (pull_request) Successful in 7s
Lint / Notify on failure (pull_request) Skipped
Lint / Deploy (pull_request) Skipped
Security / Python Security (bandit) (pull_request) Successful in 1m42s
Test / Python Tests (pytest) (pull_request) Successful in 2m2s
The rack front is drawn from the rack units on cutsheet items. Switches with a faceplate use it, with live port state; patch panels get a generic panel with port labels; everything else is a labelled plate. Each documented port shows its cutsheet state, and hovering a port lights up every port on the same cable run (through patch panels) and names the cables. Clicking opens the switch port or the cable. Overlapping items and items past the top of the rack are listed instead of drawn over another; where two claim the same top unit, the first one recorded wins. rack.units sets the height (default 42). /api/rack builds on the cutsheet view; cutsheet.rack_layout and cutsheet.port_marks hold the placement and per-port logic. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
39 lines
1.5 KiB
HTML
39 lines
1.5 KiB
HTML
{% extends "base.html" %}
|
|
{% block title %}Rack{% endblock %}
|
|
|
|
{% block content %}
|
|
<div class="lt-page-header">
|
|
<div>
|
|
<h1 class="lt-page-title">Rack</h1>
|
|
<p class="g-page-sub">The rack front, drawn from the rack units on the cutsheet with live port state. Hover a port to light up every port on the same cable run; click it to open the port or the cable.</p>
|
|
</div>
|
|
{% if can_edit %}
|
|
<div class="cs-actions no-print">
|
|
<a class="lt-btn lt-btn-secondary lt-btn-sm" href="/cutsheet#cs-items-section">Edit positions</a>
|
|
</div>
|
|
{% endif %}
|
|
</div>
|
|
|
|
<div class="rack-warnings" id="rack-warnings" role="alert" hidden></div>
|
|
|
|
<section class="g-section">
|
|
<div class="g-section-header">
|
|
<h2 class="g-section-title">Front</h2>
|
|
<span class="g-section-badge" id="rack-count">0</span>
|
|
</div>
|
|
<p class="rack-readout" id="rack-readout" aria-live="polite"></p>
|
|
<div class="rack-legend" aria-hidden="true">
|
|
<span><i class="rack-key rack-key-ok"></i>matches cutsheet</span>
|
|
<span><i class="rack-key rack-key-bad"></i>mismatch</span>
|
|
<span><i class="rack-key rack-key-doc"></i>documented, unconfirmed</span>
|
|
</div>
|
|
<div class="rack" id="rack"><div class="link-loading">Loading rack</div></div>
|
|
<p class="cs-hint rack-unplaced" id="rack-unplaced"></p>
|
|
</section>
|
|
{% endblock %}
|
|
|
|
{% block scripts %}
|
|
<script src="{{ url_for('static', filename='faceplates.js') }}"></script>
|
|
<script src="{{ url_for('static', filename='rack.js') }}"></script>
|
|
{% endblock %}
|