Commit 9f18301e authored by Rafael Monnerat's avatar Rafael Monnerat

Parameter form readonly

See merge request nexedi/slapos.core!454
parents 7d07dfdd 81b437a1
Pipeline #25078 failed with stage
in 0 seconds
......@@ -107,13 +107,10 @@
parameter_dict = {
'parameter' : {
'json_url': doc.url_string.split('?')[0] + ".json",
//'json_url': "https://lab.node.vifib.com/nexedi/slapos/raw/master/software/kvm/software.cfg.json",
'parameter_hash': btoa('<?xml version="1.0" encoding="utf-8" ?><instance/>'),
'restricted_softwaretype': false
'parameter_hash': btoa('<?xml version="1.0" encoding="utf-8" ?><instance/>')
}
};
if (options.software_type) {
parameter_dict["parameter"]['restricted_softwaretype'] = true;
parameter_dict["parameter"]['softwaretype'] = options.software_type;
}
if (options.shared) {
......
......@@ -279,7 +279,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>999.2068.62564.17</string> </value>
<value> <string>1000.31175.43828.12919</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -297,7 +297,7 @@
</tuple>
<state>
<tuple>
<float>1652724671.12</float>
<float>1669310140.13</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -226,9 +226,7 @@
'json_url': gadget.state.doc.url_string.split('?')[0] + ".json",
'softwaretype': gadget.state.doc.source_reference,
'shared': gadget.state.doc.root_slave ? 1 : 0,
//'json_url': "https://lab.node.vifib.com/nexedi/slapos/raw/master/software/kvm/software.cfg.json",
'parameter_hash': btoa('<?xml version="1.0" encoding="utf-8" ?><instance></instance>'),
'restricted_softwaretype': true
'parameter_hash': btoa('<?xml version="1.0" encoding="utf-8" ?><instance></instance>')
}
};
if (gadget.state.doc.text_content !== undefined) {
......@@ -294,17 +292,6 @@
"hidden": 0,
"type": "StringField"
},
"my_source_reference": {
"description": "",
"title": result[1][17],
"default": gadget.state.doc.source_reference,
"css_class": "",
"required": 1,
"editable": 0,
"key": "source_reference",
"hidden": 0,
"type": "StringField"
},
"my_url_string": {
"description": "",
"title": result[1][18],
......@@ -488,7 +475,7 @@
[["my_slap_state_title"], ['my_monitoring_status'], ['my_monitor_scope'], ['my_upgrade_scope'], ['my_source_project'], ['my_source']]
], ["center",
[["my_source_reference"], ["my_url_string"], ["my_list_image"]]
[["my_url_string"], ["my_list_image"]]
], [
"bottom",
[["ticket_listbox"], ["connection_listbox"], ["my_text_content"], ["listbox"]]
......
......@@ -236,7 +236,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>1001.26171.19762.42854</string> </value>
<value> <string>1004.26872.6486.682</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -254,7 +254,7 @@
</tuple>
<state>
<tuple>
<float>1658173330.65</float>
<float>1669310224.29</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -4,10 +4,7 @@
padding-top: 10px;
}
.subfield span {
.subfield span:not(.slapos-parameter) {
font-weight: normal;
font-style: italic;
padding-left: 7px;
......@@ -22,12 +19,8 @@
font-weight: 700;
}
.input button {margin-left: 10px;}
.bt_close, .subfield .slapos-parameter-dict-key span.bt_close{
padding: 0 6px;
display: block;
......@@ -62,7 +55,6 @@
word-break: keep-all;
}
.non-editable > div.input {border: 1px solid rgb(201, 201, 201); padding: 5px; background: white; font-weight: normal;
margin: 5px 0 10px; max-height: 250px; width: 80%;}
......@@ -84,6 +76,7 @@ label.slapos-parameter-dict-key-colapse::before {
}
div.slapos-parameter-dict-key {
margin-top: 10px;
margin-left: 6px;
background: rgb(245, 245, 245);
border: 1px solid rgb(230, 230, 230);
padding: 5px;
......@@ -91,7 +84,6 @@ div.slapos-parameter-dict-key {
/* cleanup */
fieldset > .subfield > label:not(.slapos-parameter-dict-key) {
font-size: 113%;
color: rgb(112, 125, 136);
}
fieldset > div.subfield {
......@@ -103,24 +95,30 @@ fieldset > div.subfield {
.field input ~ span,
.subfield input ~ span {
position: relative;
top: -30px;
top: -27px;
pointer-events: none;
cursor: text;
}
.field input:not(:placeholder-shown) ~ span:not(.error),
.subfield input:not(:placeholder-shown) ~ span:not(.error) {
.subfield input:not(:placeholder-shown) ~ span:not(.error),
.field select:not(:placeholder-shown) ~ span:not(.error),
.subfield select:not(:placeholder-shown) ~ span:not(.error) {
visibility: hidden;
}
.field input ~ span:not(.error),
.subfield input ~ span:not(.error) {
.subfield input ~ span:not(.error),
.field select ~ span:not(.error),
.subfield select ~ span:not(.error) {
opacity: .7;
}
.field input:focus ~ span,
.subfield input:focus ~ span {
.subfield input:focus ~ span,
.field select:focus ~ span,
.subfield select:focus ~ span {
visibility: hidden;
}
.subfield .input {
margin-bottom: -20px;
margin-bottom: -15px;
}
.subfield .error {
float: right;
......@@ -135,7 +133,6 @@ fieldset > div.subfield {
.slapos-show-form {
cursor: pointer;
font-style: italic;
font-size: 14px;
color: #000;
}
.slapos-show-form,
......@@ -147,7 +144,6 @@ label.slapos-parameter-dict-key {
text-transform: capitalize;
}
label.slapos-parameter-dict-key ~ div.input label {
font-size: 113%;
color: rgb(112, 125, 136);
}
.slapos-parameter-dict-key label {
......@@ -180,14 +176,20 @@ label.slapos-parameter-dict-key ~ div.input label {
left: 4px;
}
.subfield {
min-height: 5em;
}
.subfield select {
margin-bottom: 0;
}
.subfield .input select + span {
position: relative;
top: -1.9em;
opacity: .7;
}
.subfield {
min-height: 5em;
}
.subfield select {
margin-bottom: 0;
}
.subfield .input select + span {
position: relative;
top: -1.9em;
opacity: .7;
}
select.readonly {
background: #EEE;
pointer-events: none;
touch-action: none;
}
......@@ -72,8 +72,8 @@
);
}
function render_selection(json_field, default_value, is_required) {
var property_dict = {size: 1},
function render_selection(json_field, default_value, is_required, editable) {
var input,
option_list = [domsugar('option', {
value: "",
selected: (default_value === undefined)
......@@ -81,7 +81,12 @@
option_index,
selected,
is_selected = (default_value === undefined),
data_format = "string";
data_format = "string",
property_dict = {
size: 1,
"placeholder": " ",
"class": "slapos-parameter"
};
if (json_field.type === "integer" || json_field.type === "number") {
data_format = "number";
......@@ -118,14 +123,27 @@
if (is_required) {
property_dict.required = true;
}
return domsugar('select', property_dict, option_list);
input = domsugar('select', property_dict, option_list);
if (!editable) {
input.classList.add("readonly");
input["aria-disabled"] = "true";
input["tab-index"] = "-1";
}
return input;
}
function render_selection_oneof(json_field, default_value, is_required) {
var option_list = [domsugar('option', {
value: "",
selected: (default_value === undefined)
})];
function render_selection_oneof(json_field, default_value, is_required, editable) {
var input,
option_list = [domsugar('option', {
value: "",
selected: (default_value === undefined)
})],
property_dict = {
size: 1,
"placeholder": " ",
"class": "slapos-parameter"
};
json_field.oneOf.forEach(function (element) {
if ((element['const'] !== undefined) && (element.title !== undefined)) {
......@@ -143,14 +161,24 @@
}));
}
});
return domsugar('select', {
size: 1
}, option_list);
if (is_required) {
property_dict.required = true;
}
input = domsugar('select', property_dict, option_list);
if (!editable) {
input.classList.add("readonly");
input["aria-disabled"] = "true";
input["tab-index"] = "-1";
}
return input;
}
function render_textarea(json_field, default_value, data_format, is_required) {
var property_dict = {"data-format": data_format};
function render_textarea(json_field, default_value, data_format, is_required, editable) {
var input, property_dict = {
"data-format": data_format,
"placeholder": " ",
"class": "slapos-parameter"
};
if (default_value !== undefined) {
if (default_value instanceof Array) {
property_dict.value = default_value.join("\n");
......@@ -161,17 +189,23 @@
if (is_required) {
property_dict.required = true;
}
return domsugar('textarea', property_dict);
input = domsugar('textarea', property_dict);
if (!editable) {
input.setAttribute('readonly', true);
}
return input;
}
function render_field(json_field, default_value, is_required) {
var data_format, domsugar_input_dict = {};
function render_field(json_field, default_value, is_required, editable) {
var input,
data_format,
domsugar_input_dict = {"placeholder": " ", "class": "slapos-parameter"};
if (json_field['enum'] !== undefined) {
return render_selection(json_field, default_value, is_required);
return render_selection(json_field, default_value, is_required, editable);
}
if (json_field.oneOf !== undefined) {
return render_selection_oneof(json_field, default_value, is_required);
return render_selection_oneof(json_field, default_value, is_required, editable);
}
if (json_field.type === "boolean") {
......@@ -182,7 +216,7 @@
if (default_value === "false") {
default_value = false;
}
return render_selection(json_field, default_value, is_required);
return render_selection(json_field, default_value, is_required, editable);
}
if (json_field.type === "array") {
......@@ -192,11 +226,11 @@
data_format = "array-number";
}
}
return render_textarea(json_field, default_value, data_format, is_required);
return render_textarea(json_field, default_value, data_format, is_required, editable);
}
if (json_field.type === "string" && json_field.textarea === true) {
return render_textarea(json_field, default_value, "string", is_required);
return render_textarea(json_field, default_value, "string", is_required, editable);
}
if (default_value !== undefined) {
......@@ -217,11 +251,14 @@
if (is_required) {
domsugar_input_dict.required = true;
}
return domsugar('input', domsugar_input_dict);
input = domsugar('input', domsugar_input_dict);
if (!editable) {
input.setAttribute('readonly', true);
}
return input;
}
function render_subform(json_field, default_dict, root, path) {
function render_subform(json_field, default_dict, root, path, editable) {
var div_input,
key,
div,
......@@ -229,7 +266,6 @@
input,
default_value,
default_used_list = [],
default_div,
is_required;
if (default_dict === undefined) {
......@@ -248,31 +284,30 @@
title: json_field.description
});
div_input = domsugar("div", {
"class": "input"
}, [
domsugar('input', {
type: "text",
// Name is only meaningfull to automate tests
name: "ADD" + path
}),
domsugar('button', {
value: btoa(JSON.stringify(json_field.patternProperties['.*'])),
"class": "add-sub-form",
type: "button",
name: path,
text: "+"
})
]);
div.appendChild(div_input);
if (editable) {
div_input = domsugar("div", {
"class": "input"
}, [
domsugar('input', {
type: "text",
// Name is only meaningfull to automate tests
name: "ADD" + path
}),
domsugar('button', {
value: btoa(JSON.stringify(json_field.patternProperties['.*'])),
"class": "add-sub-form",
type: "button",
name: path,
text: "+"
})
]);
div.appendChild(div_input);
}
for (default_value in default_dict) {
if (default_dict.hasOwnProperty(default_value)) {
default_div = domsugar("div", {
"class": "slapos-parameter-dict-key"
}, [
domsugar('label', {
if (editable) {
label = domsugar('label', {
text: default_value,
'class': "slapos-parameter-dict-key"
}, [
......@@ -281,14 +316,22 @@
"class": "bt_close CLOSE" + path + "/" + default_value,
title: "Remove this parameter section."
})
])
]);
]);
} else {
label = domsugar('label', {
text: default_value,
'class': "slapos-parameter-dict-key"
});
}
div.appendChild(render_subform(
json_field.patternProperties['.*'],
default_dict[default_value],
default_div,
path + "/" + default_value
domsugar("div", {
"class": "slapos-parameter-dict-key"
}, [label]),
path + "/" + default_value,
editable
));
}
}
......@@ -322,45 +365,46 @@
for (key in json_field.properties) {
if (json_field.properties.hasOwnProperty(key)) {
label = domsugar("label", {
'text': json_field.properties[key].title
});
is_required = false;
if ((Array.isArray(json_field.required)) && (json_field.required.includes(key))) {
is_required = true;
}
if (json_field.properties[key].type === 'object') {
label.setAttribute("class", "slapos-parameter-dict-key");
div_input = render_subform(json_field.properties[key],
default_dict[key],
domsugar("div", {"class": "input"}),
path + "/" + key);
} else {
input = render_field(
json_field.properties[key],
default_dict[key],
is_required
);
input.name = path + "/" + key;
input.setAttribute("class", "slapos-parameter");
input.setAttribute("placeholder", " ");
div_input = domsugar("div", {"class": "input"}, [input]);
}
default_used_list.push(key);
if (json_field.properties[key]['default'] !== undefined) {
div_input.appendChild(
domsugar("span",
{'text': '(default = ' + json_field.properties[key]['default'] + ')'})
if (editable || default_dict[key] !== undefined) {
label = domsugar("label", {
'text': json_field.properties[key].title
});
is_required = false;
if ((Array.isArray(json_field.required)) && (json_field.required.includes(key))) {
is_required = true;
}
if (json_field.properties[key].type === 'object') {
label.setAttribute("class", "slapos-parameter-dict-key");
div_input = render_subform(json_field.properties[key],
default_dict[key],
domsugar("div", {"class": "input"}),
path + "/" + key,
editable);
} else {
input = render_field(
json_field.properties[key],
default_dict[key],
is_required,
editable
);
input.name = path + "/" + key;
div_input = domsugar("div", {"class": "input"}, [input]);
}
default_used_list.push(key);
if (json_field.properties[key]['default'] !== undefined) {
div_input.appendChild(
domsugar("span",
{'text': '(default = ' + json_field.properties[key]['default'] + ')'})
);
}
div_input.appendChild(domsugar("span", {'class': 'error'}));
root.appendChild(
domsugar("div", {
"class": "subfield",
title: json_field.properties[key].description
}, [label, div_input])
);
}
div_input.appendChild(domsugar("span", {'class': 'error'}));
root.appendChild(
domsugar("div", {
"class": "subfield",
title: json_field.properties[key].description
}, [label, div_input])
);
}
}
for (key in default_dict) {
......@@ -379,10 +423,8 @@
editable)
]);
} else {
input = render_field({"type": "string", "textarea": true}, default_dict[key], false);
input = render_field({"type": "string", "textarea": true}, default_dict[key], false, editable);
input.name = path + "/" + key;
input.setAttribute("class", "slapos-parameter");
input.setAttribute("placeholder", " ");
div = domsugar("div", {
title: key,
"class": "subfield"
......@@ -481,7 +523,6 @@
convertOnMultiLevel(entry, json_dict[entry], multi_level_dict);
}
}
return multi_level_dict;
}
......@@ -683,6 +724,7 @@
var fieldset,
fieldset_list = g.element.querySelectorAll('fieldset'),
div_error,
textarea,
show_raw_button = g.element.querySelector("button.slapos-show-raw-parameter"),
show_form_button = g.element.querySelector("button.slapos-show-form");
......@@ -715,16 +757,20 @@
} else {
div_error = domsugar('div');
}
textarea = domsugar('textarea', {
rows: "10",
cols: "80",
name: "text_content",
text: g.state.parameter_xml
});
if (!g.state.editable) {
textarea.setAttribute("readonly", true);
}
fieldset = domsugar('fieldset', [
domsugar('div', {
'class': 'field'
}, [
domsugar('textarea', {
rows: "10",
cols: "80",
name: "text_content",
text: g.state.parameter_xml
})
textarea
]),
// div error
div_error
......@@ -744,10 +790,10 @@
var serialisation = gadget.state.serialisation,
json_url = gadget.state.json_url,
parameter_xml = gadget.state.parameter_xml,
restricted_softwaretype = gadget.state.restricted_softwaretype,
shared = gadget.state.shared,
softwaretype = gadget.state.softwaretype,
softwareindex = gadget.state.softwareindex,
editable = gadget.state.editable,
to_hide = gadget.element.querySelector("button.slapos-show-form"),
to_show = gadget.element.querySelector("button.slapos-show-raw-parameter");
......@@ -776,18 +822,27 @@
lowest_index = 999,
lowest_option_index;
if (!editable || gadget.state.restricted_softwaretype === true) {
input.classList.add("readonly");
input["aria-disabled"] = "true";
input["tab-index"] = "-1";
}
if (input.children.length === 0) {
if (option_selected === undefined) {
// search by the lowest index
for (option_index in json['software-type']) {
if (json['software-type'].hasOwnProperty(option_index)) {
if (json['software-type'][option_index].index === undefined) {
json['software-type'][option_index].index = 999;
}
if ((gadget.state.software_type_list.length === 0) ||
(gadget.state.software_type_list.includes(option_index))) {
if (json['software-type'][option_index].index === undefined) {
json['software-type'][option_index].index = 999;
}
if (json['software-type'][option_index].index < lowest_index) {
lowest_index = json['software-type'][option_index].index;
lowest_option_index = option_index;
if (json['software-type'][option_index].index < lowest_index) {
lowest_index = json['software-type'][option_index].index;
lowest_option_index = option_index;
}
}
}
}
......@@ -795,61 +850,66 @@
for (option_index in json['software-type']) {
if (json['software-type'].hasOwnProperty(option_index)) {
option = document.createElement("option");
if (json['software-type'][option_index]['software-type'] !== undefined) {
option.value = json['software-type'][option_index]['software-type'];
} else {
option.value = option_index;
}
if ((gadget.state.software_type_list.length === 0) ||
(gadget.state.software_type_list.includes(option_index))) {
if (json['software-type'][option_index].shared === undefined) {
json['software-type'][option_index].shared = false;
}
option['data-id'] = option_index;
option.textContent = json['software-type'][option_index].title;
if (json['software-type'][option_index].index) {
option['data-index'] = json['software-type'][option_index].index;
} else {
option = domsugar("option", {
text: json['software-type'][option_index].title,
value: option_index
});
option['data-id'] = option_index;
option['data-index'] = 999;
}
option['data-shared'] = json['software-type'][option_index].shared;
if (option_index === lowest_option_index) {
option_selected = option.value;
option.selected = true;
option_selected_index = option_index;
if (json['software-type'][option_index].shared === true) {
parameter_shared.value = true;
} else {
parameter_shared.value = false;
if (json['software-type'][option_index]['software-type'] !== undefined) {
option.value = json['software-type'][option_index]['software-type'];
}
if (shared === undefined) {
shared = parameter_shared.value;
}
}
if (json['software-type'][option_index].shared === undefined) {
json['software-type'][option_index].shared = false;
}
if (json['software-type'][option_index].index) {
option['data-index'] = json['software-type'][option_index].index;
}
option['data-shared'] = json['software-type'][option_index].shared;
if (option_index === lowest_option_index) {
option_selected = option.value;
option.selected = true;
option_selected_index = option_index;
if (json['software-type'][option_index].shared === true) {
parameter_shared.value = true;
} else {
parameter_shared.value = false;
}
if (shared === undefined) {
shared = parameter_shared.value;
}
}
if ((option_selected_index === undefined) &&
(option.value === option_selected) &&
(Boolean(shared) === Boolean(json['software-type'][option_index].shared))) {
option.selected = true;
option_selected_index = option_index;
if (json['software-type'][option_index].shared === true) {
parameter_shared.value = true;
} else {
parameter_shared.value = false;
if ((option_selected_index === undefined) &&
(option.value === option_selected) &&
(Boolean(shared) === Boolean(json['software-type'][option_index].shared))) {
option.selected = true;
option_selected_index = option_index;
if (json['software-type'][option_index].shared === true) {
parameter_shared.value = true;
} else {
parameter_shared.value = false;
}
}
}
if (restricted_softwaretype === true) {
if (option.value === softwaretype) {
if (Boolean(shared) === Boolean(json['software-type'][option_index].shared)) {
selection_option_list.push(option);
if (gadget.state.restricted_softwaretype === true) {
if (option.value === softwaretype) {
if (Boolean(shared) === Boolean(json['software-type'][option_index].shared)) {
selection_option_list.push(option);
// We expect a single possible occurence per software type
break;
}
}
} else {
selection_option_list.push(option);
}
} else {
selection_option_list.push(option);
}
}
}
......@@ -950,7 +1010,7 @@
var fieldset_list = gadget.element.querySelectorAll('fieldset'),
fieldset = document.createElement("fieldset");
fieldset = render_subform(json, parameter_dict, fieldset, undefined);
fieldset = render_subform(json, parameter_dict, fieldset, undefined, editable);
fieldset_list[1].parentNode.replaceChild(
fieldset,
fieldset_list[1]
......@@ -1014,7 +1074,9 @@
})
.declareMethod('render', function (options) {
var parameter_hash = options.value.parameter.parameter_hash,
var restricted_softwaretype = false,
software_type_list = [],
parameter_hash = options.value.parameter.parameter_hash,
// XXX Do we directly get parameter_xml parameter?
parameter_xml = options.value.parameter.parameter_xml;
......@@ -1023,18 +1085,31 @@
parameter_xml = atob(parameter_hash);
}
if (options.value.parameter.software_type_list !== undefined) {
software_type_list = options.value.parameter.software_type_list;
}
if (options.value.parameter.softwaretype !== undefined) {
restricted_softwaretype = true;
// exceptional situation where the default item must be in
// the list.
software_type_list.push(options.value.parameter.softwaretype);
}
return this.changeState({
// Not used parameters
// editable: options.editable,
// hidden: options.hidden,
// key: options.key,
serialisation: options.serialisation,
json_url: options.value.parameter.json_url,
parameter_xml: parameter_xml,
restricted_softwaretype: options.value.parameter.restricted_softwaretype,
restricted_softwaretype: restricted_softwaretype,
shared: options.value.parameter.shared,
softwaretype: options.value.parameter.softwaretype,
software_type_list: software_type_list,
softwareindex: options.value.parameter.softwareindex,
editable: options.editable,
// Force refresh in any case
render_timestamp: new Date().getTime()
});
......@@ -1057,6 +1132,7 @@
return updateParameterForm(gadget);
}
// @ts-ignore
if (evt.target.className.indexOf("slapos-parameter") !== -1) {
// getContent is protected by a mutex which prevent
// onchangestate to be called in parallel
......@@ -1069,14 +1145,17 @@
// Only handle click on BUTTON element
var gadget = this,
queue,
// @ts-ignore
tag_name = evt.target.tagName;
if ((tag_name === 'LABEL') &&
// @ts-ignore
(evt.target.className.indexOf("slapos-parameter-dict-key") !== -1)) {
return collapseParameter(evt.target);
}
if ((tag_name === 'SPAN') &&
// @ts-ignore
(evt.target.className.indexOf("bt_close") !== -1)) {
return removeSubParameter(evt.target);
}
......@@ -1091,6 +1170,7 @@
queue = gadget.getContent();
if ((tag_name === 'BUTTON') &&
// @ts-ignore
(evt.target.className.indexOf("slapos-show-form") !== -1)) {
return queue
.push(function () {
......@@ -1099,6 +1179,7 @@
}
if ((tag_name === 'BUTTON') &&
// @ts-ignore
(evt.target.className.indexOf("slapos-show-raw-parameter") !== -1)) {
return queue
.push(function () {
......@@ -1132,6 +1213,9 @@
gadget.state.shared = 1;
content_dict.shared = 1;
}
if (!gadget.state.editable) {
return gadget.state.parameter_xml;
}
if (text_content !== null) {
// Don't provide blank string since the parameter will not able to load
// itself. If the user removed the values, provide an empty parameter default.
......
......@@ -280,7 +280,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>1004.33938.61743.7680</string> </value>
<value> <string>1004.35604.19918.32529</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -298,7 +298,7 @@
</tuple>
<state>
<tuple>
<float>1669224195.85</float>
<float>1669324961.21</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -51,6 +51,7 @@
.push(function () {
return gadget.redirect({"command": "change",
"options": {"url_string": doc.url_string,
"software_type": doc.software_type,
"parameter_output": doc.text_content}});
});
}, function (error) {
......@@ -65,6 +66,7 @@
})
.declareMethod("triggerSubmit", function () {
// @ts-ignore
return this.element.querySelector('button[type="submit"]').click();
})
......@@ -74,8 +76,9 @@
}
return this.changeState({
"url_string": options.url_string,
"parameter_output": options.parameter_output
})
"parameter_output": options.parameter_output,
"software_type_list": options.software_type
});
})
.onStateChange(function onStateChange() {
......@@ -105,14 +108,16 @@
parameter_dict = {
'parameter' : {
'json_url': gadget.state.url_string.split('?')[0] + ".json",
'parameter_hash': parameter_hash,
'restricted_softwaretype': false
'parameter_hash': parameter_hash
}
};
if (gadget.state.software_type_list) {
parameter_dict.parameter.software_type_list = gadget.state.software_type_list.split(',');
}
return result[0].render({
erp5_document: {
"_embedded": {"_view": {
"my_url_string": {
"your_url_string": {
"description": "Software Release Url",
"title": "Software Release URL",
"default": default_url,
......@@ -136,6 +141,18 @@
"hidden": gadget.state.url_string === "",
"type": "GadgetField"
},
"your_software_type": {
"description": "",
"title": "Software type",
"default": gadget.state.software_type_list,
"css_class": "",
"required": 0,
"editable": 1,
"sandbox": "",
"key": "software_type",
"hidden": 1,
"type": "StringField"
},
"your_parameter_output": {
"description": "",
"title": "Parameters Output",
......@@ -159,8 +176,7 @@
"key": "parameter_hash",
"hidden": gadget.state.parameter_output === undefined,
"type": "StringField"
},
}
}},
"_links": {
"type": {
......@@ -172,14 +188,15 @@
form_definition: {
group_list: [[
"center",
[["my_url_string"], ["your_parameter_output"], ["your_parameter_hash"], ["your_text_content"]]
[["your_url_string"], ["your_parameter_output"], ["your_software_type"], ["your_parameter_hash"], ["your_text_content"]]
]]
}
})
.push(function () {
return gadget.getUrlFor({"command": "change",
"options": {"url_string": undefined,
"parameter_output": undefined}});
"software_type": undefined,
"parameter_output": undefined}});
})
.push(function (selection_url) {
return gadget.updateHeader({
......
......@@ -277,7 +277,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>1003.56162.18447.41164</string> </value>
<value> <string>1004.41258.43166.28757</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -295,7 +295,7 @@
</tuple>
<state>
<tuple>
<float>1666635866.16</float>
<float>1669664533.48</float>
<string>UTC</string>
</tuple>
</state>
......
<!DOCTYPE html>
<html>
<!--
data-i18n=Title
data-i18n=Instance Parameter
-->
<head>
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width, user-scalable=no" />
<title>Site List</title>
<!-- renderjs -->
<script src="rsvp.js" type="text/javascript"></script>
<script src="renderjs.js" type="text/javascript"></script>
<!-- custom script -->
<script src="gadget_erp5_page_slap_test_readonly_parameter_form.js" type="text/javascript"></script>
</head>
<body>
<form class="save_form ui-body-c" novalidate>
<button type="submit" class="ui-btn ui-btn-b ui-btn-inline
ui-icon-edit ui-btn-icon-right ui-screen-hidden"></button>
<div data-gadget-url="gadget_erp5_form.html"
data-gadget-scope="form_view"
data-gadget-sandbox="public">
</div>
</form>
</body>
</html>
<?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>
</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>
</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>default_reference</string> </key>
<value> <string>gadget_erp5_page_slap_test_readonly_parameter_form.html</string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>rjs_gadget_erp5_page_slap_test_readonly_parameter_form_html</string> </value>
</item>
<item>
<key> <string>language</string> </key>
<value> <string>en</string> </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 Test Parameter Form</string> </value>
</item>
<item>
<key> <string>version</string> </key>
<value> <string>003</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>1669085170.19</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>1004.31622.50166.32017</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>1669085301.63</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>1669085149.81</float>
<string>UTC</string>
</tuple>
</state>
</object>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
/*global window, rJS, RSVP, btoa */
/*jslint nomen: true, indent: 2, maxerr: 3, sub:true */
(function (window, rJS, RSVP) {
"use strict";
rJS(window)
/////////////////////////////////////////////////////////////////
// Acquired methods
/////////////////////////////////////////////////////////////////
.declareAcquiredMethod("updateHeader", "updateHeader")
.declareAcquiredMethod("updatePanel", "updatePanel")
.declareAcquiredMethod("getSetting", "getSetting")
.declareAcquiredMethod("getUrlFor", "getUrlFor")
.declareAcquiredMethod("redirect", "redirect")
.declareAcquiredMethod("jio_post", "jio_post")
.declareAcquiredMethod("jio_get", "jio_get")
.declareAcquiredMethod("jio_putAttachment", "jio_putAttachment")
.declareAcquiredMethod("notifySubmitting", "notifySubmitting")
.declareAcquiredMethod("notifySubmitted", 'notifySubmitted')
.declareAcquiredMethod("getTranslationList", "getTranslationList")
/////////////////////////////////////////////////////////////////
// declared methods
/////////////////////////////////////////////////////////////////
.allowPublicAcquisition('notifySubmit', function () {
return this.triggerSubmit();
})
.onEvent('submit', function () {
var gadget = this;
return gadget.notifySubmitting()
.push(function () {
return gadget.getDeclaredGadget('form_view');
})
.push(function (form_gadget) {
return form_gadget.checkValidity()
.push(function (is_valid) {
if (!is_valid) {
return null;
}
return form_gadget.getContent();
});
})
.push(function (doc) {
if (doc === null) {
return gadget.notifySubmitted({message: "Doc is empty", status: 'error'});
}
return gadget.getSetting("hateoas_url")
.push(function () {
return gadget.notifySubmitted({message: "All is fine, we reseted your form.", status: 'success'})
.push(function () {
return gadget.redirect({"command": "change",
"options": {"url_string": doc.url_string,
"software_type": doc.software_type,
"shared": doc.shared,
"parameter_output": doc.parameter_output}});
});
}, function (error) {
if (error.target.status === 409) {
return gadget.notifySubmitted({message: "Error 409", status: 'error'});
}
if (error.target.status === 400) {
return gadget.notifySubmitted({message: "Error 400", status: 'error'});
}
});
});
})
.declareMethod("triggerSubmit", function () {
// @ts-ignore
return this.element.querySelector('button[type="submit"]').click();
})
.declareMethod("render", function (options) {
if (options.url_string === undefined) {
options.url_string = "";
}
if (options.restricted_softwaretype === undefined) {
options.restricted_softwaretype = false;
}
return this.changeState({
"url_string": options.url_string,
"parameter_output": options.parameter_output,
"software_type": options.software_type,
"shared": options.shared,
"restricted_softwaretype": options.restricted_softwaretype
});
})
.onStateChange(function onStateChange() {
var gadget = this;
return new RSVP.Queue()
.push(function () {
return RSVP.all([
gadget.getDeclaredGadget('form_view'),
gadget.getSetting("hateoas_url")
]);
})
.push(function (result) {
var parameter_hash,
parameter_dict,
default_url;
if (gadget.state.url_string === "") {
default_url = result[1] + "sample-software-schema/simpledemo/software.cfg";
} else {
default_url = gadget.state.url_string;
}
if (gadget.state.parameter_output === undefined) {
parameter_hash = btoa('<?xml version="1.0" encoding="utf-8" ?><instance></instance>');
} else {
parameter_hash = btoa(gadget.state.parameter_output);
}
parameter_dict = {
'parameter' : {
'json_url': gadget.state.url_string.split('?')[0] + ".json",
'parameter_hash': parameter_hash,
'softwaretype': gadget.state.software_type,
'restricted_softwaretype': false
}
};
if (gadget.state.shared === 'yes') {
parameter_dict['parameter']['shared'] = true;
}
return result[0].render({
erp5_document: {
"_embedded": {"_view": {
"your_url_string": {
"description": "Software Release Url",
"title": "Software Release URL",
"default": default_url,
"css_class": "",
"required": 1,
"editable": gadget.state.url_string === "",
"key": "url_string",
"hidden": 0,
"type": "StringField"
},
"your_text_content": {
"description": "",
"title": "Parameters",
"default": parameter_dict,
"css_class": "",
"required": 1,
"editable": 0,
"url": "gadget_erp5_page_slap_parameter_form.html",
"sandbox": "",
"key": "text_content",
"hidden": gadget.state.url_string === "",
"type": "GadgetField"
},
"your_software_type": {
"description": "Software Type",
"title": "Software Type",
"default": "default",
"css_class": "",
"required": 1,
"editable": gadget.state.url_string === "",
"key": "software_type",
"hidden": gadget.state.url_string !== "",
"type": "StringField"
},
"your_shared": {
"description": "Software Type",
"title": "Software Type",
"default": "no",
"css_class": "",
"required": 1,
"editable": gadget.state.url_string === "",
"key": "shared",
"hidden": gadget.state.url_string !== "",
"type": "StringField"
},
"your_text_content_to_load": {
"description": "",
"title": "Parameters to Load",
"default": '<?xml version="1.0" encoding="utf-8" ?><instance></instance>',
"css_class": "",
"required": 0,
"editable": 1,
"sandbox": "",
"key": "parameter_output",
"hidden": gadget.state.url_string !== "",
"type": "TextAreaField"
}
}},
"_links": {
"type": {
// form_list display portal_type in header
name: ""
}
}
},
form_definition: {
group_list: [[
"center",
[["your_url_string"], ["your_software_type"], ["your_shared"], ["your_text_content"], ['your_text_content_to_load']]
]]
}
})
.push(function () {
return gadget.getUrlFor({"command": "change",
"options": {"url_string": undefined,
"software_type": undefined,
"shared": undefined,
"parameter_output": undefined}});
})
.push(function (selection_url) {
var header_dict = {
page_title: "Parameter testing page",
selection_url: selection_url };
if (gadget.state.parameter_output === undefined) {
header_dict['submit_action'] = true;
}
return gadget.updateHeader(header_dict);
});
});
});
}(window, rJS, RSVP));
\ No newline at end of file
<?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>
</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>
</tuple>
</value>
</item>
<item>
<key> <string>categories</string> </key>
<value>
<tuple>
<string>contributor/person_module/1</string>
</tuple>
</value>
</item>
<item>
<key> <string>content_md5</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>creators</string> </key>
<value>
<tuple>
<string>cedric.le.ninivin</string>
</tuple>
</value>
</item>
<item>
<key> <string>default_reference</string> </key>
<value> <string>gadget_erp5_page_slap_test_readonly_parameter_form.js</string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>rjs_gadget_erp5_page_slap_test_readonly_parameter_form_js</string> </value>
</item>
<item>
<key> <string>language</string> </key>
<value>
<none/>
</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>1455284351.49</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>SlapOS Test ReadOnly Parameter Form JS</string> </value>
</item>
<item>
<key> <string>url_string</string> </key>
<value>
<none/>
</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>1669084864.53</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>1004.32728.24062.25344</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>1669152031.46</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>1669084700.39</float>
<string>UTC</string>
</tuple>
</state>
</object>
</value>
</item>
</dictionary>
</list>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -15,11 +15,13 @@ else:
mail_message.deliver()
message = translateString("Your account is being activated. You will receive an e-mail when activation is complete.")
url = "%s/login_form?portal_status_message=%s&%s" % (
url = "%s/login_form?%s" % (
context.getWebSectionValue().absolute_url(),
message,
make_query({"came_from": came_from})
make_query({
"portal_status_message": message,
"came_from": came_from
})
)
context.REQUEST.RESPONSE.setHeader('Location', url)
context.REQUEST.RESPONSE.setStatus(303)
return message
......@@ -197,6 +197,8 @@ web_page_module/rjs_slapos_load_software_schema_json
web_page_module/rjs_gadget_slapos_login_page_css
web_page_module/rjs_gadget_erp5_page_slap_test_parameter_form_js
web_page_module/rjs_gadget_erp5_page_slap_test_parameter_form_html
web_page_module/rjs_gadget_erp5_page_slap_test_readonly_parameter_form_html
web_page_module/rjs_gadget_erp5_page_slap_test_readonly_parameter_form_js
web_page_module/rjs_vkbeautify_js
web_page_module/slapos_admin_front_page
web_site_module/hostingjs
......
......@@ -144,6 +144,8 @@ web_page_module/rjs_gadget_erp5_page_slap_stop_instance_tree_js
web_page_module/rjs_gadget_erp5_page_slap_support_request_view_html
web_page_module/rjs_gadget_erp5_page_slap_test_parameter_form_html
web_page_module/rjs_gadget_erp5_page_slap_test_parameter_form_js
web_page_module/rjs_gadget_erp5_page_slap_test_readonly_parameter_form_html
web_page_module/rjs_gadget_erp5_page_slap_test_readonly_parameter_form_js
web_page_module/rjs_gadget_erp5_page_slap_ticket_list_html
web_page_module/rjs_gadget_erp5_page_slap_ticket_list_js
web_page_module/rjs_gadget_erp5_page_slap_ticket_view_js
......
......@@ -61,6 +61,7 @@
<td>//a[text()="TEST-SLAPOSJS-PROJECT 0"]</td>
<td></td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_content_loaded" />
<tal:block tal:define="header python: 'Project : ${title}';
dummy python: context.REQUEST.set('mapping', {'title': 'TEST-SLAPOSJS-PROJECT 0'}) ">
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>testSlapOSJSTestParameterEditorAllOfReadOnly</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test Parameter editor (AllOf ReadOnly) </title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr>
<td rowspan="1" colspan="3">Test Parameter editor (AllOf ReadOnly)</td>
</tr>
</thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/init_readonly" />
<tr>
<td colspan="3"><b> Set URL for the software release </b></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='url_string']</td>
<td>${base_url}/web_site_module/hostingjs/hateoas/sample-software-schema/simpledemo/software.cfg</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@name='parameter_output']</td>
<td tal:content="python: '<?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?><instance><parameter id=&quot;_&quot;>{&quot;simple-string&quot;: &quot;this is a simple string&quot;,&quot;simple-string-with-enum&quot;: &quot;simple string B&quot;,&quot;simple-boolean&quot;: true,&quot;simple-string-with-text-area&quot;: &quot;this is a simple string on a text area&quot;,&quot;simple-integer&quot;: 1,&quot;simple-integer-with-enum&quot;: 7,&quot;simple-numeric-integer&quot;: 2,&quot;simple-numeric-integer-enum&quot;: 13,&quot;simple-numeric-float&quot;: 2,&quot;simple-numeric-float-enum&quot;: 1.25,&quot;simple-object&quot;: { &quot;sample-object-string&quot;: &quot;this is a simple string on an object&quot;, &quot;simple-object-with-integer&quot;: 99, &quot;simple-object-with-integer-with-enum&quot;: 2},&quot;simple-object-dict&quot;: { &quot;Example of Simple object&quot;: { &quot;simple-object-dict-string-example&quot;: &quot;This an example of a string on an object&quot;,&quot;simple-object-dict-string-with-enum&quot;: &quot;String Sample A&quot; }}}</parameter></instance>'"></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='software_type']</td>
<td>jsondefault</td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" />
<tr>
<td>waitForElementPresent</td>
<td>//div[contains(@data-gadget-url,
'gadget_erp5_page_slap_parameter_form.html')]//select[@name="software_type"]//option[text()="JSON in XML"]
</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//div[contains(@data-gadget-url,
'gadget_erp5_page_slap_parameter_form.html')]//select[@name="software_type"]//option[text()="JSON in XML"]
</td>
<td></td>
</tr>
<tr>
<td colspan="3"><b> Fill the simple string</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-string" and @type="text" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-string" and @type="text" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-string" and @type="text" and @readonly="true"]</td>
<td>this is a simple string</td>
</tr>
<tr>
<td colspan="3"><b> Fill the string + enum</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-string-with-enum"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-string-with-enum"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-string-with-enum"]</td>
<td>simple string B</td>
</tr>
<tr>
<td colspan="3"><b> Fill the boolean</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-boolean"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-boolean"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-boolean"]</td>
<td>true</td>
</tr>
<tr>
<td colspan="3"><b> Fill the String on Text area</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@name="//simple-string-with-text-area"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//textarea[@name="//simple-string-with-text-area"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//textarea[@name="//simple-string-with-text-area"]</td>
<td>this is a simple string on a text area</td>
</tr>
<tr>
<td colspan="3"><b> Fill the simple integer</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-integer" and @type="number" and @readonly="true"]</td>
<td>1</td>
</tr>
<tr>
<td colspan="3"><b> Fill the integer + enum</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-integer-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-integer-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-integer-with-enum" and contains(@class, "readonly")]</td>
<td>7</td>
</tr>
<tr>
<td colspan="3"><b> Fill the simple numeric (integer)</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-numeric-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-numeric-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-numeric-integer" and @type="number" and @readonly="true"]</td>
<td>2</td>
</tr>
<tr>
<td colspan="3"><b> Fill the numeric integer + enum</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-numeric-integer-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-numeric-integer-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-numeric-integer-enum" and contains(@class, "readonly")]</td>
<td>13</td>
</tr>
<tr>
<td colspan="3"><b> Fill the simple numeric (float)</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-numeric-float" and @type="number" and @readonly="true" and @step="any"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-numeric-float" and @type="number" and @readonly="true"and @step="any"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-numeric-float" and @type="number" and @readonly="true"and @step="any"]</td>
<td>2</td>
</tr>
<tr>
<td colspan="3"><b> Fill the numeric float + enum</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-numeric-float-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-numeric-float-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-numeric-float-enum" and contains(@class, "readonly")]</td>
<td>1.25</td>
</tr>
<tr>
<td colspan="3"><b> Fill the simple string on an object</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-object/sample-object-string" and @type="text" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-object/sample-object-string" and @type="text" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-object/sample-object-string" and @type="text" and @readonly="true"]</td>
<td>this is a simple string on an object</td>
</tr>
<tr>
<td colspan="3"><b> Fill the simple numeric (integer) on an object</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-object/simple-object-with-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-object/simple-object-with-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-object/simple-object-with-integer" and @type="number" and @readonly="true"]</td>
<td>99</td>
</tr>
<tr>
<td colspan="3"><b> Fill the numeric integer + enum</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-object/simple-object-with-integer-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-object/simple-object-with-integer-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-object/simple-object-with-integer-with-enum" and contains(@class, "readonly")]</td>
<td>2</td>
</tr>
<tr>
<td colspan="3"><b> Add one object </b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-object-dict/Example of Simple object/simple-object-dict-string-example"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-object-dict/Example of Simple object/simple-object-dict-string-example"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-object-dict/Example of Simple object/simple-object-dict-string-example"]</td>
<td>This an example of a string on an object</td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-object-dict/Example of Simple object/simple-object-dict-string-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-object-dict/Example of Simple object/simple-object-dict-string-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-object-dict/Example of Simple object/simple-object-dict-string-with-enum" and contains(@class, "readonly")]</td>
<td>String Sample A</td>
</tr>
</tbody>
</table>
</body>
</html>
\ No newline at end of file
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>testSlapOSJSTestParameterEditorFilterSoftwareTypeList</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test Parameter editor Change Serialisation </title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr>
<td rowspan="1" colspan="3">Test Parameter editor (Filter software_type)</td>
</tr>
</thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_CommonTemplate/macros/init" />
<tr>
<td>open</td>
<td>${base_url}/web_site_module/hostingjs/#/?page=slap_test_parameter_form</td>
<td></td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_app_loaded" />
<tr>
<td>waitForElementPresent</td>
<td>//input[@name='url_string']</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name='url_string']</td>
<td></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name='software_type']</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name='software_type']</td>
<td></td>
</tr>
<tr>
<td colspan="3"><b> Set URL for the software release </b></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='url_string']</td>
<td>${base_url}/web_site_module/hostingjs/hateoas/sample-software-schema/minimal_dual_type/software.cfg</td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='software_type']</td>
<td>jsondefault</td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" />
<tr>
<td colspan="3"><b> Only JSON in XML Software type is available</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//div[contains(@data-gadget-url,
'gadget_erp5_page_slap_parameter_form.html')]//select[@name="software_type"]//option[text()="JSON in XML"]
</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//div[contains(@data-gadget-url,
'gadget_erp5_page_slap_parameter_form.html')]//select[@name="software_type"]//option[text()="JSON in XML"]
</td>
<td></td>
</tr>
<tr>
<td>assertElementNotPresent</td>
<td>//div[contains(@data-gadget-url,
'gadget_erp5_page_slap_parameter_form.html')]//select[@name="software_type"]//option[text()="Default"]
</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//div[contains(@data-gadget-url,
'gadget_erp5_page_slap_parameter_form.html')]//select[@name="software_type"]
</td>
<td>jsondefault</td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-string-in-json" and @type="text"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-string-in-json" and @type="text"]</td>
<td></td>
</tr>
<tr>
<td>assertElementNotPresent</td>
<td>//input[@name="//simple-string" and @type="text"]</td>
<td></td>
</tr>
<tr>
<td colspan="3"><b> Fill the simple string</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-string-in-json" and @type="text"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-string-in-json" and @type="text"]</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name="//simple-string-in-json" and @type="text"]</td>
<td>this is a simple string</td>
</tr>
<tr>
<td colspan="3"><b> Fill the simple integer</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-integer-in-json" and @type="number"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-integer-in-json" and @type="number"]</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name="//simple-integer-in-json" and @type="number"]</td>
<td>1</td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/click_proceed_and_wait_for_hash" />
<tr>
<td>waitForTextPresent</td>
<td>PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPGluc3RhbmNlPgogICAgPHBhcmFtZXRlciBpZ</td>
<td></td>
</tr>
<tr>
<td>assertTextPresent</td>
<td>PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPGluc3RhbmNlPgogICAgPHBhcmFtZXRlciBpZD0iXyI+ewogICAgInNpbXBsZS1zdHJpbmctaW4tanNvbiI6ICJ0aGlzIGlzIGEgc2ltcGxlIHN0cmluZyIsCiAgICAic2ltcGxlLWludGVnZXItaW4tanNvbiI6IDEKfTwvcGFyYW1ldGVyPgo8L2luc3RhbmNlPg==</td>
<td></td>
</tr>
</tbody>
</table>
</body>
</html>
\ No newline at end of file
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>testSlapOSJSTestParameterEditorFilterSoftwareTypeListXML</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test Parameter editor Change Serialisation </title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr>
<td rowspan="1" colspan="3">Test Parameter editor (Filter software_type)</td>
</tr>
</thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_CommonTemplate/macros/init" />
<tr>
<td>open</td>
<td>${base_url}/web_site_module/hostingjs/#/?page=slap_test_parameter_form</td>
<td></td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_app_loaded" />
<tr>
<td>waitForElementPresent</td>
<td>//input[@name='url_string']</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name='url_string']</td>
<td></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name='software_type']</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name='software_type']</td>
<td></td>
</tr>
<tr>
<td colspan="3"><b> Set URL for the software release </b></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='url_string']</td>
<td>${base_url}/web_site_module/hostingjs/hateoas/sample-software-schema/minimal_dual_type/software.cfg</td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='software_type']</td>
<td>default</td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" />
<tr>
<td colspan="3"><b> Only Default Software type is available</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//div[contains(@data-gadget-url,
'gadget_erp5_page_slap_parameter_form.html')]//select[@name="software_type"]//option[text()="Default"]
</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//div[contains(@data-gadget-url,
'gadget_erp5_page_slap_parameter_form.html')]//select[@name="software_type"]//option[text()="Default"]
</td>
<td></td>
</tr>
<tr>
<td>assertElementNotPresent</td>
<td>//div[contains(@data-gadget-url,
'gadget_erp5_page_slap_parameter_form.html')]//select[@name="software_type"]//option[text()="JSON in XML"]
</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//div[contains(@data-gadget-url,
'gadget_erp5_page_slap_parameter_form.html')]//select[@name="software_type"]
</td>
<td>default</td>
</tr>
<tr>
<td colspan="3"><b> Fill the simple string</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-string" and @type="text"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-string" and @type="text"]</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name="//simple-string" and @type="text"]</td>
<td>this is a simple string</td>
</tr>
<tr>
<td colspan="3"><b> Fill the simple integer</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-integer" and @type="number"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-integer" and @type="number"]</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name="//simple-integer" and @type="number"]</td>
<td>1</td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/click_proceed_and_wait_for_hash" />
<tr>
<td>waitForTextPresent</td>
<td>PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPGluc3RhbmNlPgogICAgPHBhcmFtZXRlciBpZ</td>
<td></td>
</tr>
<tr>
<td>assertTextPresent</td>
<td>PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPGluc3RhbmNlPgogICAgPHBhcmFtZXRlciBpZD0ic2ltcGxlLXN0cmluZyI+dGhpcyBpcyBhIHNpbXBsZSBzdHJpbmc8L3BhcmFtZXRlcj4KICAgIDxwYXJhbWV0ZXIgaWQ9InNpbXBsZS1pbnRlZ2VyIj4xPC9wYXJhbWV0ZXI+CjwvaW5zdGFuY2U+</td>
<td></td>
</tr>
</tbody>
</table>
</body>
</html>
\ No newline at end of file
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>testSlapOSJSTestParameterEditorJSONinXMLReadOnly</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test Parameter editor (XML Serialisation) </title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr>
<td rowspan="1" colspan="3">Test Parameter editor (JSON in XML Serialisation)</td>
</tr>
</thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/init_readonly" />
<tr>
<td colspan="3"><b> Set URL for the software release </b></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='url_string']</td>
<td>${base_url}/web_site_module/hostingjs/hateoas/sample-software-schema/minimal_json_in_xml_demo/software.cfg</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@name='parameter_output']</td>
<td tal:content="python: '<?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?><instance><parameter id=&quot;_&quot;>{&quot;simple-string&quot;: &quot;this is a simple string&quot;,&quot;simple-string-with-enum&quot;: &quot;simple string B&quot;,&quot;simple-boolean&quot;: true,&quot;simple-string-with-text-area&quot;: &quot;this is a simple string on a text area&quot;,&quot;simple-integer&quot;: 1,&quot;simple-integer-with-enum&quot;: 7,&quot;simple-numeric-integer&quot;: 2,&quot;simple-numeric-integer-enum&quot;: 13,&quot;simple-numeric-float&quot;: 2,&quot;simple-numeric-float-enum&quot;: 1.25,&quot;simple-object&quot;: { &quot;sample-object-string&quot;: &quot;this is a simple string on an object&quot;, &quot;simple-object-with-integer&quot;: 99, &quot;simple-object-with-integer-with-enum&quot;: 2},&quot;simple-object-dict&quot;: { &quot;Example of Simple object&quot;: { &quot;simple-object-dict-string-example&quot;: &quot;This an example of a string on an object&quot;,&quot;simple-object-dict-string-with-enum&quot;: &quot;String Sample A&quot; }}}</parameter></instance>'"></td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" />
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/wait_software_type_selection_default" />
<tr>
<td colspan="3"><b> Fill the simple string</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-string" and @type="text" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-string" and @type="text" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name="//simple-string" and @type="text" and @readonly="true"]</td>
<td>this is a simple string</td>
</tr>
<tr>
<td colspan="3"><b> Fill the string + enum</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-string-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-string-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-string-with-enum" and contains(@class, "readonly")]</td>
<td>simple string B</td>
</tr>
<tr>
<td colspan="3"><b> Fill the boolean</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-boolean" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-boolean" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-boolean" and contains(@class, "readonly")]</td>
<td>true</td>
</tr>
<tr>
<td colspan="3"><b> Fill the String on Text area</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@name="//simple-string-with-text-area" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//textarea[@name="//simple-string-with-text-area" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//textarea[@name="//simple-string-with-text-area" and @readonly="true"]</td>
<td>this is a simple string on a text area</td>
</tr>
<tr>
<td colspan="3"><b> Fill the simple integer</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-integer" and @type="number" and @readonly="true"]</td>
<td>1</td>
</tr>
<tr>
<td colspan="3"><b> Fill the integer + enum</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-integer-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-integer-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-integer-with-enum" and contains(@class, "readonly")]</td>
<td>7</td>
</tr>
<tr>
<td colspan="3"><b> Fill the simple numeric (integer)</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-numeric-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-numeric-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-numeric-integer" and @type="number" and @readonly="true"]</td>
<td>2</td>
</tr>
<tr>
<td colspan="3"><b> Fill the numeric integer + enum</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-numeric-integer-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-numeric-integer-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-numeric-integer-enum" and contains(@class, "readonly")]</td>
<td>13</td>
</tr>
<tr>
<td colspan="3"><b> Fill the simple numeric (float)</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-numeric-float" and @type="number" and @step="any" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-numeric-float" and @type="number"and @step="any" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-numeric-float" and @type="number"and @step="any" and @readonly="true"]</td>
<td>2</td>
</tr>
<tr>
<td colspan="3"><b> Fill the numeric float + enum</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-numeric-float-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-numeric-float-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-numeric-float-enum" and contains(@class, "readonly")]</td>
<td>1.25</td>
</tr>
<tr>
<td colspan="3"><b> Fill the simple string on an object</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-object/sample-object-string" and @type="text" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-object/sample-object-string" and @type="text" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-object/sample-object-string" and @type="text" and @readonly="true"]</td>
<td>this is a simple string on an object</td>
</tr>
<tr>
<td colspan="3"><b> Fill the simple numeric (integer) on an object</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-object/simple-object-with-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-object/simple-object-with-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-object/simple-object-with-integer" and @type="number" and @readonly="true"]</td>
<td>99</td>
</tr>
<tr>
<td colspan="3"><b> Fill the numeric integer + enum</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-object/simple-object-with-integer-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-object/simple-object-with-integer-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-object/simple-object-with-integer-with-enum" and contains(@class, "readonly")]</td>
<td>2</td>
</tr>
<tr>
<td colspan="3"><b> Add one object </b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-object-dict/Example of Simple object/simple-object-dict-string-example" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-object-dict/Example of Simple object/simple-object-dict-string-example" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-object-dict/Example of Simple object/simple-object-dict-string-example" and @readonly="true"]</td>
<td>This an example of a string on an object</td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-object-dict/Example of Simple object/simple-object-dict-string-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-object-dict/Example of Simple object/simple-object-dict-string-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-object-dict/Example of Simple object/simple-object-dict-string-with-enum" and contains(@class, "readonly")]</td>
<td>String Sample A</td>
</tr>
</tbody>
</table>
</body>
</html>
\ No newline at end of file
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>testSlapOSJSTestParameterEditorKVMDefaultReadOnly</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test Parameter editor (AllOf) </title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr>
<td rowspan="1" colspan="3">Test Parameter editor (AllOf)</td>
</tr>
</thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/init_readonly" />
<tr>
<td colspan="3"><b> Set URL for the software release </b></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='url_string']</td>
<td>https://lab.nexedi.com/nexedi/slapos/raw/1.0.289/software/kvm/software.cfg</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@name='parameter_output']</td>
<td tal:content="python: '<?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?><instance><parameter id=&quot;_&quot;>{&quot;ram-size&quot;: 4096,&quot;cpu-count&quot;: 3}</parameter></instance>'"></td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" />
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/wait_software_type_selection_default" />
<tr>
<td colspan="3"><b> Check ram size</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//ram-size" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//ram-size" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//ram-size" and @type="number" and @readonly="true"]</td>
<td>4096</td>
</tr>
<tr>
<td colspan="3"><b> Check CPU count</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//cpu-count" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//cpu-count" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//cpu-count" and @type="number" and @readonly="true"]</td>
<td>3</td>
</tr>
</tbody>
</table>
</body>
</html>
\ No newline at end of file
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>testSlapOSJSTestParameterEditorORSAmarisoftTD1900eNBReadOnly</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test Parameter editor (eNB Simpler Test) </title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr>
<td rowspan="1" colspan="3">Test Parameter editor (eNB Test)</td>
</tr>
</thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/init_readonly" />
<tr>
<td colspan="3"><b> Set URL for the software release </b></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='url_string']</td>
<td>https://lab.nexedi.com/nexedi/slapos/raw/1.0.286/software/ors-amarisoft/software-tdd1900.cfg</td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSORSParameterCommonTemplate/macros/basic_rx_tx_scenario_readonly" />
</tbody>
</table>
</body>
</html>
\ No newline at end of file
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>testSlapOSJSTestParameterEditorORSAmarisoftTD1900gNBEPCSimCardReadOnly</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test Parameter editor (gNB Simcard Simpler Test) </title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr>
<td rowspan="1" colspan="3">Test Parameter editor (gNB Simcard Test)</td>
</tr>
</thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/init_readonly" />
<tr>
<td colspan="3"><b> Set URL for the software release </b></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='url_string']</td>
<td>https://lab.nexedi.com/nexedi/slapos/raw/1.0.286/software/ors-amarisoft/software-tdd1900.cfg</td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSORSParameterCommonTemplate/macros/basic_rx_tx_scenario_readonly" />
</tbody>
</table>
</body>
</html>
\ No newline at end of file
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>testSlapOSJSTestParameterEditorORSAmarisoftTD2600eNBReadOnly</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test Parameter editor (eNB Simpler Test) </title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr>
<td rowspan="1" colspan="3">Test Parameter editor (eNB Test)</td>
</tr>
</thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/init_readonly" />
<tr>
<td colspan="3"><b> Set URL for the software release </b></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='url_string']</td>
<td>https://lab.nexedi.com/nexedi/slapos/raw/1.0.286/software/ors-amarisoft/software-tdd2600.cfg</td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSORSParameterCommonTemplate/macros/basic_rx_tx_scenario_readonly" />
</tbody>
</table>
</body>
</html>
\ No newline at end of file
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>testSlapOSJSTestParameterEditorORSAmarisoftTD2600gNBEPCSimCardReadOnly</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test Parameter editor (gNB Simcard Simpler Test) </title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr>
<td rowspan="1" colspan="3">Test Parameter editor (gNB Simcard Test)</td>
</tr>
</thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/init_readonly" />
<tr>
<td colspan="3"><b> Set URL for the software release </b></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='url_string']</td>
<td>https://lab.nexedi.com/nexedi/slapos/raw/1.0.286/software/ors-amarisoft/software-tdd2600.cfg</td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSORSParameterCommonTemplate/macros/basic_rx_tx_scenario_readonly" />
</tbody>
</table>
</body>
</html>
\ No newline at end of file
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>testSlapOSJSTestParameterEditorORSAmarisoftTD3500eNBReadOnly</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test Parameter editor (eNB Simpler Test) </title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr>
<td rowspan="1" colspan="3">Test Parameter editor (eNB Test)</td>
</tr>
</thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/init_readonly" />
<tr>
<td colspan="3"><b> Set URL for the software release </b></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='url_string']</td>
<td>https://lab.nexedi.com/nexedi/slapos/raw/1.0.286/software/ors-amarisoft/software-tdd3500.cfg</td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSORSParameterCommonTemplate/macros/basic_rx_tx_scenario_readonly" />
</tbody>
</table>
</body>
</html>
\ No newline at end of file
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>testSlapOSJSTestParameterEditorORSAmarisoftTD3500gNBEPCSimCardReadOnly</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test Parameter editor (gNB Simcard Simpler Test) </title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr>
<td rowspan="1" colspan="3">Test Parameter editor (gNB Simcard Test)</td>
</tr>
</thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/init_readonly" />
<tr>
<td colspan="3"><b> Set URL for the software release </b></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='url_string']</td>
<td>https://lab.nexedi.com/nexedi/slapos/raw/1.0.286/software/ors-amarisoft/software-tdd3500.cfg</td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSORSParameterCommonTemplate/macros/basic_rx_tx_scenario_readonly" />
</tbody>
</table>
</body>
</html>
\ No newline at end of file
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>testSlapOSJSTestParameterEditorORSAmarisoftTD3700eNBReadOnly</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test Parameter editor (eNB Simpler Test) </title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr>
<td rowspan="1" colspan="3">Test Parameter editor (eNB Test)</td>
</tr>
</thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/init_readonly" />
<tr>
<td colspan="3"><b> Set URL for the software release </b></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='url_string']</td>
<td>https://lab.nexedi.com/nexedi/slapos/raw/1.0.286/software/ors-amarisoft/software-tdd3700.cfg</td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSORSParameterCommonTemplate/macros/basic_rx_tx_scenario_readonly" />
</tbody>
</table>
</body>
</html>
\ No newline at end of file
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>testSlapOSJSTestParameterEditorORSAmarisoftTD3700gNBEPCSimCardReadOnly</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test Parameter editor (gNB Simcard Simpler Test) </title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr>
<td rowspan="1" colspan="3">Test Parameter editor (gNB Simcard Test)</td>
</tr>
</thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/init_readonly" />
<tr>
<td colspan="3"><b> Set URL for the software release </b></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='url_string']</td>
<td>https://lab.nexedi.com/nexedi/slapos/raw/1.0.286/software/ors-amarisoft/software-tdd3700.cfg</td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSORSParameterCommonTemplate/macros/basic_rx_tx_scenario_readonly" />
</tbody>
</table>
</body>
</html>
\ No newline at end of file
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>testSlapOSJSTestParameterEditorTheiaDefaultReadOnly</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test Parameter editor (Theia Simpler Test) </title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr>
<td rowspan="1" colspan="3">Test Parameter editor (Theia Simpler Test)</td>
</tr>
</thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/init_readonly" />
<tr>
<td colspan="3"><b> Set URL for the software release </b></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='url_string']</td>
<td>https://lab.nexedi.com/nexedi/slapos/raw/1.0.289/software/theia/software.cfg</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@name='parameter_output']</td>
<td tal:content="python: '<?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?><instance><parameter id=&quot;autorun&quot;>running</parameter></instance>'"></td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" />
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/wait_software_type_selection_default" />
<tr>
<td colspan="3"><b>Assert parameter was loaded</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//autorun" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//autorun" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//autorun" and contains(@class, "readonly")]</td>
<td>running</td>
</tr>
</tbody>
</table>
</body>
</html>
\ No newline at end of file
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>testSlapOSJSTestParameterEditorXMLParamNotInSchemaReadOnly</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test Parameter editor (XML Serialisation) </title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr>
<td rowspan="1" colspan="3">Test Parameter editor (XML Read Only)</td>
</tr>
</thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/init_readonly" />
<tr>
<td colspan="3"><b> Set URL for the software release </b></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='url_string']</td>
<td>${base_url}/web_site_module/hostingjs/hateoas/sample-software-schema/minimal_xml_demo/software.cfg</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@name='parameter_output']</td>
<td tal:content="python: '<?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?><instance><parameter id=&quot;simple-stringxxx&quot;>this is a simple stringxx</parameter><parameter id=&quot;simple-string-with-enum&quot;>simple string B</parameter><parameter id=&quot;simple-boolean&quot;>true</parameter><parameter id=&quot;simple-string-with-text-area&quot;>this is a simple string on a text area</parameter><parameter id=&quot;simple-integer&quot;>1</parameter><parameter id=&quot;simple-integer-with-enum&quot;>7</parameter><parameter id=&quot;simple-numeric-integer&quot;>2</parameter><parameter id=&quot;simple-numeric-integer-enum&quot;>13</parameter><parameter id=&quot;simple-numeric-float&quot;>2</parameter><parameter id=&quot;simple-numeric-float-enum&quot;>1.25</parameter></instance>'"></td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" />
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/wait_software_type_selection_default" />
<tr>
<td colspan="3"><b> Assert the simple string</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@name="//simple-stringxxx" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//textarea[@name="//simple-stringxxx" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//textarea[@name="//simple-stringxxx" and @readonly="true"]</td>
<td>this is a simple stringxx</td>
</tr>
<tr>
<td colspan="3"><b> Assert the simple string not Present</b></td>
</tr>
<tr>
<td>assertElementNotPresent</td>
<td>//input[@name="//simple-string" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td colspan="3"><b> Assert the string + enum</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-string-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-string-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-string-with-enum" and contains(@class, "readonly")]</td>
<td>simple string B</td>
</tr>
<tr>
<td colspan="3"><b> Assert the boolean</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-boolean" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-boolean" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-boolean" and contains(@class, "readonly")]</td>
<td>true</td>
</tr>
<tr>
<td colspan="3"><b> Assert the String on Text area</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@name="//simple-string-with-text-area" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//textarea[@name="//simple-string-with-text-area" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//textarea[@name="//simple-string-with-text-area" and @readonly="true"]</td>
<td>this is a simple string on a text area</td>
</tr>
<tr>
<td colspan="3"><b> Assert the simple integer</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-integer" and @type="number" and @readonly="true"]</td>
<td>1</td>
</tr>
<tr>
<td colspan="3"><b> Assert the integer + enum</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-integer-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-integer-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-integer-with-enum" and contains(@class, "readonly")]</td>
<td>7</td>
</tr>
<tr>
<td colspan="3"><b> Assert the simple numeric (integer)</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-numeric-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-numeric-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-numeric-integer" and @type="number" and @readonly="true"]</td>
<td>2</td>
</tr>
<tr>
<td colspan="3"><b> Assert the numeric integer + enum</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-numeric-integer-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-numeric-integer-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-numeric-integer-enum" and contains(@class, "readonly")]</td>
<td>13</td>
</tr>
<tr>
<td colspan="3"><b> Assert the simple numeric (float)</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-numeric-float" and @type="number" and @step="any" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-numeric-float" and @type="number"and @step="any" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-numeric-float" and @type="number"and @step="any" and @readonly="true"]</td>
<td>2</td>
</tr>
<tr>
<td colspan="3"><b> Assert the numeric float + enum</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-numeric-float-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-numeric-float-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-numeric-float-enum" and contains(@class, "readonly")]</td>
<td>1.25</td>
</tr>
</tbody>
</table>
</body>
</html>
\ No newline at end of file
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>testSlapOSJSTestParameterEditorXMLReadOnly</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<html xmlns:tal="http://xml.zope.org/namespaces/tal" xmlns:metal="http://xml.zope.org/namespaces/metal">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Test Parameter editor (XML Serialisation) </title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr>
<td rowspan="1" colspan="3">Test Parameter editor (XML Read Only)</td>
</tr>
</thead>
<tbody>
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/init_readonly" />
<tr>
<td colspan="3"><b> Set URL for the software release </b></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='url_string']</td>
<td>${base_url}/web_site_module/hostingjs/hateoas/sample-software-schema/minimal_xml_demo/software.cfg</td>
</tr>
<tr>
<td>type</td>
<td>//textarea[@name='parameter_output']</td>
<td tal:content="python: '<?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?><instance><parameter id=&quot;simple-string&quot;>this is a simple string</parameter><parameter id=&quot;simple-string-with-enum&quot;>simple string B</parameter><parameter id=&quot;simple-boolean&quot;>true</parameter><parameter id=&quot;simple-string-with-text-area&quot;>this is a simple string on a text area</parameter><parameter id=&quot;simple-integer&quot;>1</parameter><parameter id=&quot;simple-integer-with-enum&quot;>7</parameter><parameter id=&quot;simple-numeric-integer&quot;>2</parameter><parameter id=&quot;simple-numeric-integer-enum&quot;>13</parameter><parameter id=&quot;simple-numeric-float&quot;>2</parameter><parameter id=&quot;simple-numeric-float-enum&quot;>1.25</parameter></instance>'"></td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" />
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/wait_software_type_selection_default" />
<tr>
<td colspan="3"><b> Fill the simple string</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-string" and @type="text" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-string" and @type="text" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-string" and @type="text" and @readonly="true"]</td>
<td>this is a simple string</td>
</tr>
<tr>
<td colspan="3"><b> Fill the string + enum</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-string-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-string-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-string-with-enum" and contains(@class, "readonly")]</td>
<td>simple string B</td>
</tr>
<tr>
<td colspan="3"><b> Fill the boolean</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-boolean" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-boolean" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-boolean" and contains(@class, "readonly")]</td>
<td>true</td>
</tr>
<tr>
<td colspan="3"><b> Fill the String on Text area</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@name="//simple-string-with-text-area" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//textarea[@name="//simple-string-with-text-area" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//textarea[@name="//simple-string-with-text-area" and @readonly="true"]</td>
<td>this is a simple string on a text area</td>
</tr>
<tr>
<td colspan="3"><b> Fill the simple integer</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-integer" and @type="number" and @readonly="true"]</td>
<td>1</td>
</tr>
<tr>
<td colspan="3"><b> Fill the integer + enum</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-integer-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-integer-with-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-integer-with-enum" and contains(@class, "readonly")]</td>
<td>7</td>
</tr>
<tr>
<td colspan="3"><b> Fill the simple numeric (integer)</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-numeric-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-numeric-integer" and @type="number" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-numeric-integer" and @type="number" and @readonly="true"]</td>
<td>2</td>
</tr>
<tr>
<td colspan="3"><b> Fill the numeric integer + enum</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-numeric-integer-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-numeric-integer-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-numeric-integer-enum" and contains(@class, "readonly")]</td>
<td>13</td>
</tr>
<tr>
<td colspan="3"><b> Fill the simple numeric (float)</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//simple-numeric-float" and @type="number" and @step="any" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//simple-numeric-float" and @type="number"and @step="any" and @readonly="true"]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//input[@name="//simple-numeric-float" and @type="number"and @step="any" and @readonly="true"]</td>
<td>2</td>
</tr>
<tr>
<td colspan="3"><b> Fill the numeric float + enum</b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//select[@name="//simple-numeric-float-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//select[@name="//simple-numeric-float-enum" and contains(@class, "readonly")]</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//select[@name="//simple-numeric-float-enum" and contains(@class, "readonly")]</td>
<td>1.25</td>
</tr>
</tbody>
</table>
</body>
</html>
\ No newline at end of file
......@@ -702,6 +702,7 @@
<td></td>
</tr>
</tal:block>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_content_loaded" />
<tal:block tal:define="notification_configuration python: {'class': 'success',
'text': delete_configuration['notification_text']}">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_notification" />
......
<tal:block xmlns:tal="http://xml.zope.org/namespaces/tal"
xmlns:metal="http://xml.zope.org/namespaces/metal">
<tal:block metal:define-macro="basic_rx_tx_scenario">
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/wait_software_type_selection" />
<tr>
......@@ -27,36 +28,13 @@
<tr>
<td colspan="3"><b> Fill RX/TX </b></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//tx_gain" and @type="number"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//tx_gain" and @type="number"]</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name="//tx_gain" and @type="number"]</td>
<td>78.0</td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//input[@name="//rx_gain" and @type="number"]</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name="//rx_gain" and @type="number"]</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name="//rx_gain" and @type="number"]</td>
<td>78.0</td>
</tr>
<tal:block tal:define="name python: '//tx_gain'; value python: '78.0'">
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/input_number" />
</tal:block>
<tal:block tal:define="name python: '//rx_gain'; value python: '78.0'">
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/input_number" />
</tal:block>
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/click_proceed_and_wait_for_hash" />
<tr>
<td>waitForTextPresent</td>
......@@ -186,8 +164,6 @@
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/input_text" />
</tal:block>
<tal:block tal:define="name python:'//imsi'; value python: 'some value'">
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/input_text" />
</tal:block>
......@@ -230,4 +206,129 @@
</tal:block>
<tal:block metal:define-macro="basic_rx_tx_scenario_readonly">
<tr>
<td>type</td>
<td>//textarea[@name='parameter_output']</td>
<td tal:content="python: '<?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?><instance><parameter id=&quot;_&quot;>{&quot;tx_gain&quot;: 78,&quot;rx_gain&quot;: 78}</parameter></instance>'"></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='software_type']</td>
<td tal:content="python: 'enb'"></td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" />
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/wait_software_type_selection" />
<tr>
<td>waitForElementPresent</td>
<td>//div[contains(@data-gadget-url,
'gadget_erp5_page_slap_parameter_form.html')]//select[@name="software_type"]//option[text()="eNB"]
</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//div[contains(@data-gadget-url,
'gadget_erp5_page_slap_parameter_form.html')]//select[@name="software_type"]//option[text()="eNB"]
</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//div[contains(@data-gadget-url,
'gadget_erp5_page_slap_parameter_form.html')]//select[@name="software_type"]
</td>
<td>enb</td>
</tr>
<tr>
<td colspan="3"><b> Fill RX/TX </b></td>
</tr>
<tal:block tal:define="name python: '//tx_gain'; value python: '78'">
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/assert_readonly_input_number" />
</tal:block>
<tal:block tal:define="name python: '//rx_gain'; value python: '78'">
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/assert_readonly_input_number" />
</tal:block>
</tal:block>
<tal:block metal:define-macro="basic_gnb_sim_card_scenario_readonly">
<tr>
<td>type</td>
<td>//textarea[@name='parameter_output']</td>
<td tal:content="python: '<?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?><instance><parameter id=&quot;_&quot;>{&quot;sim_algo&quot;: &quot;some value&quot;,&quot;imsi&quot;: &quot;some value&quot;,&quot;opc&quot;: &quot;some value&quot;,&quot;amf&quot;: &quot;some value&quot;,&quot;sqn&quot;: &quot;some value&quot;,&quot;k&quot;: &quot;some value&quot;,&quot;impu&quot;: &quot;some value&quot;,&quot;impi&quot;: &quot;some value&quot;}</parameter></instance>'"></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='software_type']</td>
<td tal:content="python: 'gnb-epc'"></td>
</tr>
<tr>
<td>type</td>
<td>//input[@name='shared']</td>
<td tal:content="python: 'yes'"></td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" />
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/wait_software_type_selection" />
<tr>
<td>waitForElementPresent</td>
<td>//div[contains(@data-gadget-url,
'gadget_erp5_page_slap_parameter_form.html')]//select[@name="software_type"]//option[text()="gNB-EPC Sim Card"]
</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//div[contains(@data-gadget-url,
'gadget_erp5_page_slap_parameter_form.html')]//select[@name="software_type"]//option[text()="gNB-EPC Sim Card"]
</td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td>//div[contains(@data-gadget-url,
'gadget_erp5_page_slap_parameter_form.html')]//select[@name="software_type"]
</td>
<td>gnb-epc</td>
</tr>
<tal:block tal:define="name python: '//sim_algo'; value python: 'some value'">
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/assert_readonly_input_text" />
</tal:block>
<tal:block tal:define="name python:'//imsi'; value python: 'some value'">
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/assert_readonly_input_text" />
</tal:block>
<tal:block tal:define="name python:'//opc'; value python: 'some value'">
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/assert_readonly_input_text" />
</tal:block>
<tal:block tal:define="name python:'//amf'; value python: 'some value'">
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/assert_readonly_input_text" />
</tal:block>
<tal:block tal:define="name python:'//sqn'; value python: 'some value'">
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/assert_readonly_input_text" />
</tal:block>
<tal:block tal:define="name python:'//k'; value python: 'some value'">
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/assert_readonly_input_text" />
</tal:block>
<tal:block tal:define="name python:'//impu'; value python: 'some value'">
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/assert_readonly_input_text" />
</tal:block>
<tal:block tal:define="name python:'//impi'; value python: 'some value'">
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/assert_readonly_input_text" />
</tal:block>
</tal:block>
</tal:block>
\ No newline at end of file
......@@ -20,7 +20,6 @@
</tr>
</tal:block>
<tal:block metal:define-macro="wait_software_type_selection_default">
<tal:block metal:use-macro="here/Zuite_SlapOSParameterCommonTemplate/macros/wait_software_type_selection" />
<tr>
......@@ -68,7 +67,6 @@
<tal:block metal:define-macro="init">
<tal:block metal:use-macro="here/Zuite_CommonTemplate/macros/init" />
<tal:block metal:use-macro="here/Zuite_CommonTemplate/macros/wait_for_activities" />
<tr>
<td>open</td>
<td>${base_url}/web_site_module/hostingjs/#/?page=slap_test_parameter_form</td>
......@@ -87,6 +85,36 @@
</tr>
</tal:block>
<tal:block metal:define-macro="init_readonly">
<tal:block metal:use-macro="here/Zuite_CommonTemplate/macros/init" />
<tr>
<td>open</td>
<td>${base_url}/web_site_module/hostingjs/#/?page=slap_test_readonly_parameter_form</td>
<td></td>
</tr>
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/wait_for_app_loaded" />
<tr>
<td>waitForElementPresent</td>
<td>//input[@name='url_string']</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//input[@name='url_string']</td>
<td></td>
</tr>
<tr>
<td>waitForElementPresent</td>
<td>//textarea[@name='parameter_output']</td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td>//textarea[@name='parameter_output']</td>
<td></td>
</tr>
</tal:block>
<tal:block metal:define-macro="click_proceed_and_wait_for_hash">
<tal:block metal:use-macro="here/Zuite_SlapOSCommonTemplate/macros/click_proceed" />
<tr>
......@@ -180,4 +208,60 @@
<td tal:content="python: value"></td>
</tr>
</tal:block>
<tal:block metal:define-macro="assert_readonly_input_text">
<tr>
<td>waitForElementPresent</td>
<td tal:content="python: '//input[@name=\'%s\' and @type=\'text\' and @readonly=\'true\']' % name"></td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td tal:content="python: '//input[@name=\'%s\' and @type=\'text\' and @readonly=\'true\']' % name"></td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td tal:content="python: '//input[@name=\'%s\' and @type=\'text\' and @readonly=\'true\']' % name"></td>
<td tal:content="python: value"></td>
</tr>
</tal:block>
<tal:block metal:define-macro="input_number">
<tr>
<td>waitForElementPresent</td>
<td tal:content="python: '//input[@name=\'%s\' and @type=\'number\']' % name"></td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td tal:content="python: '//input[@name=\'%s\' and @type=\'number\']' % name"></td>
<td></td>
</tr>
<tr>
<td>type</td>
<td tal:content="python: '//input[@name=\'%s\' and @type=\'number\']' % name"></td>
<td tal:content="python: value"></td>
</tr>
</tal:block>
<tal:block metal:define-macro="assert_readonly_input_number">
<tr>
<td>waitForElementPresent</td>
<td tal:content="python: '//input[@name=\'%s\' and @type=\'number\' and @readonly=\'true\']' % name"></td>
<td></td>
</tr>
<tr>
<td>assertElementPresent</td>
<td tal:content="python: '//input[@name=\'%s\' and @type=\'number\' and @readonly=\'true\']' % name"></td>
<td></td>
</tr>
<tr>
<td>assertValue</td>
<td tal:content="python: '//input[@name=\'%s\' and @type=\'number\' and @readonly=\'true\']' % name"></td>
<td tal:content="python: value"></td>
</tr>
</tal:block>
</tal:block>
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment