Skip to content

Commit

Permalink
Allow to pause\resume multiple containers providers at a time
Browse files Browse the repository at this point in the history
  • Loading branch information
Ari Zellner committed Nov 5, 2017
1 parent dcb4496 commit fda3e99
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 4 deletions.
10 changes: 6 additions & 4 deletions app/helpers/application_helper/toolbar/ems_container_center.rb
Original file line number Diff line number Diff line change
Expand Up @@ -28,16 +28,18 @@ class ApplicationHelper::Toolbar::EmsContainerCenter < ApplicationHelper::Toolba
'pficon pficon-trend-up fa-lg',
t = N_('Resume this Containers Provider'),
t,
:confirm => N_("Resume this Containers Provider?"),
:enabled => proc { !@record.enabled? }),
:confirm => N_("Resume this Containers Provider?"),
:enabled => proc { !@record.enabled? },
:url_parms => "main_div"),
button(
:ems_container_pause,
'pficon pficon-trend-down fa-lg',
t = N_('Pause this Containers Provider'),
t,
:confirm => N_("Warning: While this provider is paused no data will be collected from it. " \
:confirm => N_("Warning: While this provider is paused no data will be collected from it. " \
"This may cause gaps in inventory, metrics and events!"),
:enabled => proc { @record.enabled? }),
:enabled => proc { @record.enabled? },
:url_parms => "main_div"),
button(
:ems_container_delete,
'pficon pficon-delete fa-lg',
Expand Down
19 changes: 19 additions & 0 deletions app/helpers/application_helper/toolbar/ems_containers_center.rb
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,25 @@ class ApplicationHelper::Toolbar::EmsContainersCenter < ApplicationHelper::Toolb
:send_checked => true,
:enabled => false,
:onwhen => "1"),
button(
:ems_container_resume,
'pficon pficon-trend-up fa-lg',
t = N_('Resume selected Containers Providers'),
t,
:confirm => N_("Resume these Containers Providers?"),
:enabled => false,
:url_parms => "main_div",
:onwhen => "1+"),
button(
:ems_container_pause,
'pficon pficon-trend-down fa-lg',
t = N_('Pause selected Containers Providers'),
t,
:confirm => N_("Warning: While these providers are paused no data will be collected from them. " \
"This may cause gaps in inventory, metrics and events!"),
:enabled => false,
:url_parms => "main_div",
:onwhen => "1+"),
button(
:ems_container_delete,
'pficon pficon-delete fa-lg',
Expand Down

0 comments on commit fda3e99

Please sign in to comment.