Skip to content

Commit

Permalink
Merge pull request ManageIQ#829 from hayesr/fix_diag_zone_screen
Browse files Browse the repository at this point in the history
Fix delete button under Configuration > Diagnostics
  • Loading branch information
mzazrivec authored Mar 29, 2017
2 parents 0f28507 + a7582ed commit d3f69ab
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion app/controllers/ops_controller/diagnostics.rb
Original file line number Diff line number Diff line change
Expand Up @@ -801,7 +801,7 @@ def reload_server_tree
def diagnostics_set_form_vars
active_node = x_node
if active_node && active_node.split('-').first == "z"
@record = @selected_server = Zone.find_by_id(from_cid(active_node.split('-').last))
@record = @selected_zone = @selected_server = Zone.find_by_id(from_cid(active_node.split('-').last))
@sb[:selected_server_id] = @selected_server.id
@sb[:selected_typ] = "zone"
if @selected_server.miq_servers.length >= 1 &&
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,19 +15,19 @@ class ApplicationHelper::Toolbar::DiagnosticsZoneCenter < ApplicationHelper::Too
t,
:items => [
button(
:zone_delete_server,
:zone_delete,
'pficon pficon-delete fa-lg',
t = proc do
_('Delete Server %{server_name} [%{server_id}]') % {:server_name => @record.name, :server_id => @record.id}
_('Delete Zone %{server_name} [%{server_id}]') % {:server_name => @selected_zone.name, :server_id => @selected_zone.id}
end,
t,
:confirm => proc do
_("Do you want to delete Server %{server_name} [%{server_id}]?") % {
:server_name => @record.name,
:server_id => @record.id
_("Do you want to delete Zone %{server_name} [%{server_id}]?") % {
:server_name => @selected_zone.name,
:server_id => @selected_zone.id
}
end,
:klass => ApplicationHelper::Button::ZoneDeleteServer
:klass => ApplicationHelper::Button::ZoneDelete
),
button(
:zone_role_start,
Expand Down

0 comments on commit d3f69ab

Please sign in to comment.