Commit 30dd982c authored by Rafael Monnerat's avatar Rafael Monnerat

slapos_jio: Allow use restricted mode when request a specific portal type'

parent 34bc91ca
......@@ -202,6 +202,7 @@
</item>
</dictionary>
</list>
<none/>
</tuple>
</pickle>
</record>
......@@ -261,6 +262,7 @@
</item>
</dictionary>
</list>
<none/>
</tuple>
</pickle>
</record>
......@@ -318,6 +320,7 @@
</item>
</dictionary>
</list>
<none/>
</tuple>
</pickle>
</record>
......
......@@ -82,6 +82,15 @@
'restricted_softwaretype': false
}
};
if (options.software_type) {
parameter_dict["parameter"]['restricted_softwaretype'] = true;
parameter_dict["parameter"]['softwaretype'] = options.software_type;
}
if (options.shared) {
parameter_dict["parameter"]['shared'] = true;
}
return result[0].render({
erp5_document: {
"_embedded": {"_view": {
......@@ -129,9 +138,20 @@
"required": 0,
"editable": 1,
"key": "computer_guid",
"hidden": 0,
"hidden": options.sla_xml !== undefined ? 1 : 0,
"type": "ListField"
},
"your_sla_xml": {
"description": "The name of a document in ERP5",
"title": "SLA",
"default": options.sla_xml,
"css_class": "",
"required": 0,
"editable": 0,
"key": "sla_xml",
"hidden": options.sla_xml !== undefined ? 0 : 1,
"type": "StringField"
},
"my_relative_url": {
"description": "",
"title": "Parent Relative Url",
......@@ -155,7 +175,7 @@
group_list: [[
"center",
[["my_url_string"], ["your_title"], ["your_text_content"],
["your_computer_guid"], ["my_portal_type"], ["my_relative_url"]]
["your_computer_guid"],["your_sla_xml"], ["my_portal_type"], ["my_relative_url"]]
]]
}
})
......
......@@ -241,6 +241,7 @@
</item>
</dictionary>
</list>
<none/>
</tuple>
</pickle>
</record>
......@@ -273,7 +274,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>976.9867.41515.40260</string> </value>
<value> <string>981.35383.15103.35259</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -291,7 +292,7 @@
</tuple>
<state>
<tuple>
<float>1561394238.54</float>
<float>1580513887.37</float>
<string>UTC</string>
</tuple>
</state>
......@@ -300,6 +301,7 @@
</item>
</dictionary>
</list>
<none/>
</tuple>
</pickle>
</record>
......@@ -357,6 +359,7 @@
</item>
</dictionary>
</list>
<none/>
</tuple>
</pickle>
</record>
......
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