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
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Léo-Paul Géneau
slapos.core
Commits
6530d531
Commit
6530d531
authored
Oct 27, 2022
by
Rafael Monnerat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
slapos_jio: Minor fixup on Domparser usage
parent
ca9bd36e
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
6 deletions
+5
-6
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_parameter_form_js.js
...age_module/rjs_gadget_erp5_page_slap_parameter_form_js.js
+3
-4
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_parameter_form_js.xml
...ge_module/rjs_gadget_erp5_page_slap_parameter_form_js.xml
+2
-2
No files found.
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_parameter_form_js.js
View file @
6530d531
...
@@ -7,12 +7,11 @@
...
@@ -7,12 +7,11 @@
"
use strict
"
;
"
use strict
"
;
var
DISPLAY_JSON_FORM
=
'
display_json_form
'
,
var
DISPLAY_JSON_FORM
=
'
display_json_form
'
,
DISPLAY_RAW_XML
=
'
display_raw_xml
'
,
DISPLAY_RAW_XML
=
'
display_raw_xml
'
;
domparser
=
new
DOMParser
;
function
jsonDictToParameterXML
(
json
)
{
function
jsonDictToParameterXML
(
json
)
{
var
parameter_id
,
var
parameter_id
,
xml_output
=
$
((
new
DOMParser
).
parseFromString
(
xml_output
=
$
((
new
DOMParser
()
).
parseFromString
(
'
<?xml version="1.0" encoding="UTF-8" ?><instance />
'
,
'
text/xml
'
));
'
<?xml version="1.0" encoding="UTF-8" ?><instance />
'
,
'
text/xml
'
));
// Used by serialisation XML
// Used by serialisation XML
for
(
parameter_id
in
json
)
{
for
(
parameter_id
in
json
)
{
...
@@ -30,7 +29,7 @@
...
@@ -30,7 +29,7 @@
}
}
function
jsonDictToParameterJSONInXML
(
json
)
{
function
jsonDictToParameterJSONInXML
(
json
)
{
var
xml_output
=
$
((
new
DOMParser
).
parseFromString
(
var
xml_output
=
$
((
new
DOMParser
()
).
parseFromString
(
'
<?xml version="1.0" encoding="UTF-8" ?><instance />
'
,
'
<?xml version="1.0" encoding="UTF-8" ?><instance />
'
,
'
text/xml
'
'
text/xml
'
));
));
...
...
master/bt5/slapos_jio/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_slap_parameter_form_js.xml
View file @
6530d531
...
@@ -280,7 +280,7 @@
...
@@ -280,7 +280,7 @@
</item>
</item>
<item>
<item>
<key>
<string>
serial
</string>
</key>
<key>
<string>
serial
</string>
</key>
<value>
<string>
1003.605
31.19628.1092
</string>
</value>
<value>
<string>
1003.605
64.512.29713
</string>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
state
</string>
</key>
<key>
<string>
state
</string>
</key>
...
@@ -298,7 +298,7 @@
...
@@ -298,7 +298,7 @@
</tuple>
</tuple>
<state>
<state>
<tuple>
<tuple>
<float>
16668
89520.3
5
</float>
<float>
16668
96829.8
5
</float>
<string>
UTC
</string>
<string>
UTC
</string>
</tuple>
</tuple>
</state>
</state>
...
...
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