Browse Source

Fixed double top border on component template tables

Jeremy Stretch 9 years ago
parent
commit
0b66b547a3

+ 4 - 4
netbox/dcim/tables.py

@@ -145,7 +145,7 @@ class ConsolePortTemplateTable(tables.Table):
         empty_text = "None"
         show_header = False
         attrs = {
-            'class': 'table table-hover panel-body',
+            'class': 'table table-hover',
         }
 
 
@@ -158,7 +158,7 @@ class ConsoleServerPortTemplateTable(tables.Table):
         empty_text = "None"
         show_header = False
         attrs = {
-            'class': 'table table-hover panel-body',
+            'class': 'table table-hover',
         }
 
 
@@ -171,7 +171,7 @@ class PowerPortTemplateTable(tables.Table):
         empty_text = "None"
         show_header = False
         attrs = {
-            'class': 'table table-hover panel-body',
+            'class': 'table table-hover',
         }
 
 
@@ -184,7 +184,7 @@ class PowerOutletTemplateTable(tables.Table):
         empty_text = "None"
         show_header = False
         attrs = {
-            'class': 'table table-hover panel-body',
+            'class': 'table table-hover',
         }
 
 

+ 10 - 4
netbox/project-static/css/base.css

@@ -258,16 +258,22 @@ ul.rack_near_face li.empty:hover a {
 .dark_gray:hover { background-color: #2c3e50; }
 
 /* Misc */
-.panel table>thead>tr>th {
-    border-bottom: 0;
+.panel table {
+    margin-bottom: 0;
 }
-ul.nav-tabs, ul.nav-pills {
-    margin-bottom: 20px;
+.panel .table th {
+    border-bottom-width: 1px;
+}
+.panel table tr.even:first-child td {
+    border-top: 0;
 }
 .panel .list-group {
     max-height: 400px;
     overflow: auto;
 }
+ul.nav-tabs, ul.nav-pills {
+    margin-bottom: 20px;
+}
 /* Fix progress bar margin inside table cells */
 td .progress {
     margin-bottom: 0;

+ 1 - 3
netbox/templates/dcim/inc/devicetype_component_table.html

@@ -22,8 +22,6 @@
         <div class="panel-heading">
             <strong>{{ title }}</strong>
         </div>
-        <table class="table table-hover panel-body">
-            {% render_table table table_template|default:'table.html' %}
-        </table>
+        {% render_table table 'table.html' %}
     </div>
 {% endif %}