Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
Rafael Monnerat
slapos.core
Commits
53cda406
Commit
53cda406
authored
Jun 13, 2022
by
Rafael Monnerat
👻
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
slapos_jio: Unify status gadget
parent
73332133
Pipeline
#22421
failed with stage
Changes
29
Pipelines
2
Show whitespace changes
Inline
Side-by-side
Showing
29 changed files
with
219 additions
and
2765 deletions
+219
-2765
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_compute_node_view_js.js
..._module/rjs_gadget_erp5_page_slap_compute_node_view_js.js
+1
-1
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_compute_node_view_js.xml
...module/rjs_gadget_erp5_page_slap_compute_node_view_js.xml
+1
-1
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_instance_tree_view_js.js
...module/rjs_gadget_erp5_page_slap_instance_tree_view_js.js
+3
-3
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_instance_tree_view_js.xml
...odule/rjs_gadget_erp5_page_slap_instance_tree_view_js.xml
+2
-2
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_project_view_js.js
..._page_module/rjs_gadget_erp5_page_slap_project_view_js.js
+1
-1
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_project_view_js.xml
...page_module/rjs_gadget_erp5_page_slap_project_view_js.xml
+2
-2
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_service_list_js.js
..._page_module/rjs_gadget_erp5_page_slap_service_list_js.js
+1
-1
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_service_list_js.xml
...page_module/rjs_gadget_erp5_page_slap_service_list_js.xml
+2
-2
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_software_installation_view_js.js
...js_gadget_erp5_page_slap_software_installation_view_js.js
+1
-1
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_software_installation_view_js.xml
...s_gadget_erp5_page_slap_software_installation_view_js.xml
+2
-2
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_software_instance_view_js.xml
...e/rjs_gadget_erp5_page_slap_software_instance_view_js.xml
+2
-2
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_installation_status_html.html
...ge_module/rjs_gadget_slapos_installation_status_html.html
+0
-32
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_installation_status_html.xml
...age_module/rjs_gadget_slapos_installation_status_html.xml
+0
-374
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_installation_status_js.js
...b_page_module/rjs_gadget_slapos_installation_status_js.js
+0
-96
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_installation_status_js.xml
..._page_module/rjs_gadget_slapos_installation_status_js.xml
+0
-359
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_instance_status_html.html
...b_page_module/rjs_gadget_slapos_instance_status_html.html
+0
-36
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_instance_status_html.xml
...eb_page_module/rjs_gadget_slapos_instance_status_html.xml
+0
-374
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_instance_status_js.js
...m/web_page_module/rjs_gadget_slapos_instance_status_js.js
+0
-123
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_instance_status_js.xml
.../web_page_module/rjs_gadget_slapos_instance_status_js.xml
+0
-359
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_instance_tree_status_html.html
...e_module/rjs_gadget_slapos_instance_tree_status_html.html
+0
-36
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_instance_tree_status_html.xml
...ge_module/rjs_gadget_slapos_instance_tree_status_html.xml
+0
-374
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_instance_tree_status_js.js
..._page_module/rjs_gadget_slapos_instance_tree_status_js.js
+0
-171
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_instance_tree_status_js.xml
...page_module/rjs_gadget_slapos_instance_tree_status_js.xml
+0
-359
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_status_css.css
...lateItem/web_page_module/rjs_gadget_slapos_status_css.css
+4
-0
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_status_css.xml
...lateItem/web_page_module/rjs_gadget_slapos_status_css.xml
+2
-2
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_status_js.js
...mplateItem/web_page_module/rjs_gadget_slapos_status_js.js
+193
-38
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_status_js.xml
...plateItem/web_page_module/rjs_gadget_slapos_status_js.xml
+2
-2
master/bt5/slapos_jio/bt/template_keep_last_workflow_history_only_path_list
...jio/bt/template_keep_last_workflow_history_only_path_list
+0
-6
master/bt5/slapos_jio/bt/template_path_list
master/bt5/slapos_jio/bt/template_path_list
+0
-6
No files found.
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_compute_node_view_js.js
View file @
53cda406
...
@@ -38,7 +38,7 @@
...
@@ -38,7 +38,7 @@
hidden
:
0
,
hidden
:
0
,
"
default
"
:
{
jio_key
:
value
,
result
:
value
},
"
default
"
:
{
jio_key
:
value
,
result
:
value
},
key
:
"
status
"
,
key
:
"
status
"
,
url
:
"
gadget_slapos_
installation_
status.html
"
,
url
:
"
gadget_slapos_status.html
"
,
title
:
"
Status
"
,
title
:
"
Status
"
,
type
:
"
GadgetField
"
type
:
"
GadgetField
"
}
}
...
...
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_compute_node_view_js.xml
View file @
53cda406
...
@@ -281,7 +281,7 @@
...
@@ -281,7 +281,7 @@
</tuple>
</tuple>
<state>
<state>
<tuple>
<tuple>
<float>
165
4875173.93
</float>
<float>
165
5115844.0
</float>
<string>
UTC
</string>
<string>
UTC
</string>
</tuple>
</tuple>
</state>
</state>
...
...
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_instance_tree_view_js.js
View file @
53cda406
...
@@ -39,7 +39,7 @@
...
@@ -39,7 +39,7 @@
hidden
:
0
,
hidden
:
0
,
"
default
"
:
{
jio_key
:
jio_key_value
,
result
:
value
},
"
default
"
:
{
jio_key
:
jio_key_value
,
result
:
value
},
key
:
"
status
"
,
key
:
"
status
"
,
url
:
"
gadget_slapos_
instance_
status.html
"
,
url
:
"
gadget_slapos_status.html
"
,
title
:
gadget
.
title_translation
,
title
:
gadget
.
title_translation
,
type
:
"
GadgetField
"
type
:
"
GadgetField
"
}
}
...
@@ -357,11 +357,11 @@
...
@@ -357,11 +357,11 @@
"
description
"
:
""
,
"
description
"
:
""
,
"
title
"
:
result
[
1
][
23
],
"
title
"
:
result
[
1
][
23
],
"
default
"
:
{
jio_key
:
gadget
.
state
.
jio_key
,
"
default
"
:
{
jio_key
:
gadget
.
state
.
jio_key
,
result
:
gadget
.
state
.
doc
.
news
},
result
:
gadget
.
state
.
doc
},
"
css_class
"
:
""
,
"
css_class
"
:
""
,
"
required
"
:
0
,
"
required
"
:
0
,
"
editable
"
:
0
,
"
editable
"
:
0
,
"
url
"
:
"
gadget_slapos_
instance_tree_
status.html
"
,
"
url
"
:
"
gadget_slapos_status.html
"
,
"
sandbox
"
:
""
,
"
sandbox
"
:
""
,
"
key
"
:
"
monitoring_status
"
,
"
key
"
:
"
monitoring_status
"
,
"
hidden
"
:
0
,
"
hidden
"
:
0
,
...
...
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_instance_tree_view_js.xml
View file @
53cda406
...
@@ -236,7 +236,7 @@
...
@@ -236,7 +236,7 @@
</item>
</item>
<item>
<item>
<key>
<string>
serial
</string>
</key>
<key>
<string>
serial
</string>
</key>
<value>
<string>
99
2.39464.63395.50176
</string>
</value>
<value>
<string>
99
9.2068.62564.17
</string>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
state
</string>
</key>
<key>
<string>
state
</string>
</key>
...
@@ -254,7 +254,7 @@
...
@@ -254,7 +254,7 @@
</tuple>
</tuple>
<state>
<state>
<tuple>
<tuple>
<float>
16
23227290.36
</float>
<float>
16
55115718.45
</float>
<string>
UTC
</string>
<string>
UTC
</string>
</tuple>
</tuple>
</state>
</state>
...
...
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_project_view_js.js
View file @
53cda406
...
@@ -63,7 +63,7 @@
...
@@ -63,7 +63,7 @@
hidden
:
0
,
hidden
:
0
,
"
default
"
:
{
jio_key
:
value_jio_key
,
result
:
value
},
"
default
"
:
{
jio_key
:
value_jio_key
,
result
:
value
},
key
:
"
status
"
,
key
:
"
status
"
,
url
:
"
gadget_slapos_
instance_tree_
status.html
"
,
url
:
"
gadget_slapos_status.html
"
,
title
:
gadget
.
title_translation
,
title
:
gadget
.
title_translation
,
type
:
"
GadgetField
"
type
:
"
GadgetField
"
}
}
...
...
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_project_view_js.xml
View file @
53cda406
...
@@ -247,7 +247,7 @@
...
@@ -247,7 +247,7 @@
</item>
</item>
<item>
<item>
<key>
<string>
serial
</string>
</key>
<key>
<string>
serial
</string>
</key>
<value>
<string>
1000.
31175.43828.12919
</string>
</value>
<value>
<string>
1000.
54051.30712.44322
</string>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
state
</string>
</key>
<key>
<string>
state
</string>
</key>
...
@@ -265,7 +265,7 @@
...
@@ -265,7 +265,7 @@
</tuple>
</tuple>
<state>
<state>
<tuple>
<tuple>
<float>
165
4875088.05
</float>
<float>
165
5115677.76
</float>
<string>
UTC
</string>
<string>
UTC
</string>
</tuple>
</tuple>
</state>
</state>
...
...
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_service_list_js.js
View file @
53cda406
...
@@ -30,7 +30,7 @@
...
@@ -30,7 +30,7 @@
hidden
:
0
,
hidden
:
0
,
default
:
{
jio_key
:
value
,
result
:
news
},
default
:
{
jio_key
:
value
,
result
:
news
},
key
:
"
status
"
,
key
:
"
status
"
,
url
:
"
gadget_slapos_
instance_tree_
status.html
"
,
url
:
"
gadget_slapos_status.html
"
,
type
:
"
GadgetField
"
type
:
"
GadgetField
"
}
}
};
};
...
...
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_service_list_js.xml
View file @
53cda406
...
@@ -236,7 +236,7 @@
...
@@ -236,7 +236,7 @@
</item>
</item>
<item>
<item>
<key>
<string>
serial
</string>
</key>
<key>
<string>
serial
</string>
</key>
<value>
<string>
99
1.63523.46105.2850
</string>
</value>
<value>
<string>
99
9.2068.62564.17
</string>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
state
</string>
</key>
<key>
<string>
state
</string>
</key>
...
@@ -254,7 +254,7 @@
...
@@ -254,7 +254,7 @@
</tuple>
</tuple>
<state>
<state>
<tuple>
<tuple>
<float>
16
21432757.5
</float>
<float>
16
55115655.51
</float>
<string>
UTC
</string>
<string>
UTC
</string>
</tuple>
</tuple>
</state>
</state>
...
...
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_software_installation_view_js.js
View file @
53cda406
...
@@ -157,7 +157,7 @@
...
@@ -157,7 +157,7 @@
"
css_class
"
:
""
,
"
css_class
"
:
""
,
"
required
"
:
1
,
"
required
"
:
1
,
"
editable
"
:
0
,
"
editable
"
:
0
,
"
url
"
:
"
gadget_slapos_
installation_
status.html
"
,
"
url
"
:
"
gadget_slapos_status.html
"
,
"
sandbox
"
:
""
,
"
sandbox
"
:
""
,
"
key
"
:
"
monitoring_status
"
,
"
key
"
:
"
monitoring_status
"
,
"
hidden
"
:
0
,
"
hidden
"
:
0
,
...
...
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_software_installation_view_js.xml
View file @
53cda406
...
@@ -236,7 +236,7 @@
...
@@ -236,7 +236,7 @@
</item>
</item>
<item>
<item>
<key>
<string>
serial
</string>
</key>
<key>
<string>
serial
</string>
</key>
<value>
<string>
9
87.11768.7153.56183
</string>
</value>
<value>
<string>
9
99.2068.62564.17
</string>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
state
</string>
</key>
<key>
<string>
state
</string>
</key>
...
@@ -254,7 +254,7 @@
...
@@ -254,7 +254,7 @@
</tuple>
</tuple>
<state>
<state>
<tuple>
<tuple>
<float>
16
02256822.25
</float>
<float>
16
55115861.91
</float>
<string>
UTC
</string>
<string>
UTC
</string>
</tuple>
</tuple>
</state>
</state>
...
...
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_software_instance_view_js.xml
View file @
53cda406
...
@@ -236,7 +236,7 @@
...
@@ -236,7 +236,7 @@
</item>
</item>
<item>
<item>
<key>
<string>
serial
</string>
</key>
<key>
<string>
serial
</string>
</key>
<value>
<string>
1000.
41365.5795.26487
</string>
</value>
<value>
<string>
1000.
58063.29277.1706
</string>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
state
</string>
</key>
<key>
<string>
state
</string>
</key>
...
@@ -254,7 +254,7 @@
...
@@ -254,7 +254,7 @@
</tuple>
</tuple>
<state>
<state>
<tuple>
<tuple>
<float>
165
4159125.9
</float>
<float>
165
5115820.43
</float>
<string>
UTC
</string>
<string>
UTC
</string>
</tuple>
</tuple>
</state>
</state>
...
...
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_installation_status_html.html
deleted
100644 → 0
View file @
73332133
<!DOCTYPE html>
<html>
<head>
<meta
charset=
"utf-8"
>
<meta
name=
"viewport"
content=
"width=device-width, initial-scale=1"
>
<title>
Background
</title>
<script
src=
"rsvp.js"
></script>
<script
src=
"renderjs.js"
></script>
<script
src=
"handlebars.js"
></script>
<script
src=
"gadget_slapos_installation_status.js"
></script>
<link
href=
"gadget_slapos_compute_node_status.css"
rel=
"stylesheet"
type=
"text/css"
/>
<script
id=
"inline-status-template"
type=
"text/x-handlebars-template"
>
<
div
class
=
"
ui-block-a
"
style
=
"
width:50%
"
><
div
class
=
"
ui-bar ui-corner-all first-child {{status_class}}
"
style
=
"
{{status_style}}
"
>
{{
status_title
}}
<
/div></
div
>
<
div
class
=
"
ui-block-c
"
style
=
"
width:50%
"
><
div
class
=
"
ui-bar ui-corner-all last-child {{right_class}}
"
style
=
"
{{right_style}}
"
>
{{
right_title
}}
<
/div></
div
>
</script>
<script
id=
"loading-template"
type=
"text/x-handlebars-template"
>
<
button
data
-
i18n
=
"
loading
"
type
=
"
submit
"
class
=
"
responsive ui-btn ui-icon-spinner ui-icon-spin ui-btn-icon-center ui-disabled
"
style
=
"
border:none;
"
>
loading
<
/button
>
</script>
</head>
<body>
<div
class=
"ui-block-a"
style=
"width:50%"
>
<div
class=
"ui-bar ui-corner-all first-child ui-btn-no-data"
>
<a
class=
"ui-btn ui-btn-icon-left ui-icon-spinner"
style=
"color: white !important;"
>
Installations
</a>
</div>
</div>
</body>
</html>
\ No newline at end of file
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_installation_status_html.xml
deleted
100644 → 0
View file @
73332133
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"Web Page"
module=
"erp5.portal_type"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_Access_contents_information_Permission
</string>
</key>
<value>
<tuple>
<string>
Anonymous
</string>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Auditor
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Add_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Change_local_roles_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Copy_or_Move_Permission
</string>
</key>
<value>
<list>
<string>
Manager
</string>
<string>
Authenticated
</string>
<string>
Developer
</string>
<string>
Owner
</string>
</list>
</value>
</item>
<item>
<key>
<string>
_Modify_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_View_Permission
</string>
</key>
<value>
<tuple>
<string>
Anonymous
</string>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Auditor
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
content_md5
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
content_type
</string>
</key>
<value>
<string>
text/html
</string>
</value>
</item>
<item>
<key>
<string>
creators
</string>
</key>
<value>
<tuple>
<string>
zope
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
gadget_slapos_installation_status.html
</string>
</value>
</item>
<item>
<key>
<string>
description
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
rjs_gadget_slapos_installation_status_html
</string>
</value>
</item>
<item>
<key>
<string>
language
</string>
</key>
<value>
<string>
en
</string>
</value>
</item>
<item>
<key>
<string>
modification_date
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1523884656.9
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
portal_type
</string>
</key>
<value>
<string>
Web Page
</string>
</value>
</item>
<item>
<key>
<string>
short_title
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
<value>
<string>
Gadget SlapOS Installation Status
</string>
</value>
</item>
<item>
<key>
<string>
version
</string>
</key>
<value>
<string>
001
</string>
</value>
</item>
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary>
<item>
<key>
<string>
document_publication_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAM=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
edit_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAQ=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
processing_status_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAU=
</string>
</persistent>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
publish_alive
</string>
</value>
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
zope
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
error_message
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
time
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1509980695.62
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
validation_state
</string>
</key>
<value>
<string>
published_alive
</string>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"4"
aka=
"AAAAAAAAAAQ="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
edit
</string>
</value>
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
zope
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
error_message
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
966.58781.43824.3635
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
<value>
<string>
current
</string>
</value>
</item>
<item>
<key>
<string>
time
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1530120100.87
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"5"
aka=
"AAAAAAAAAAU="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
detect_converted_file
</string>
</value>
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
zope
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
error_message
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
external_processing_state
</string>
</key>
<value>
<string>
converted
</string>
</value>
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
0.0.0.0
</string>
</value>
</item>
<item>
<key>
<string>
time
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1509980663.78
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_installation_status_js.js
deleted
100644 → 0
View file @
73332133
/*globals console, window, rJS, RSVP, loopEventListener, i18n, Handlebars, $*/
/*jslint indent: 2, nomen: true, maxlen: 80*/
(
function
(
window
,
rJS
,
RSVP
,
Handlebars
)
{
"
use strict
"
;
var
gadget_klass
=
rJS
(
window
),
inline_status_source
=
gadget_klass
.
__template_element
.
getElementById
(
"
inline-status-template
"
)
.
innerHTML
,
inline_status_template
=
Handlebars
.
compile
(
inline_status_source
);
function
checkInstallationStatus
(
options
)
{
if
((
!
options
)
||
(
options
&&
!
options
.
news
))
{
return
'
ui-btn-no-data
'
;
}
if
(
options
.
news
.
text
.
startsWith
(
"
#access
"
))
{
return
'
ui-btn-ok
'
;
}
else
if
(
options
.
news
.
text
.
startsWith
(
"
#building
"
))
{
return
'
ui-btn-warning
'
;
}
else
{
if
(
options
.
no_data
)
{
return
'
ui-btn-no-data
'
;
}
return
'
ui-btn-error
'
;
}
}
function
getStatus
(
gadget
)
{
return
new
RSVP
.
Queue
()
.
push
(
function
()
{
return
gadget
.
jio_get
(
gadget
.
options
.
value
.
jio_key
);
})
.
push
(
function
(
result
)
{
var
status_class
=
'
ui-btn-no-data
'
,
status_title
=
'
Installation
'
,
status_style
=
""
;
status_class
=
checkInstallationStatus
(
result
);
if
(
status_class
===
'
ui-btn-no-data
'
)
{
status_style
=
"
color: transparent !important;
"
;
}
gadget
.
element
.
innerHTML
=
inline_status_template
({
status_class
:
status_class
,
status_title
:
status_title
,
status_style
:
status_style
});
return
gadget
;
});
}
gadget_klass
.
ready
(
function
(
gadget
)
{
gadget
.
props
=
{};
return
gadget
.
getSetting
(
"
hateoas_url
"
)
.
push
(
function
(
url
)
{
gadget
.
props
.
hateoas_url
=
url
;
});
})
.
declareAcquiredMethod
(
"
jio_get
"
,
"
jio_get
"
)
.
declareAcquiredMethod
(
"
getSetting
"
,
"
getSetting
"
)
.
declareAcquiredMethod
(
"
translateHtml
"
,
"
translateHtml
"
)
.
declareMethod
(
"
getContent
"
,
function
()
{
return
{};
})
.
declareJob
(
"
getStatus
"
,
function
(
result
)
{
var
gadget
=
this
,
status_class
=
'
ui-btn-no-data
'
,
status_title
=
'
Installation
'
,
status_style
=
""
;
status_class
=
checkInstallationStatus
({
news
:
result
});
if
(
status_class
===
'
ui-btn-no-data
'
)
{
status_style
=
"
color: transparent !important;
"
;
}
gadget
.
element
.
innerHTML
=
inline_status_template
({
status_class
:
status_class
,
status_title
:
status_title
,
status_style
:
status_style
});
return
gadget
;
})
.
onLoop
(
function
()
{
var
gadget
=
this
;
return
getStatus
(
gadget
);
},
300000
)
.
declareMethod
(
"
render
"
,
function
(
options
)
{
var
gadget
=
this
;
gadget
.
options
=
options
;
gadget
.
flag
=
options
.
value
.
jio_key
;
return
gadget
.
getStatus
(
options
.
value
.
result
);
});
}(
window
,
rJS
,
RSVP
,
Handlebars
));
\ No newline at end of file
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_installation_status_js.xml
deleted
100644 → 0
View file @
73332133
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"Web Script"
module=
"erp5.portal_type"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_Access_contents_information_Permission
</string>
</key>
<value>
<tuple>
<string>
Anonymous
</string>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Auditor
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Add_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Change_local_roles_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Modify_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_View_Permission
</string>
</key>
<value>
<tuple>
<string>
Anonymous
</string>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Auditor
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
content_md5
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
creators
</string>
</key>
<value>
<tuple>
<string>
zope
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
gadget_slapos_installation_status.js
</string>
</value>
</item>
<item>
<key>
<string>
description
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
rjs_gadget_slapos_installation_status_js
</string>
</value>
</item>
<item>
<key>
<string>
language
</string>
</key>
<value>
<string>
en
</string>
</value>
</item>
<item>
<key>
<string>
modification_date
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1523884656.94
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
portal_type
</string>
</key>
<value>
<string>
Web Script
</string>
</value>
</item>
<item>
<key>
<string>
short_title
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
<value>
<string>
Gadget SlapOS Installation Status JS
</string>
</value>
</item>
<item>
<key>
<string>
version
</string>
</key>
<value>
<string>
001
</string>
</value>
</item>
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary>
<item>
<key>
<string>
document_publication_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAM=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
edit_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAQ=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
processing_status_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAU=
</string>
</persistent>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
publish_alive
</string>
</value>
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
zope
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
error_message
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
time
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1509981097.66
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
validation_state
</string>
</key>
<value>
<string>
published_alive
</string>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"4"
aka=
"AAAAAAAAAAQ="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
edit
</string>
</value>
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
zope
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
error_message
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
972.38717.20279.51251
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
<value>
<string>
current
</string>
</value>
</item>
<item>
<key>
<string>
time
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1545928626.78
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"5"
aka=
"AAAAAAAAAAU="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
detect_converted_file
</string>
</value>
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
zope
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
error_message
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
external_processing_state
</string>
</key>
<value>
<string>
converted
</string>
</value>
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
0.0.0.0
</string>
</value>
</item>
<item>
<key>
<string>
time
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1509981088.76
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_instance_status_html.html
deleted
100644 → 0
View file @
73332133
<!DOCTYPE html>
<html>
<head>
<meta
charset=
"utf-8"
>
<meta
name=
"viewport"
content=
"width=device-width, initial-scale=1"
>
<title>
Background
</title>
<script
src=
"rsvp.js"
></script>
<script
src=
"renderjs.js"
></script>
<script
src=
"handlebars.js"
></script>
<script
src=
"gadget_slapos_instance_status.js"
></script>
<link
href=
"gadget_slapos_compute_node_status.css"
rel=
"stylesheet"
type=
"text/css"
/>
<script
id=
"inline-status-no-link-template"
type=
"text/x-handlebars-template"
>
<
div
class
=
"
ui-block-a
"
style
=
"
width:50%
"
><
div
class
=
"
ui-bar ui-corner-all first-child {{status_class}}
"
style
=
"
{{status_style}}
"
>
{{
status_title
}}
<
/div></
div
>
</script>
<script
id=
"inline-status-template"
type=
"text/x-handlebars-template"
>
<
div
class
=
"
ui-block-a
"
style
=
"
width:50%
"
><
div
class
=
"
ui-bar ui-corner-all first-child {{status_class}}
"
style
=
"
{{status_style}}
"
>
<
a
class
=
"
ui-btn ui-btn-icon-left ui-icon-desktop
"
href
=
"
{{monitor_url}}
"
target
=
_blank
>
{{
status_title
}}
<
/a></
div
><
/div
>
</script>
<script
id=
"loading-template"
type=
"text/x-handlebars-template"
>
<
button
data
-
i18n
=
"
loading
"
type
=
"
submit
"
class
=
"
responsive ui-btn ui-icon-spinner ui-icon-spin ui-btn-icon-center ui-disabled
"
style
=
"
border:none;
"
>
loading
<
/button
>
</script>
</head>
<body>
<div
class=
"ui-block-a"
style=
"width:50%"
>
<div
class=
"ui-bar ui-corner-all first-child ui-btn-no-data"
>
<a
class=
"ui-btn ui-btn-icon-left ui-icon-spinner"
style=
"color: white !important;"
>
Instance
</a>
</div>
</div>
</body>
</html>
\ No newline at end of file
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_instance_status_html.xml
deleted
100644 → 0
View file @
73332133
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"Web Page"
module=
"erp5.portal_type"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_Access_contents_information_Permission
</string>
</key>
<value>
<tuple>
<string>
Anonymous
</string>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Auditor
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Add_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Change_local_roles_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Copy_or_Move_Permission
</string>
</key>
<value>
<list>
<string>
Manager
</string>
<string>
Authenticated
</string>
<string>
Developer
</string>
<string>
Owner
</string>
</list>
</value>
</item>
<item>
<key>
<string>
_Modify_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_View_Permission
</string>
</key>
<value>
<tuple>
<string>
Anonymous
</string>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Auditor
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
content_md5
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
content_type
</string>
</key>
<value>
<string>
text/html
</string>
</value>
</item>
<item>
<key>
<string>
creators
</string>
</key>
<value>
<tuple>
<string>
zope
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
gadget_slapos_instance_status.html
</string>
</value>
</item>
<item>
<key>
<string>
description
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
rjs_gadget_slapos_instance_status_html
</string>
</value>
</item>
<item>
<key>
<string>
language
</string>
</key>
<value>
<string>
en
</string>
</value>
</item>
<item>
<key>
<string>
modification_date
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1523884657.03
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
portal_type
</string>
</key>
<value>
<string>
Web Page
</string>
</value>
</item>
<item>
<key>
<string>
short_title
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
<value>
<string>
Gadget SlapOS Instance Status
</string>
</value>
</item>
<item>
<key>
<string>
version
</string>
</key>
<value>
<string>
001
</string>
</value>
</item>
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary>
<item>
<key>
<string>
document_publication_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAM=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
edit_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAQ=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
processing_status_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAU=
</string>
</persistent>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
publish_alive
</string>
</value>
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
zope
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
error_message
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
time
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1510068888.36
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
validation_state
</string>
</key>
<value>
<string>
published_alive
</string>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"4"
aka=
"AAAAAAAAAAQ="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
edit
</string>
</value>
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
zope
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
error_message
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
972.32024.53732.34406
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
<value>
<string>
current
</string>
</value>
</item>
<item>
<key>
<string>
time
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1554213561.03
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"5"
aka=
"AAAAAAAAAAU="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
detect_converted_file
</string>
</value>
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
zope
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
error_message
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
external_processing_state
</string>
</key>
<value>
<string>
converted
</string>
</value>
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
0.0.0.0
</string>
</value>
</item>
<item>
<key>
<string>
time
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1510068868.36
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_instance_status_js.js
deleted
100644 → 0
View file @
73332133
/*globals console, window, rJS, RSVP, loopEventListener, i18n, Handlebars, $*/
/*jslint indent: 2, nomen: true, maxlen: 80*/
(
function
(
window
,
rJS
,
RSVP
,
Handlebars
)
{
"
use strict
"
;
var
gadget_klass
=
rJS
(
window
),
inline_status_source
=
gadget_klass
.
__template_element
.
getElementById
(
"
inline-status-template
"
)
.
innerHTML
,
inline_status_template
=
Handlebars
.
compile
(
inline_status_source
),
inline_status_no_link_source
=
gadget_klass
.
__template_element
.
getElementById
(
"
inline-status-no-link-template
"
)
.
innerHTML
,
inline_status_no_link_template
=
Handlebars
.
compile
(
inline_status_no_link_source
);
function
checkInstanceStatus
(
options
)
{
if
((
!
options
)
||
(
options
&&
!
options
.
news
))
{
return
'
ui-btn-no-data
'
;
}
if
(
options
.
news
.
text
.
startsWith
(
"
#access
"
))
{
return
'
ui-btn-ok
'
;
}
else
{
if
(
options
.
news
.
no_data
)
{
return
'
ui-btn-no-data
'
;
}
else
if
(
options
.
news
.
is_slave
)
{
return
'
ui-btn-is-slave
'
;
}
else
if
(
options
.
news
.
is_stopped
)
{
return
'
ui-btn-is-stopped
'
;
}
else
if
(
options
.
news
.
is_destroyed
)
{
return
'
ui-btn-is-destroyed
'
;
}
return
'
ui-btn-error
'
;
}
}
function
getStatus
(
gadget
,
result
)
{
var
status_class
=
'
ui-btn-no-data
'
,
status_title
=
'
Instance
'
,
status_style
=
""
,
monitor_url
,
template
=
inline_status_template
;
monitor_url
=
'
https://monitor.app.officejs.com/#/?page=ojsm_dispatch&query=portal_type%3A%22Software%20Instance%22%20AND%20reference%3A%22
'
+
result
.
reference
+
'
%22
'
;
status_class
=
checkInstanceStatus
(
result
);
if
(
status_class
===
'
ui-btn-is-slave
'
)
{
status_class
=
'
ui-btn-no-data
'
;
status_style
=
"
color: white !important;
"
;
status_title
=
'
Slave
'
;
}
else
if
(
status_class
===
'
ui-btn-is-stopped
'
)
{
status_class
=
'
ui-btn-no-data
'
;
status_style
=
"
color: white !important;
"
;
status_title
=
'
Stopped
'
;
}
else
if
(
status_class
===
'
ui-btn-is-destroyed
'
)
{
status_class
=
'
ui-btn-no-data
'
;
status_style
=
"
color: white !important;
"
;
status_title
=
'
Destroyed
'
;
}
if
(
status_class
===
'
ui-btn-no-data
'
)
{
gadget
.
element
.
innerHTML
=
inline_status_no_link_template
({
status_class
:
status_class
,
status_title
:
status_title
,
status_style
:
status_style
});
}
else
{
gadget
.
element
.
innerHTML
=
inline_status_template
({
monitor_url
:
monitor_url
,
status_class
:
status_class
,
status_title
:
status_title
,
status_style
:
status_style
});
}
return
gadget
;
}
function
getStatusLoop
(
gadget
)
{
return
new
RSVP
.
Queue
()
.
push
(
function
()
{
return
gadget
.
jio_get
(
gadget
.
options
.
value
.
jio_key
);
})
.
push
(
function
(
result
)
{
return
getStatus
(
gadget
,
result
);
});
}
gadget_klass
.
ready
(
function
(
gadget
)
{
gadget
.
props
=
{};
return
gadget
.
getSetting
(
"
hateoas_url
"
)
.
push
(
function
(
url
)
{
gadget
.
props
.
hateoas_url
=
url
;
});
})
.
declareAcquiredMethod
(
"
jio_get
"
,
"
jio_get
"
)
.
declareAcquiredMethod
(
"
getSetting
"
,
"
getSetting
"
)
.
declareAcquiredMethod
(
"
translateHtml
"
,
"
translateHtml
"
)
.
declareMethod
(
"
getContent
"
,
function
()
{
return
{};
})
.
declareJob
(
"
getStatus
"
,
function
(
result
)
{
var
gadget
=
this
;
return
getStatus
(
gadget
,
{
news
:
result
});
})
.
onLoop
(
function
()
{
var
gadget
=
this
;
return
getStatusLoop
(
gadget
);
},
300000
)
.
declareMethod
(
"
render
"
,
function
(
options
)
{
var
gadget
=
this
;
gadget
.
options
=
options
;
gadget
.
flag
=
options
.
value
.
jio_key
;
return
gadget
.
getStatus
(
options
.
value
.
result
);
});
}(
window
,
rJS
,
RSVP
,
Handlebars
));
\ No newline at end of file
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_instance_status_js.xml
deleted
100644 → 0
View file @
73332133
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"Web Script"
module=
"erp5.portal_type"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_Access_contents_information_Permission
</string>
</key>
<value>
<tuple>
<string>
Anonymous
</string>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Auditor
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Add_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Change_local_roles_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Modify_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_View_Permission
</string>
</key>
<value>
<tuple>
<string>
Anonymous
</string>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Auditor
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
content_md5
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
creators
</string>
</key>
<value>
<tuple>
<string>
zope
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
gadget_slapos_instance_status.js
</string>
</value>
</item>
<item>
<key>
<string>
description
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
rjs_gadget_slapos_instance_status_js
</string>
</value>
</item>
<item>
<key>
<string>
language
</string>
</key>
<value>
<string>
en
</string>
</value>
</item>
<item>
<key>
<string>
modification_date
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1523884657.06
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
portal_type
</string>
</key>
<value>
<string>
Web Script
</string>
</value>
</item>
<item>
<key>
<string>
short_title
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
<value>
<string>
Gadget SlapOS Instance Status JS
</string>
</value>
</item>
<item>
<key>
<string>
version
</string>
</key>
<value>
<string>
001
</string>
</value>
</item>
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary>
<item>
<key>
<string>
document_publication_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAM=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
edit_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAQ=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
processing_status_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAU=
</string>
</persistent>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
publish_alive
</string>
</value>
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
zope
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
error_message
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
time
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1510068986.88
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
validation_state
</string>
</key>
<value>
<string>
published_alive
</string>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"4"
aka=
"AAAAAAAAAAQ="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
edit
</string>
</value>
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
superrafael
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
error_message
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
974.50363.35694.46455
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
<value>
<string>
current
</string>
</value>
</item>
<item>
<key>
<string>
time
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1554236784.11
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"5"
aka=
"AAAAAAAAAAU="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
detect_converted_file
</string>
</value>
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
zope
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
error_message
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
external_processing_state
</string>
</key>
<value>
<string>
converted
</string>
</value>
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
0.0.0.0
</string>
</value>
</item>
<item>
<key>
<string>
time
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1510068964.95
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_instance_tree_status_html.html
deleted
100644 → 0
View file @
73332133
<!DOCTYPE html>
<html>
<head>
<meta
charset=
"utf-8"
>
<meta
name=
"viewport"
content=
"width=device-width, initial-scale=1"
>
<title>
Background
</title>
<script
src=
"rsvp.js"
></script>
<script
src=
"renderjs.js"
></script>
<script
src=
"handlebars.js"
></script>
<script
src=
"gadget_slapos_instance_tree_status.js"
></script>
<link
href=
"gadget_slapos_compute_node_status.css"
rel=
"stylesheet"
type=
"text/css"
/>
<script
id=
"inline-status-template"
type=
"text/x-handlebars-template"
>
<
div
class
=
"
ui-block-a
"
style
=
"
width:50%
"
><
div
class
=
"
ui-bar ui-corner-all first-child {{status_class}}
"
style
=
"
{{status_style}}
"
>
<
a
class
=
"
ui-btn ui-btn-icon-left ui-icon-desktop
"
href
=
"
{{monitor_url}}
"
target
=
_blank
>
{{
status_title
}}
<
/a></
div
><
/div
>
</script>
<script
id=
"inline-status-no-link-template"
type=
"text/x-handlebars-template"
>
<
div
class
=
"
ui-block-a
"
style
=
"
width:50%
"
><
div
class
=
"
ui-bar ui-corner-all first-child {{status_class}}
"
style
=
"
{{status_style}}
"
>
{{
status_title
}}
<
/div></
div
>
</script>
<script
id=
"loading-template"
type=
"text/x-handlebars-template"
>
<
button
data
-
i18n
=
"
loading
"
type
=
"
submit
"
class
=
"
responsive ui-btn ui-icon-spinner ui-icon-spin ui-btn-icon-center ui-disabled
"
style
=
"
border:none;
"
>
loading
<
/button
>
</script>
</head>
<body>
<div
class=
"ui-block-a"
style=
"width:50%"
>
<div
class=
"ui-bar ui-corner-all first-child ui-btn-no-data"
>
<a
class=
"ui-btn ui-btn-icon-left ui-icon-spinner"
style=
"color: white !important;"
>
Instances
</a>
</div>
</div>
</body>
</html>
\ No newline at end of file
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_instance_tree_status_html.xml
deleted
100644 → 0
View file @
73332133
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"Web Page"
module=
"erp5.portal_type"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_Access_contents_information_Permission
</string>
</key>
<value>
<tuple>
<string>
Anonymous
</string>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Auditor
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Add_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Change_local_roles_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Copy_or_Move_Permission
</string>
</key>
<value>
<list>
<string>
Manager
</string>
<string>
Authenticated
</string>
<string>
Developer
</string>
<string>
Owner
</string>
</list>
</value>
</item>
<item>
<key>
<string>
_Modify_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_View_Permission
</string>
</key>
<value>
<tuple>
<string>
Anonymous
</string>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Auditor
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
content_md5
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
content_type
</string>
</key>
<value>
<string>
text/html
</string>
</value>
</item>
<item>
<key>
<string>
creators
</string>
</key>
<value>
<tuple>
<string>
zope
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
gadget_slapos_instance_tree_status.html
</string>
</value>
</item>
<item>
<key>
<string>
description
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
rjs_gadget_slapos_instance_tree_status_html
</string>
</value>
</item>
<item>
<key>
<string>
language
</string>
</key>
<value>
<string>
en
</string>
</value>
</item>
<item>
<key>
<string>
modification_date
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1523884656.83
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
portal_type
</string>
</key>
<value>
<string>
Web Page
</string>
</value>
</item>
<item>
<key>
<string>
short_title
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
<value>
<string>
Gadget SlapOS Instance Tree Status
</string>
</value>
</item>
<item>
<key>
<string>
version
</string>
</key>
<value>
<string>
001
</string>
</value>
</item>
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary>
<item>
<key>
<string>
document_publication_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAM=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
edit_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAQ=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
processing_status_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAU=
</string>
</persistent>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
publish_alive
</string>
</value>
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
zope
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
error_message
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
time
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1510067718.74
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
validation_state
</string>
</key>
<value>
<string>
published_alive
</string>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"4"
aka=
"AAAAAAAAAAQ="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
edit
</string>
</value>
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
superrafael
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
error_message
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
970.21496.17710.36488
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
<value>
<string>
current
</string>
</value>
</item>
<item>
<key>
<string>
time
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1554255222.31
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"5"
aka=
"AAAAAAAAAAU="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
detect_converted_file
</string>
</value>
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
zope
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
error_message
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
external_processing_state
</string>
</key>
<value>
<string>
converted
</string>
</value>
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
0.0.0.0
</string>
</value>
</item>
<item>
<key>
<string>
time
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1510067690.86
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_instance_tree_status_js.js
deleted
100644 → 0
View file @
73332133
/*globals console, window, rJS, RSVP, loopEventListener, i18n, Handlebars, $*/
/*jslint indent: 2, nomen: true, maxlen: 80*/
(
function
(
window
,
rJS
,
RSVP
,
Handlebars
)
{
"
use strict
"
;
var
gadget_klass
=
rJS
(
window
),
inline_status_source
=
gadget_klass
.
__template_element
.
getElementById
(
"
inline-status-template
"
)
.
innerHTML
,
inline_status_template
=
Handlebars
.
compile
(
inline_status_source
),
inline_status_no_link_source
=
gadget_klass
.
__template_element
.
getElementById
(
"
inline-status-no-link-template
"
)
.
innerHTML
,
inline_status_no_link_template
=
Handlebars
.
compile
(
inline_status_no_link_source
);
function
checkInstanceTreeStatus
(
options
)
{
var
message
,
instance
,
partition_class
=
'
ui-btn-ok
'
,
error_amount
=
0
,
total_amount
=
0
;
if
((
!
options
)
||
(
options
&&
!
options
.
instance
))
{
return
'
ui-btn-no-data
'
;
}
if
(
options
.
is_slave
)
{
return
'
ui-btn-is-slave
'
;
}
else
if
(
options
.
is_stopped
)
{
return
'
ui-btn-is-stopped
'
;
}
else
if
(
options
.
is_destroyed
)
{
return
'
ui-btn-is-destroyed
'
;
}
for
(
instance
in
options
.
instance
)
{
message
=
options
.
instance
[
instance
].
text
;
if
(
message
.
startsWith
(
"
#error
"
))
{
partition_class
=
'
ui-btn-warning
'
;
error_amount
++
;
}
total_amount
++
;
if
((
error_amount
>
0
)
&&
(
error_amount
<
total_amount
))
{
// No need to continue the result will be a warnning
return
partition_class
;
}
}
if
(
error_amount
===
total_amount
)
{
// No need to continue the result will be a warnning
return
'
ui-btn-error
'
;
}
return
partition_class
;
}
function
getDoc
(
gadget
)
{
if
(
gadget
.
options
.
doc
&&
gadget
.
options
.
doc
!==
undefined
)
{
return
gadget
.
options
.
doc
;
}
return
gadget
.
jio_get
(
gadget
.
options
.
value
.
jio_key
);
}
function
getStatus
(
gadget
,
result
)
{
return
new
RSVP
.
Queue
()
.
push
(
function
()
{
return
getDoc
(
gadget
);
})
.
push
(
function
(
jio_doc
)
{
var
monitor_url
,
connection_key
,
status_class
=
'
ui-btn-no-data
'
,
status_title
=
'
Instances
'
,
status_style
=
""
;
result
=
jio_doc
;
status_class
=
checkInstanceTreeStatus
(
result
.
news
);
// it should verify if the monitor-base-url is ready.
for
(
connection_key
in
result
.
connection_parameter_list
)
{
if
(
result
.
connection_parameter_list
[
connection_key
].
connection_key
===
"
monitor-setup-url
"
)
{
monitor_url
=
result
.
connection_parameter_list
[
connection_key
].
connection_value
;
}
}
if
(
monitor_url
===
""
)
{
monitor_url
=
'
https://monitor.app.officejs.com/#/?page=ojsm_dispatch&query=portal_type%3A%22Instance%20Tree%22%20AND%20title%3A
'
+
result
.
title
;
}
if
(
status_class
===
'
ui-btn-is-slave
'
)
{
status_class
=
'
ui-btn-no-data
'
;
status_style
=
"
color: white !important;
"
;
status_title
=
'
Slave Only
'
;
}
else
if
(
status_class
===
'
ui-btn-is-stopped
'
)
{
status_class
=
'
ui-btn-no-data
'
;
status_style
=
"
color: white !important;
"
;
status_title
=
'
Stopped
'
;
}
else
if
(
status_class
===
'
ui-btn-is-destroyed
'
)
{
status_class
=
'
ui-btn-no-data
'
;
status_style
=
"
color: white !important;
"
;
status_title
=
'
Destroyed
'
;
}
if
(
status_class
===
'
ui-btn-no-data
'
)
{
gadget
.
element
.
innerHTML
=
inline_status_no_link_template
({
status_class
:
status_class
,
status_title
:
status_title
,
status_style
:
status_style
});
}
else
{
gadget
.
element
.
innerHTML
=
inline_status_template
({
monitor_url
:
monitor_url
,
status_class
:
status_class
,
status_title
:
status_title
,
status_style
:
status_style
});
}
return
gadget
;
}
);
}
function
getStatusLoop
(
gadget
)
{
return
new
RSVP
.
Queue
()
.
push
(
function
()
{
return
gadget
.
jio_get
(
gadget
.
options
.
value
.
jio_key
);
})
.
push
(
function
(
result
)
{
return
getStatus
(
gadget
,
result
);
});
}
gadget_klass
.
setState
({
has_monitor_info
:
false
})
.
ready
(
function
(
gadget
)
{
gadget
.
props
=
{};
return
gadget
.
getSetting
(
"
hateoas_url
"
)
.
push
(
function
(
url
)
{
gadget
.
props
.
hateoas_url
=
url
;
});
})
.
declareAcquiredMethod
(
"
jio_get
"
,
"
jio_get
"
)
.
declareAcquiredMethod
(
"
jio_getAttachment
"
,
"
jio_getAttachment
"
)
.
declareAcquiredMethod
(
"
getSetting
"
,
"
getSetting
"
)
.
declareAcquiredMethod
(
"
translateHtml
"
,
"
translateHtml
"
)
.
declareMethod
(
"
getContent
"
,
function
()
{
return
{};
})
.
declareJob
(
"
getStatus
"
,
function
(
result
)
{
var
gadget
=
this
;
return
getStatus
(
gadget
,
{
news
:
result
});
})
.
onLoop
(
function
()
{
var
gadget
=
this
;
return
getStatusLoop
(
gadget
);
},
300000
)
.
declareMethod
(
"
render
"
,
function
(
options
)
{
var
gadget
=
this
;
gadget
.
options
=
options
;
gadget
.
flag
=
options
.
value
.
jio_key
;
return
gadget
.
getStatus
(
options
.
value
.
result
);
});
}(
window
,
rJS
,
RSVP
,
Handlebars
));
\ No newline at end of file
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_instance_tree_status_js.xml
deleted
100644 → 0
View file @
73332133
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"Web Script"
module=
"erp5.portal_type"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_Access_contents_information_Permission
</string>
</key>
<value>
<tuple>
<string>
Anonymous
</string>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Auditor
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Add_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Change_local_roles_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_Modify_portal_content_Permission
</string>
</key>
<value>
<tuple>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Manager
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
_View_Permission
</string>
</key>
<value>
<tuple>
<string>
Anonymous
</string>
<string>
Assignee
</string>
<string>
Assignor
</string>
<string>
Associate
</string>
<string>
Auditor
</string>
<string>
Manager
</string>
<string>
Owner
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
content_md5
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
creators
</string>
</key>
<value>
<tuple>
<string>
zope
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
gadget_slapos_instance_tree_status.js
</string>
</value>
</item>
<item>
<key>
<string>
description
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
rjs_gadget_slapos_instance_tree_status_js
</string>
</value>
</item>
<item>
<key>
<string>
language
</string>
</key>
<value>
<string>
en
</string>
</value>
</item>
<item>
<key>
<string>
modification_date
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1523884656.86
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
portal_type
</string>
</key>
<value>
<string>
Web Script
</string>
</value>
</item>
<item>
<key>
<string>
short_title
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
<value>
<string>
Gadget SlapOS Instance Tree Status JS
</string>
</value>
</item>
<item>
<key>
<string>
version
</string>
</key>
<value>
<string>
001
</string>
</value>
</item>
<item>
<key>
<string>
workflow_history
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary>
<item>
<key>
<string>
document_publication_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAM=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
edit_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAQ=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
processing_status_workflow
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAU=
</string>
</persistent>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
publish_alive
</string>
</value>
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
zope
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
error_message
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
time
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1510067801.81
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
validation_state
</string>
</key>
<value>
<string>
published_alive
</string>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"4"
aka=
"AAAAAAAAAAQ="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
edit
</string>
</value>
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
superrafael
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<key>
<string>
error_message
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
974.50748.25599.3686
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
<value>
<string>
current
</string>
</value>
</item>
<item>
<key>
<string>
time
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1554255778.44
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"5"
aka=
"AAAAAAAAAAU="
>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_log
</string>
</key>
<value>
<list>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
detect_converted_file
</string>
</value>
</item>
<item>
<key>
<string>
actor
</string>
</key>
<value>
<string>
zope
</string>
</value>
</item>
<item>
<key>
<string>
comment
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
error_message
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
external_processing_state
</string>
</key>
<value>
<string>
converted
</string>
</value>
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
0.0.0.0
</string>
</value>
</item>
<item>
<key>
<string>
time
</string>
</key>
<value>
<object>
<klass>
<global
name=
"DateTime"
module=
"DateTime.DateTime"
/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>
1510067777.76
</float>
<string>
UTC
</string>
</tuple>
</state>
</object>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_status_css.css
View file @
53cda406
...
@@ -24,6 +24,10 @@
...
@@ -24,6 +24,10 @@
color
:
white
!important
;
color
:
white
!important
;
}
}
.ui-btn-hide
{
display
:
none
;
}
.ui-bar
{
.ui-bar
{
position
:
relative
;
position
:
relative
;
padding
:
.4em
1em
;
padding
:
.4em
1em
;
...
...
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_status_css.xml
View file @
53cda406
...
@@ -242,7 +242,7 @@
...
@@ -242,7 +242,7 @@
</item>
</item>
<item>
<item>
<key>
<string>
serial
</string>
</key>
<key>
<string>
serial
</string>
</key>
<value>
<string>
1000.5
4026.12481.29013
</string>
</value>
<value>
<string>
1000.5
7958.38485.23927
</string>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
state
</string>
</key>
<key>
<string>
state
</string>
</key>
...
@@ -260,7 +260,7 @@
...
@@ -260,7 +260,7 @@
</tuple>
</tuple>
<state>
<state>
<tuple>
<tuple>
<float>
165
4873584.88
</float>
<float>
165
5110268.61
</float>
<string>
UTC
</string>
<string>
UTC
</string>
</tuple>
</tuple>
</state>
</state>
...
...
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_status_js.js
View file @
53cda406
...
@@ -5,6 +5,55 @@
...
@@ -5,6 +5,55 @@
"
use strict
"
;
"
use strict
"
;
var
gadget_klass
=
rJS
(
window
);
var
gadget_klass
=
rJS
(
window
);
function
getInstanceStatus
(
options
)
{
if
((
!
options
)
||
(
options
&&
!
options
.
text
))
{
return
'
ui-btn-no-data
'
;
}
if
(
options
.
text
.
startsWith
(
"
#access
"
))
{
return
'
ui-btn-ok
'
;
}
if
(
options
.
no_data
)
{
return
'
ui-btn-no-data
'
;
}
if
(
options
.
is_slave
)
{
return
'
ui-btn-is-slave
'
;
}
if
(
options
.
is_stopped
)
{
return
'
ui-btn-is-stopped
'
;
}
if
(
options
.
is_destroyed
)
{
return
'
ui-btn-is-destroyed
'
;
}
return
'
ui-btn-error
'
;
}
function
getInstanceTreeStatus
(
options
)
{
var
instance
;
if
((
!
options
)
||
(
options
&&
!
options
.
instance
))
{
return
'
ui-btn-no-data
'
;
}
if
(
options
.
is_slave
)
{
return
'
ui-btn-is-slave
'
;
}
if
(
options
.
is_stopped
)
{
return
'
ui-btn-is-stopped
'
;
}
if
(
options
.
is_destroyed
)
{
return
'
ui-btn-is-destroyed
'
;
}
for
(
instance
in
options
.
instance
)
{
if
(
options
.
instance
.
hasOwnProperty
(
instance
))
{
if
(
options
.
instance
[
instance
].
text
.
startsWith
(
"
#error
"
))
{
return
'
ui-btn-error
'
;
}
}
}
return
'
ui-btn-ok
'
;
}
function
getComputeNodeStatus
(
options
)
{
function
getComputeNodeStatus
(
options
)
{
if
(
!
options
||
!
options
.
text
)
{
if
(
!
options
||
!
options
.
text
)
{
return
'
ui-btn-no-data
'
;
return
'
ui-btn-no-data
'
;
...
@@ -60,24 +109,45 @@
...
@@ -60,24 +109,45 @@
return
partition_class
;
return
partition_class
;
}
}
function
getSoftwareInstallationStatus
(
options
)
{
if
((
!
options
)
||
(
options
&&
!
options
.
text
))
{
return
'
ui-btn-no-data
'
;
}
if
(
options
.
text
.
startsWith
(
"
#access
"
))
{
return
'
ui-btn-ok
'
;
}
if
(
options
.
text
.
startsWith
(
"
#building
"
))
{
return
'
ui-btn-is-building
'
;
}
if
(
options
.
no_data
)
{
return
'
ui-btn-no-data
'
;
}
return
'
ui-btn-error
'
;
}
function
getComputeNodeStatusList
(
options
)
{
function
getComputeNodeStatusList
(
options
)
{
var
previous_status
=
"
START
"
,
var
previous_status
=
"
START
"
,
status
=
'
ui-btn-no-data
'
,
status
=
'
ui-btn-no-data
'
,
i
;
i
;
if
(
!
options
||
!
options
.
news
||
!
options
.
news
.
compute_node
)
{
if
(
!
options
||
!
options
.
compute_node
)
{
return
status
;
return
status
;
}
}
for
(
i
in
options
.
news
.
compute_node
)
{
for
(
i
in
options
.
compute_node
)
{
if
(
options
.
news
.
compute_node
.
hasOwnProperty
(
i
))
{
if
(
options
.
compute_node
.
hasOwnProperty
(
i
))
{
status
=
getComputeNodeStatus
(
options
.
news
.
compute_node
[
i
]);
status
=
getComputeNodeStatus
(
options
.
compute_node
[
i
]);
if
(
previous_status
===
"
START
"
)
{
if
(
previous_status
===
"
START
"
)
{
previous_status
=
status
;
previous_status
=
status
;
}
}
if
(
previous_status
!==
status
)
{
if
(
previous_status
!==
status
)
{
if
((
previous_status
===
'
ui-btn-error
'
)
&&
(
status
===
'
ui-btn-ok
'
))
{
if
((
previous_status
===
'
ui-btn-error
'
)
&&
(
status
===
'
ui-btn-ok
'
))
{
// XXX drop warning
return
'
ui-btn-warning
'
;
return
'
ui-btn-warning
'
;
}
}
if
((
status
===
'
ui-btn-error
'
)
&&
(
previous_status
===
'
ui-btn-ok
'
))
{
if
((
status
===
'
ui-btn-error
'
)
&&
(
previous_status
===
'
ui-btn-ok
'
))
{
// XXX drop warning
return
'
ui-btn-warning
'
;
return
'
ui-btn-warning
'
;
}
}
if
(
status
===
'
ui-btn-no-data
'
)
{
if
(
status
===
'
ui-btn-no-data
'
)
{
...
@@ -93,22 +163,25 @@
...
@@ -93,22 +163,25 @@
var
compute_node_reference
,
var
compute_node_reference
,
status
=
'
ui-btn-no-data
'
,
status
=
'
ui-btn-no-data
'
,
previous_status
=
"
START
"
;
previous_status
=
"
START
"
;
for
(
compute_node_reference
in
options
.
news
.
partition
)
{
for
(
compute_node_reference
in
options
.
partition
)
{
if
(
options
.
news
.
partition
.
hasOwnProperty
(
compute_node_reference
))
{
if
(
options
.
partition
.
hasOwnProperty
(
compute_node_reference
))
{
status
=
getComputePartitionStatus
(
status
=
getComputePartitionStatus
(
options
.
news
.
partition
[
compute_node_reference
]);
options
.
partition
[
compute_node_reference
]
);
if
(
previous_status
===
"
START
"
)
{
if
(
previous_status
===
"
START
"
)
{
previous_status
=
status
;
previous_status
=
status
;
}
}
if
(
status
===
'
ui-btn-warning
'
)
{
if
(
status
===
'
ui-btn-warning
'
)
{
//
If status is warning, nothing after will change it.
//
XXX Drop warning
return
status
;
return
status
;
}
}
if
(
previous_status
!==
status
)
{
if
(
previous_status
!==
status
)
{
if
((
previous_status
===
'
ui-btn-error
'
)
&&
(
status
===
'
ui-btn-ok
'
))
{
if
((
previous_status
===
'
ui-btn-error
'
)
&&
(
status
===
'
ui-btn-ok
'
))
{
return
'
ui-btn-warning
'
;
return
'
ui-btn-warning
'
;
}
}
if
((
status
===
'
ui-btn-error
'
)
&&
(
previous_status
===
'
ui-btn-ok
'
))
{
if
((
status
===
'
ui-btn-error
'
)
&&
(
previous_status
===
'
ui-btn-ok
'
))
{
return
'
ui-btn-warning
'
;
return
'
ui-btn-warning
'
;
}
}
if
(
status
===
'
ui-btn-no-data
'
)
{
if
(
status
===
'
ui-btn-no-data
'
)
{
...
@@ -121,19 +194,32 @@
...
@@ -121,19 +194,32 @@
}
}
function
getStatus
(
gadget
,
result
)
{
function
getStatus
(
gadget
,
result
)
{
var
status_class
=
'
ui-btn-no-data
'
,
var
i
,
status_class
=
'
ui-btn-no-data
'
,
right_class
=
'
ui-btn-no-data
'
,
right_class
=
'
ui-btn-no-data
'
,
computer_node_div
=
gadget
.
element
.
querySelector
(
"
compute-node-status
"
),
main_status_div
=
gadget
.
element
.
querySelector
(
"
main-status
"
),
compute_partition_div
=
gadget
.
element
.
querySelector
(
"
compute-node-status
"
),
sub_status_div
=
gadget
.
element
.
querySelector
(
"
sub-status
"
),
monitor_url
=
''
;
monitor_url
=
''
,
main_link_configuration_dict
=
{
class
:
"
ui-btn ui-btn-icon-left ui-icon-desktop
"
},
sub_link_configuration_dict
=
{
class
:
"
ui-btn ui-btn-icon-left ui-icon-desktop
"
};
if
(
result
&&
result
.
portal_type
&&
result
.
portal_type
===
"
Compute Node
"
)
{
if
(
result
&&
result
.
portal_type
&&
result
.
portal_type
===
"
Compute Node
"
)
{
monitor_url
=
'
https://monitor.app.officejs.com/#/
'
+
monitor_url
=
'
https://monitor.app.officejs.com/#/
'
+
'
?page=ojsm_dispatch&query=portal_type%3A%22Software%20Instance%22%20
'
+
'
?page=ojsm_dispatch&query=portal_type%3A%22Software%20Instance%22%20
'
+
'
AND%20aggregate_reference%3A%22
'
+
result
.
reference
+
'
%22
'
;
'
AND%20aggregate_reference%3A%22
'
+
result
.
reference
+
'
%22
'
;
main_link_configuration_dict
.
href
=
monitor_url
;
main_link_configuration_dict
.
target
=
"
_target
"
;
main_link_configuration_dict
.
text
=
'
Compute Node
'
;
sub_link_configuration_dict
.
href
=
monitor_url
;
sub_link_configuration_dict
.
target
=
"
_target
"
;
sub_link_configuration_dict
.
text
=
'
Partitions
'
;
if
(
result
&&
result
.
news
&&
result
.
news
.
compute_node
)
{
if
(
result
&&
result
.
news
&&
result
.
news
.
compute_node
)
{
status_class
=
getComputeNodeStatus
(
{
news
:
result
.
news
.
compute_node
}
);
status_class
=
getComputeNodeStatus
(
result
.
news
.
compute_node
);
}
}
if
((
status_class
===
'
ui-btn-error
'
)
||
if
((
status_class
===
'
ui-btn-error
'
)
||
(
status_class
===
'
ui-btn-no-data
'
))
{
(
status_class
===
'
ui-btn-no-data
'
))
{
...
@@ -145,42 +231,111 @@
...
@@ -145,42 +231,111 @@
);
);
}
}
}
}
}
else
if
(
result
&&
result
.
portal_type
&&
result
.
portal_type
===
"
Software Installation
"
)
{
if
(
result
&&
result
.
news
)
{
status_class
=
getSoftwareInstallationStatus
(
result
.
news
);
}
main_link_configuration_dict
.
text
=
"
Installation
"
;
right_class
=
"
ui-btn-hide
"
;
if
(
status_class
===
"
ui-btn-is-building
"
)
{
main_link_configuration_dict
.
text
=
"
Building
"
;
status_class
=
"
ui-btn-no-data
"
;
}
else
if
(
status_class
===
"
ui-btn-ok
"
)
{
main_link_configuration_dict
.
text
=
"
Available
"
;
}
else
if
(
status_class
===
"
ui-btn-error
"
)
{
main_link_configuration_dict
.
text
=
"
Error
"
;
}
}
else
if
(
result
&&
result
.
portal_type
&&
(
result
.
portal_type
===
"
Software Instance
"
||
result
.
portal_type
===
"
Slave Instance
"
))
{
monitor_url
=
'
https://monitor.app.officejs.com/#/
'
+
'
?page=ojsm_dispatch&query=
'
+
'
portal_type%3A%22Software%20Instance%22%20AND%20reference%3A%22
'
+
result
.
reference
+
'
%22
'
;
if
(
result
&&
result
.
news
)
{
status_class
=
getInstanceStatus
(
result
.
news
);
}
right_class
=
"
ui-btn-hide
"
;
if
(
status_class
===
'
ui-btn-is-slave
'
)
{
status_class
=
'
ui-btn-no-data ui-btn-color-white
'
;
main_link_configuration_dict
.
text
=
'
Slave
'
;
}
else
if
(
status_class
===
'
ui-btn-is-stopped
'
)
{
status_class
=
'
ui-btn-no-data ui-btn-color-white
'
;
main_link_configuration_dict
.
text
=
'
Stopped
'
;
}
else
if
(
status_class
===
'
ui-btn-is-destroyed
'
)
{
status_class
=
'
ui-btn-no-data ui-btn-color-white
'
;
main_link_configuration_dict
.
text
=
'
Destroyed
'
;
}
else
{
main_link_configuration_dict
.
href
=
monitor_url
;
main_link_configuration_dict
.
target
=
"
_target
"
;
main_link_configuration_dict
.
text
=
'
Instance
'
;
}
}
else
if
(
result
&&
result
.
portal_type
&&
result
.
portal_type
===
"
Instance Tree
"
)
{
if
(
result
&&
result
.
news
)
{
status_class
=
getInstanceTreeStatus
(
result
.
news
);
}
// it should verify if the monitor-base-url is ready.
for
(
i
in
result
.
connection_parameter_list
)
{
if
(
result
.
connection_parameter_list
.
hasOwnProperty
(
i
))
{
if
(
result
.
connection_parameter_list
[
i
].
connection_key
===
"
monitor-setup-url
"
)
{
monitor_url
=
result
.
connection_parameter_list
[
i
].
connection_value
;
}
}
}
if
(
monitor_url
===
""
)
{
monitor_url
=
'
https://monitor.app.officejs.com/#/
'
+
'
?page=ojsm_dispatch&query=portal_type
'
+
'
%3A%22Instance%20Tree%22%20AND%20title%3A
'
+
result
.
title
;
}
right_class
=
"
ui-btn-hide
"
;
if
(
status_class
===
'
ui-btn-is-slave
'
)
{
status_class
=
'
ui-btn-no-data ui-btn-color-white
'
;
main_link_configuration_dict
.
text
=
'
Slave Only
'
;
}
else
if
(
status_class
===
'
ui-btn-is-stopped
'
)
{
status_class
=
'
ui-btn-no-data ui-btn-color-white
'
;
main_link_configuration_dict
.
text
=
'
Stopped
'
;
}
else
if
(
status_class
===
'
ui-btn-is-destroyed
'
)
{
status_class
=
'
ui-btn-no-data ui-btn-color-white
'
;
main_link_configuration_dict
.
text
=
'
Destroyed
'
;
}
else
{
main_link_configuration_dict
.
href
=
monitor_url
;
main_link_configuration_dict
.
target
=
"
_target
"
;
main_link_configuration_dict
.
text
=
'
Instance
'
;
}
}
else
{
}
else
{
monitor_url
=
gadget
.
options
.
value
.
jio_key
+
'
/Base_redirectToMonitor
'
;
monitor_url
=
gadget
.
options
.
value
.
jio_key
+
'
/Base_redirectToMonitor
'
;
status_class
=
getComputeNodeStatusList
(
result
);
main_link_configuration_dict
.
href
=
monitor_url
;
main_link_configuration_dict
.
target
=
"
_target
"
;
main_link_configuration_dict
.
text
=
'
Compute Node
'
;
sub_link_configuration_dict
.
href
=
monitor_url
;
sub_link_configuration_dict
.
target
=
"
_target
"
;
sub_link_configuration_dict
.
text
=
'
Partitions
'
;
status_class
=
getComputeNodeStatusList
(
result
.
news
);
if
((
status_class
===
'
ui-btn-error
'
)
||
if
((
status_class
===
'
ui-btn-error
'
)
||
(
status_class
===
'
ui-btn-no-data
'
))
{
(
status_class
===
'
ui-btn-no-data
'
))
{
right_class
=
status_class
;
right_class
=
status_class
;
}
else
{
}
else
{
right_class
=
getComputePartitionStatusList
(
result
);
right_class
=
getComputePartitionStatusList
(
result
.
news
);
}
}
}
}
domsugar
(
computer_node
_div
.
firstChild
,
domsugar
(
main_status
_div
.
firstChild
,
{
{
class
:
"
ui-bar ui-corner-all first-child
"
+
status_class
class
:
"
ui-bar ui-corner-all first-child
"
+
status_class
},
[
},
[
domsugar
(
"
a
"
,
domsugar
(
"
a
"
,
main_link_configuration_dict
)
{
class
:
"
ui-btn ui-btn-icon-left ui-icon-desktop
"
,
href
:
monitor_url
,
target
:
"
_blank
"
,
// missing translation
text
:
'
Compute Node
'
})
]);
]);
domsugar
(
compute_partition
_div
.
firstChild
,
domsugar
(
sub_status
_div
.
firstChild
,
{
{
class
:
"
ui-bar ui-corner-all last-child
"
+
right_class
class
:
"
ui-bar ui-corner-all last-child
"
+
right_class
},
[
},
[
domsugar
(
"
a
"
,
domsugar
(
"
a
"
,
sub_link_configuration_dict
)
{
class
:
"
ui-btn ui-btn-icon-left ui-icon-desktop
"
,
href
:
monitor_url
,
target
:
"
_blank
"
,
// missing translation
text
:
'
Partitions
'
})
]);
]);
return
gadget
;
return
gadget
;
}
}
...
...
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_slapos_status_js.xml
View file @
53cda406
...
@@ -274,7 +274,7 @@
...
@@ -274,7 +274,7 @@
</item>
</item>
<item>
<item>
<key>
<string>
serial
</string>
</key>
<key>
<string>
serial
</string>
</key>
<value>
<string>
1000.5
4027.11178.31948
</string>
</value>
<value>
<string>
1000.5
8055.14909.921
</string>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
state
</string>
</key>
<key>
<string>
state
</string>
</key>
...
@@ -292,7 +292,7 @@
...
@@ -292,7 +292,7 @@
</tuple>
</tuple>
<state>
<state>
<tuple>
<tuple>
<float>
165
4873641.14
</float>
<float>
165
5115505.83
</float>
<string>
UTC
</string>
<string>
UTC
</string>
</tuple>
</tuple>
</state>
</state>
...
...
master/bt5/slapos_jio/bt/template_keep_last_workflow_history_only_path_list
View file @
53cda406
...
@@ -179,12 +179,6 @@ web_page_module/rjs_gadget_slapos_event_discussion_entry_html
...
@@ -179,12 +179,6 @@ web_page_module/rjs_gadget_slapos_event_discussion_entry_html
web_page_module/rjs_gadget_slapos_event_discussion_entry_js
web_page_module/rjs_gadget_slapos_event_discussion_entry_js
web_page_module/rjs_gadget_slapos_header_html
web_page_module/rjs_gadget_slapos_header_html
web_page_module/rjs_gadget_slapos_header_js
web_page_module/rjs_gadget_slapos_header_js
web_page_module/rjs_gadget_slapos_instance_tree_status_html
web_page_module/rjs_gadget_slapos_instance_tree_status_js
web_page_module/rjs_gadget_slapos_installation_status_html
web_page_module/rjs_gadget_slapos_installation_status_js
web_page_module/rjs_gadget_slapos_instance_status_html
web_page_module/rjs_gadget_slapos_instance_status_js
web_page_module/rjs_gadget_slapos_invoice_printout_html
web_page_module/rjs_gadget_slapos_invoice_printout_html
web_page_module/rjs_gadget_slapos_invoice_printout_js
web_page_module/rjs_gadget_slapos_invoice_printout_js
web_page_module/rjs_gadget_slapos_invoice_state_html
web_page_module/rjs_gadget_slapos_invoice_state_html
...
...
master/bt5/slapos_jio/bt/template_path_list
View file @
53cda406
...
@@ -184,12 +184,6 @@ web_page_module/rjs_gadget_slapos_event_discussion_entry_html
...
@@ -184,12 +184,6 @@ web_page_module/rjs_gadget_slapos_event_discussion_entry_html
web_page_module/rjs_gadget_slapos_event_discussion_entry_js
web_page_module/rjs_gadget_slapos_event_discussion_entry_js
web_page_module/rjs_gadget_slapos_header_html
web_page_module/rjs_gadget_slapos_header_html
web_page_module/rjs_gadget_slapos_header_js
web_page_module/rjs_gadget_slapos_header_js
web_page_module/rjs_gadget_slapos_installation_status_html
web_page_module/rjs_gadget_slapos_installation_status_js
web_page_module/rjs_gadget_slapos_instance_status_html
web_page_module/rjs_gadget_slapos_instance_status_js
web_page_module/rjs_gadget_slapos_instance_tree_status_html
web_page_module/rjs_gadget_slapos_instance_tree_status_js
web_page_module/rjs_gadget_slapos_invoice_printout_html
web_page_module/rjs_gadget_slapos_invoice_printout_html
web_page_module/rjs_gadget_slapos_invoice_printout_js
web_page_module/rjs_gadget_slapos_invoice_printout_js
web_page_module/rjs_gadget_slapos_invoice_state_html
web_page_module/rjs_gadget_slapos_invoice_state_html
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment