foreman_datacenter 1.19.4 → 1.19.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/app/assets/javascripts/foreman_datacenter/modal.js +10 -4
- data/app/views/foreman_datacenter/device_roles/index.html.erb +1 -1
- data/app/views/foreman_datacenter/device_roles/show.html.erb +1 -1
- data/app/views/foreman_datacenter/device_types/index.html.erb +1 -1
- data/app/views/foreman_datacenter/device_types/show.html.erb +1 -1
- data/app/views/foreman_datacenter/devices/_interface.html.erb +6 -0
- data/app/views/foreman_datacenter/devices/index.html.erb +1 -1
- data/app/views/foreman_datacenter/devices/show.html.erb +1 -1
- data/app/views/foreman_datacenter/manufacturers/index.html.erb +1 -1
- data/app/views/foreman_datacenter/manufacturers/show.html.erb +1 -1
- data/app/views/foreman_datacenter/platforms/index.html.erb +1 -1
- data/app/views/foreman_datacenter/platforms/show.html.erb +1 -1
- data/lib/foreman_datacenter/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3379f15bc6b2cdd363625a0bf9fdeef9ec6faf0cd09448afe36dcb833da5dfcb
|
4
|
+
data.tar.gz: 1ffa1280a6d03ffb2e7a53af1abff6399f11a2d4c216e8a8d400fc257c2ffb7e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fa8feef431143d629cdc55f9487f390b051fbd917d2d190fa8b874636913e57461b09a5f4aaf18ef231fa5343940c9a9dde2a7d48de8d4d4460dc8830339f9e1
|
7
|
+
data.tar.gz: 5e40dc171c0284703efc741cbb1febb2948c726b2f5bbe566b3d1c0e109377ec23b325abda30e05506c70a6a93b482559548281183cd26f821240302230daccb
|
@@ -8,7 +8,7 @@ $(window).click(function(event) {
|
|
8
8
|
var pathname = window.location.pathname; // Returns path only
|
9
9
|
var str = "/" + object_id;
|
10
10
|
var patt = new RegExp(str);
|
11
|
-
|
11
|
+
var token = $('meta[name="csrf-token"]').attr('content');
|
12
12
|
if (object_type == 'device') {
|
13
13
|
var checkbox_label = 'Delete associated host ONLY and keep current device as UNASSIGNED!'
|
14
14
|
} else {
|
@@ -19,6 +19,12 @@ $(window).click(function(event) {
|
|
19
19
|
pathname = pathname + str
|
20
20
|
}
|
21
21
|
|
22
|
+
var move = "<p></p>"
|
23
|
+
if (object_type == "device" || object_type == "site" || object_type == "rack" || object_type == "rack_group") {
|
24
|
+
move = '<p>You also can move associated object to another <strong>' + object_type + '</strong> before you destroy it.</p> \
|
25
|
+
<a class="btn btn-block btn-primary modal-btn modal-btn-primary marginbottomsixteen" href="/datacenter/' + object_type + 's/' + object_id + '/move">Move associated objects</a>'
|
26
|
+
}
|
27
|
+
|
22
28
|
var form = '<div id="myModal" class="modal"> \
|
23
29
|
<div class="modal-content"> \
|
24
30
|
<div class="modal-header"> \
|
@@ -34,17 +40,17 @@ $(window).click(function(event) {
|
|
34
40
|
be undone. By unselecting checkbox you will permanently delete the \
|
35
41
|
<strong>' + object_name + '</strong> \
|
36
42
|
with \
|
37
|
-
<strong>
|
43
|
+
<strong>ALL</strong> \
|
38
44
|
associated objects' + ao + ' \
|
39
45
|
</p> \
|
40
46
|
<form class="modal-form nonpaddingbottom" action=' + pathname + ' accept-charset="UTF-8" method="post"> \
|
41
47
|
<input type="hidden" name="_method" value="delete"> \
|
48
|
+
<input type="hidden" name="authenticity_token" value=' + token + '> \
|
42
49
|
<input type="checkbox" name="object_only" id="object_only" value="true" checked="checked"> \
|
43
50
|
<label>' + checkbox_label + '</label> \
|
44
51
|
<input type="submit" name="commit" value="I understand the consequences, delete this ' + object_type + '" class="btn btn-block btn-danger modal-btn modal-btn-danger"> \
|
45
52
|
</form> \
|
46
|
-
|
47
|
-
<a class="btn btn-block btn-primary modal-btn modal-btn-primary marginbottomsixteen" href="/datacenter/' + object_type + 's/' + object_id + '/move">Move associated objects</a> \
|
53
|
+
'+ move +' \
|
48
54
|
</div> \
|
49
55
|
</div> \
|
50
56
|
</div>'
|
@@ -28,7 +28,7 @@
|
|
28
28
|
hash_for_edit_device_role_path(:id => device_role).merge(:auth_object => device_role, :authorizer => authorizer)
|
29
29
|
),
|
30
30
|
display_fake_delete_if_authorized(
|
31
|
-
|
31
|
+
hash_for_device_role_path(:id => device_role).merge(:auth_object => device_role, :authorizer => authorizer),
|
32
32
|
id: 'init-modal',
|
33
33
|
href: '#',
|
34
34
|
data: { objecttype: 'device_role',
|
@@ -34,7 +34,7 @@
|
|
34
34
|
hash_for_edit_device_type_path(:id => device_type).merge(:auth_object => device_type, :authorizer => authorizer)
|
35
35
|
),
|
36
36
|
display_fake_delete_if_authorized(
|
37
|
-
|
37
|
+
hash_for_device_type_path(:id => device_type).merge(:auth_object => device_type, :authorizer => authorizer),
|
38
38
|
id: 'init-modal',
|
39
39
|
href: '#',
|
40
40
|
data: { objecttype: 'device_type',
|
@@ -14,6 +14,11 @@
|
|
14
14
|
<td>
|
15
15
|
<%= h interface.connected_interface.name %>
|
16
16
|
</td>
|
17
|
+
<td>
|
18
|
+
<%= h interface.connection.id %>
|
19
|
+
-
|
20
|
+
<%= h interface.form_factor %>
|
21
|
+
</td>
|
17
22
|
<td></td>
|
18
23
|
<td class="text-right">
|
19
24
|
<% if interface.connection.planned? %>
|
@@ -56,6 +61,7 @@
|
|
56
61
|
<td></td>
|
57
62
|
<td class="text-muted">Not connected</td>
|
58
63
|
<td></td>
|
64
|
+
<td></td>
|
59
65
|
<td class="text-right">
|
60
66
|
<%= link_to new_device_interface_device_interface_connection_path(interface),
|
61
67
|
class: 'btn btn-success btn-xs', title: 'Connect' do %>
|
@@ -55,7 +55,7 @@
|
|
55
55
|
hash_for_edit_device_path(:id => device).merge(:auth_object => device, :authorizer => authorizer)
|
56
56
|
),
|
57
57
|
display_fake_delete_if_authorized(
|
58
|
-
|
58
|
+
hash_for_device_path(:id => device).merge(:auth_object => device, :authorizer => authorizer),
|
59
59
|
id: 'init-modal',
|
60
60
|
href: '#',
|
61
61
|
data: { objecttype: 'device',
|
@@ -30,7 +30,7 @@
|
|
30
30
|
hash_for_edit_manufacturer_path(:id => manufacturer).merge(:auth_object => manufacturer, :authorizer => authorizer)
|
31
31
|
),
|
32
32
|
display_fake_delete_if_authorized(
|
33
|
-
|
33
|
+
hash_for_manufacturer_path(:id => manufacturer).merge(:auth_object => manufacturer, :authorizer => authorizer),
|
34
34
|
id: 'init-modal',
|
35
35
|
href: '#',
|
36
36
|
data: { objecttype: 'manufacturer',
|
@@ -28,7 +28,7 @@
|
|
28
28
|
hash_for_edit_platform_path(:id => platform).merge(:auth_object => platform, :authorizer => authorizer)
|
29
29
|
),
|
30
30
|
display_fake_delete_if_authorized(
|
31
|
-
|
31
|
+
hash_for_platform_path(:id => platform).merge(:auth_object => platform, :authorizer => authorizer),
|
32
32
|
id: 'init-modal',
|
33
33
|
href: '#',
|
34
34
|
data: { objecttype: 'platform',
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: foreman_datacenter
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.19.
|
4
|
+
version: 1.19.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Pavel Ivanov
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2019-
|
12
|
+
date: 2019-06-25 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: prawn
|