diff --git a/tailbone/static/css/layout.css b/tailbone/static/css/layout.css index 4fd44333..6305e800 100644 --- a/tailbone/static/css/layout.css +++ b/tailbone/static/css/layout.css @@ -160,6 +160,12 @@ body > #body-wrapper { * Panels ******************************/ +.panel-wrapper { + float: left; + margin-right: 15px; + width: 40%; +} + .panel, .panel-grid { border-left: 1px solid Black; diff --git a/tailbone/templates/products/view.mako b/tailbone/templates/products/view.mako index d1efcb0b..e6c12355 100644 --- a/tailbone/templates/products/view.mako +++ b/tailbone/templates/products/view.mako @@ -11,11 +11,6 @@ #product-image { float: left; } - .panel-wrapper { - float: left; - margin-right: 15px; - width: 40%; - } diff --git a/tailbone/templates/tempmon/probes/view.mako b/tailbone/templates/tempmon/probes/view.mako new file mode 100644 index 00000000..386cc4db --- /dev/null +++ b/tailbone/templates/tempmon/probes/view.mako @@ -0,0 +1,88 @@ +## -*- coding: utf-8; -*- +<%inherit file="/master/view.mako" /> + +############################## +## page body +############################## + + + +
+ +
+

General

+
+
+ ${self.render_main_fields(form)} +
+## % if image_url: +## ${h.image(image_url, "Probe Image", id='probe-image', width=150, height=150)} +## % endif +
+
+ +
+ ${self.left_column()} +
+ +
+ ${self.right_column()} +
+ +
+ +% if master.has_rows: + ${rows_grid|n} +% endif + +############################## +## rendering methods +############################## + +<%def name="render_main_fields(form)"> + ${form.render_field_readonly('client')} + ${form.render_field_readonly('config_key')} + ${form.render_field_readonly('appliance_type')} + ${form.render_field_readonly('description')} + ${form.render_field_readonly('device_path')} + ${form.render_field_readonly('notes')} + ${form.render_field_readonly('enabled')} + ${form.render_field_readonly('status')} + ${form.render_field_readonly('therm_status_timeout')} + ${form.render_field_readonly('status_alert_timeout')} + + +<%def name="left_column()"> +
+

Temperatures

+
+ ${self.render_temperature_fields(form)} +
+
+ + +<%def name="right_column()"> +
+

Timeouts

+
+ ${self.render_timeout_fields(form)} +
+
+ + +<%def name="render_temperature_fields(form)"> + ${form.render_field_readonly('critical_temp_max')} + ${form.render_field_readonly('good_temp_max')} + ${form.render_field_readonly('good_temp_min')} + ${form.render_field_readonly('critical_temp_min')} + + +<%def name="render_timeout_fields(form)"> + ${form.render_field_readonly('critical_max_timeout')} + ${form.render_field_readonly('good_max_timeout')} + ${form.render_field_readonly('good_min_timeout')} + ${form.render_field_readonly('critical_min_timeout')} + ${form.render_field_readonly('error_timeout')} + diff --git a/tailbone/views/tempmon/probes.py b/tailbone/views/tempmon/probes.py index 22a8d309..25542b4c 100644 --- a/tailbone/views/tempmon/probes.py +++ b/tailbone/views/tempmon/probes.py @@ -51,6 +51,13 @@ class TempmonProbeView(MasterView): has_rows = True model_row_class = tempmon.Reading + labels = { + 'critical_max_timeout': "Critical High Timeout", + 'good_max_timeout': "High Timeout", + 'good_min_timeout': "Low Timeout", + 'critical_min_timeout': "Critical Low Timeout", + } + grid_columns = [ 'client', 'config_key',