On 01/24/2012 04:41 PM, tsedovic(a)redhat.com wrote:
From: Tomas Sedovic<tomas(a)sedovic.cz>
---
.../views/deployments/_pretty_view_show.html.haml | 12 ++++++------
src/public/stylesheets/layout_ie7.css | 17 +++++++++++++++++
2 files changed, 23 insertions(+), 6 deletions(-)
diff --git a/src/app/views/deployments/_pretty_view_show.html.haml
b/src/app/views/deployments/_pretty_view_show.html.haml
index a52ea08..3cf6de3 100644
--- a/src/app/views/deployments/_pretty_view_show.html.haml
+++ b/src/app/views/deployments/_pretty_view_show.html.haml
@@ -22,8 +22,8 @@
.actions
%ul
- available_actions = instance.get_action_list
- %li= button_to(t('deployments.pretty_view_show.stop'),
stop_instance_path(instance), :disabled =>
!available_actions.include?(InstanceTask::ACTION_STOP))
- %li= button_to(t('deployments.pretty_view_show.reboot'),
reboot_instance_path(instance), :disabled =>
!available_actions.include?(InstanceTask::ACTION_REBOOT))
+ %li= button_to(t('deployments.pretty_view_show.stop'),
stop_instance_path(instance), :disabled =>
!available_actions.include?(InstanceTask::ACTION_STOP), :class => "button
danger")
+ %li= button_to(t('deployments.pretty_view_show.reboot'),
reboot_instance_path(instance), :disabled =>
!available_actions.include?(InstanceTask::ACTION_REBOOT), :class => "button
danger")
:javascript
Conductor.setupPrettyFilterURL(
@@ -66,15 +66,15 @@
<div class="actions">
<ul>
{{if stop_enabled}}
-<li>#{button_to(t('deployments.pretty_view_show.stop'),
stop_instance_path('replace_id').sub('replace_id', '${id}'),
:disabled => false)}</li>
+<li>#{button_to(t('deployments.pretty_view_show.stop'),
stop_instance_path('replace_id').sub('replace_id', '${id}'),
:disabled => false, :class => 'button danger')}</li>
{{else}}
-<li>#{button_to(t('deployments.pretty_view_show.stop'),
stop_instance_path('replace_id').sub('replace_id', '${id}'),
:disabled => true)}</li>
+<li>#{button_to(t('deployments.pretty_view_show.stop'),
stop_instance_path('replace_id').sub('replace_id', '${id}'),
:disabled => true, :class => 'button danger')}</li>
{{/if}}
{{if reboot_enabled}}
-<li>#{button_to(t('deployments.pretty_view_show.reboot'),
reboot_instance_path('replace_id').sub('replace_id', '${id}'),
:disabled => false)}</li>
+<li>#{button_to(t('deployments.pretty_view_show.reboot'),
reboot_instance_path('replace_id').sub('replace_id', '${id}'),
:disabled => false, :class => 'button danger')}</li>
{{else}}
-<li>#{button_to(t('deployments.pretty_view_show.reboot'),
reboot_instance_path('replace_id').sub('replace_id', '${id}'),
:disabled => true)}</li>
+<li>#{button_to(t('deployments.pretty_view_show.reboot'),
reboot_instance_path('replace_id').sub('replace_id', '${id}'),
:disabled => true, :class => 'button danger')}</li>
{{/if}}
</ul>
</div>
diff --git a/src/public/stylesheets/layout_ie7.css
b/src/public/stylesheets/layout_ie7.css
index 012ca6d..6dc8fd9 100644
--- a/src/public/stylesheets/layout_ie7.css
+++ b/src/public/stylesheets/layout_ie7.css
@@ -28,3 +28,20 @@ dl.user_stats ul li{
float: left;
width: 180px;
}
+
+/* fix the separator colour in the Instance pretty view cards */
+#content ul.instances-array li.instance hr {
+ height: 2px;
+}
+
+/* center the Stop/Restart buttons in the Instance pretty view cards */
+#content li.instance .actions {
+ text-align: center;
+}
+#content li.instance .actions * {
+ text-align: left;
+}
+#content li.instance .actions ul {
+ zoom: 1;
+ display: inline;
+}
ACK