forked from ManageIQ/manageiq
/
ems_infra_center.rb
101 lines (101 loc) · 3.31 KB
/
ems_infra_center.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
class ApplicationHelper::Toolbar::EmsInfraCenter < ApplicationHelper::Toolbar::Basic
button_group('ems_infra_vmdb', [
button(
:refresh_server_summary,
'fa fa-repeat fa-lg',
N_('Reload Current Display'),
nil),
select(
:ems_infra_vmdb_choice,
'fa fa-cog fa-lg',
t = N_('Configuration'),
t,
:items => [
button(
:ems_infra_refresh,
'fa fa-refresh fa-lg',
N_('Refresh relationships and power states for all items related to this #{ui_lookup(:table=>"ems_infra")}'),
N_('Refresh Relationships and Power States'),
:confirm => N_("Refresh relationships and power states for all items related to this \#{ui_lookup(:table=>\"ems_infra\")}?")),
separator,
button(
:ems_infra_edit,
'pficon pficon-edit fa-lg',
t = N_('Edit this #{ui_lookup(:table=>"ems_infra")}'),
t),
button(
:ems_infra_scale,
'pficon pficon-edit fa-lg',
t = N_('Scale this #{ui_lookup(:table=>"ems_infra")}'),
t,
:url => "/scaling"),
button(
:ems_infra_scaledown,
'pficon pficon-edit fa-lg',
t = N_('Scale this #{ui_lookup(:table=>"ems_infra")} down'),
t,
:url => "/scaledown"),
button(
:ems_infra_delete,
'pficon pficon-delete fa-lg',
t = N_('Remove this #{ui_lookup(:table=>"ems_infra")} from the VMDB'),
t,
:url_parms => "&refresh=y",
:confirm => N_("Warning: This \#{ui_lookup(:table=>\"ems_infra\")} and ALL of its components will be permanently removed from the Virtual Management Database. Are you sure you want to remove this \#{ui_lookup(:table=>\"ems_infra\")}?")),
]
),
])
button_group('ems_infra_policy', [
select(
:ems_infra_policy_choice,
'fa fa-shield fa-lg',
t = N_('Policy'),
t,
:items => [
button(
:ems_infra_protect,
'pficon pficon-edit fa-lg',
N_('Manage Policies for this #{ui_lookup(:table=>"ems_infra")}'),
N_('Manage Policies')),
button(
:ems_infra_tag,
'pficon pficon-edit fa-lg',
N_('Edit Tags for this #{ui_lookup(:table=>"ems_infra")}'),
N_('Edit Tags')),
]
),
])
button_group('ems_infra_monitoring', [
select(
:ems_infra_monitoring_choice,
'product product-monitoring fa-lg',
t = N_('Monitoring'),
t,
:items => [
button(
:ems_infra_timeline,
'product product-timeline fa-lg',
N_('Show Timelines for this #{ui_lookup(:table=>"ems_infra")}'),
N_('Timelines'),
:klass => ApplicationHelper::Button::EmsInfraTimeline,
:url_parms => "?display=timeline"),
]
),
])
button_group('ems_infra_authentication', [
select(
:ems_infra_authentication_choice,
'fa fa-lock fa-lg',
t = N_('Authentication'),
t,
:items => [
button(
:ems_infra_recheck_auth_status,
'fa fa-search fa-lg',
N_('Re-check Authentication Status for this #{ui_lookup(:table=>"ems_infra")}'),
N_('Re-check Authentication Status'),
:klass => ApplicationHelper::Button::EmsInfraRecheckAuthStatus),
]
),
])
end