Commit ad42cf34 authored by Gabriel Monnerat's avatar Gabriel Monnerat

erp5_web_renderjs_ui: propagate parameter to enable graphic

parent c8120676
......@@ -34,7 +34,8 @@
extended_search: (is_first_bottom_listbox && (form_definition.extended_search)), // searchfield specific
field_type: rendered_document[field_name].type,
label: ((group_name !== "bottom") && (rendered_document[field_name].title.length > 0)), // no label for bottom group and field without title
field_json: rendered_document[field_name] // pass
field_json: rendered_document[field_name], // pass
enable_graphic: modification_dict.enable_graphic
};
// XXX: what is the purpose of this?
......@@ -190,6 +191,7 @@
return this.changeState({
erp5_document: options.erp5_document,
form_definition: options.form_definition,
enable_graphic: options.enable_graphic,
jio_key: options.jio_key,
hash: hash,
view: options.view,
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>991.26405.47.57924</string> </value>
<value> <string>997.28933.33599.15445</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1618519262.64</float>
<float>1641917242.86</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -581,6 +581,7 @@
show_clipboard_action: false,
// graphic
enable_graphic: options.enable_graphic,
graphic_type: graphic_type
});
});
......@@ -946,7 +947,7 @@
loading_element_classList.add.apply(loading_element_classList, loading_class_list);
// remove pagination information
loading_element.textContent = '';
tbody_classList.add(disabled_class);
tbody_classList.add(disabled_class);
}
return gadget.fetchLineContent(false);
});
......@@ -1196,7 +1197,7 @@
})
);
}
if (!gadget.state.extended_search) {
if (!gadget.state.extended_search && gadget.state.enable_graphic) {
domsugar(gadget.element.querySelector(".graphic_section"), [
domsugar("select", {
"name": "GraphicSelect",
......@@ -1208,6 +1209,7 @@
});
});
if (!gadget.state.extended_search &&
gadget.state.enable_graphic &&
gadget.state.graphic_type &&
gadget.state.graphic_type !== "") {
result_queue
......
......@@ -240,7 +240,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>997.21666.38260.2918</string> </value>
<value> <string>997.28008.46664.51182</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -258,7 +258,7 @@
</tuple>
<state>
<tuple>
<float>1641490303.25</float>
<float>1641918364.42</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -135,7 +135,7 @@
if (form_gadget.state.extended_search) {
form_options.form_definition.extended_search = form_gadget.state.extended_search;
}
form_options.enable_graphic = true;
return erp5_form.render(form_options);
})
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>979.58033.54588.53418</string> </value>
<value> <string>997.28531.29725.31266</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1574153832.0</float>
<float>1641893404.13</float>
<string>UTC</string>
</tuple>
</state>
......
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