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

Closes #191: Support for racks numbered top-to-bottom

This commit is contained in:
Jeremy Stretch
2016-10-28 11:30:40 -04:00
parent f8f5d6876b
commit 2db50dd4a7
10 changed files with 49 additions and 13 deletions

View File

@@ -78,7 +78,7 @@
</tr>
<tr>
<td>Position (U)</td>
<td>Lowest rack unit occupied by the device (optional)</td>
<td>Lowest-numbered rack unit occupied by the device (optional)</td>
<td>21</td>
</tr>
<tr>

View File

@@ -122,7 +122,7 @@
</tr>
<tr>
<td>Height</td>
<td>{{ rack.u_height }}U</td>
<td>{{ rack.u_height }}U ({% if rack.desc_units %}descending{% else %}ascending{% endif %})</td>
</tr>
<tr>
<td>Devices</td>
@@ -189,13 +189,13 @@
<div class="rack_header">
<h4>Front</h4>
</div>
{% include 'dcim/_rack_elevation.html' with primary_face=front_elevation secondary_face=rear_elevation face_id=0 %}
{% include 'dcim/inc/_rack_elevation.html' with primary_face=front_elevation secondary_face=rear_elevation face_id=0 %}
</div>
<div class="col-md-6 col-sm-6 col-xs-12">
<div class="rack_header">
<h4>Rear</h4>
</div>
{% include 'dcim/_rack_elevation.html' with primary_face=rear_elevation secondary_face=front_elevation face_id=1 %}
{% include 'dcim/inc/_rack_elevation.html' with primary_face=rear_elevation secondary_face=front_elevation face_id=1 %}
</div>
</div>
</div>

View File

@@ -14,6 +14,7 @@
{% render_field form.type %}
{% render_field form.width %}
{% render_field form.u_height %}
{% render_field form.desc_units %}
</div>
</div>
{% if form.custom_fields %}

View File

@@ -73,10 +73,15 @@
<td>Height in rack units</td>
<td>42</td>
</tr>
<tr>
<td>Descending units</td>
<td>Units are numbered top-to-bottom</td>
<td>False</td>
</tr>
</tbody>
</table>
<h4>Example</h4>
<pre>DC-4,Cage 1400,R101,J12.100,Pied Piper,Compute,4-post cabinet,19,42</pre>
<pre>DC-4,Cage 1400,R101,J12.100,Pied Piper,Compute,4-post cabinet,19,42,False</pre>
</div>
</div>
{% endblock %}