Commit 5f52ed3a authored by Gabriel Monnerat's avatar Gabriel Monnerat

erp5_web_renderjs_ui: trigger gadgets after change select

parent 64d7d183
......@@ -1168,7 +1168,12 @@
loading_element.textContent = '(' + pagination_message + ')';
})
.push(function () {
var sub_element_list = [];
var sub_element_list = [
domsugar("option", {
"value": "",
"text": " ---------- "
})
];
for (i = 0; i < gadget.state.option_list.length; i += 1) {
sub_element_list.push(
domsugar("option", {
......@@ -1182,7 +1187,11 @@
gadget.element.firstChild
);
});
/*.push(function () {
});
} else if (modification_dict.hasOwnProperty("graphic_type") &&
modification_dict.graphic_type !== "") {
return result_queue
.push(function () {
var div = domsugar("div", {"class": "graphic-section"}),
gadget_list = [],
domain_list = JSON.parse(gadget.state.domain_list_json);
......@@ -1206,8 +1215,8 @@
);
}
return RSVP.all(gadget_list);
})*/
/*.push(function (gadget_list) {
})
.push(function (gadget_list) {
var default_param_list = JSON.parse(gadget.state.column_list_json),
domain_dict = JSON.parse(gadget.state.domain_dict_json),
domain_list = [],
......@@ -1276,10 +1285,8 @@
}
return RSVP.all(queue_list);
}
});*/
});
}
return result_queue;
})
......@@ -1523,10 +1530,14 @@
show_clipboard_action: false
});
}
if (evt.target.type === "select-one") {
// XXX Move it to onEvent > "change" probably
return gadget.changeState({"graphic_type": evt.target.value});
return gadget.changeState({
"graphic_type": evt.target.value
});
}
if ((evt.target.type === 'button') &&
((evt.target.name === 'SelectAction') || (evt.target.name === 'ClipboardAction'))) {
console.log("I am here");
......
......@@ -240,7 +240,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>994.21450.459.32358</string> </value>
<value> <string>994.21596.49508.22784</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -258,7 +258,7 @@
</tuple>
<state>
<tuple>
<float>1629844472.66</float>
<float>1629853271.24</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