Commit 3ebbab30 authored by Romain Courteaud's avatar Romain Courteaud

[erp5_web_renderjs_ui] Reduce number of RSVP.all calls

parent 2c337082
...@@ -506,22 +506,18 @@ ...@@ -506,22 +506,18 @@
} }
} }
} }
promise_list.push.apply(promise_list, url_promise_list);
return new RSVP.Queue() return new RSVP.Queue()
.push(function () { .push(function () {
return RSVP.all([ return RSVP.all(promise_list);
RSVP.all(promise_list),
RSVP.all(url_promise_list)
]);
}) })
.push(function (result_list) { .push(function (line_link_list) {
var row_list = [], var row_list = [],
value, value,
cell_list, cell_list,
url_value, url_value,
index = 0, index = 0,
listbox_tbody_template, listbox_tbody_template,
line_link_list = result_list[0],
url_column_list = result_list[1],
setNonEditable = function (cell) {cell.editable = false; }; setNonEditable = function (cell) {cell.editable = false; };
// reset list of UIDs of editable sub-documents // reset list of UIDs of editable sub-documents
gadget.props.listbox_uid_dict = { gadget.props.listbox_uid_dict = {
...@@ -539,7 +535,7 @@ ...@@ -539,7 +535,7 @@
// get url value // get url value
if (value.url_value) { if (value.url_value) {
if (value.url_value.command) { if (value.url_value.command) {
url_value = url_column_list[index]; url_value = line_link_list[counter + index];
index += 1; index += 1;
} else { } else {
url_value = false; url_value = false;
......
...@@ -236,7 +236,7 @@ ...@@ -236,7 +236,7 @@
</item> </item>
<item> <item>
<key> <string>serial</string> </key> <key> <string>serial</string> </key>
<value> <string>967.34796.62500.30566</string> </value> <value> <string>967.34816.49816.58760</string> </value>
</item> </item>
<item> <item>
<key> <string>state</string> </key> <key> <string>state</string> </key>
...@@ -254,7 +254,7 @@ ...@@ -254,7 +254,7 @@
</tuple> </tuple>
<state> <state>
<tuple> <tuple>
<float>1526291513.71</float> <float>1526292640.95</float>
<string>UTC</string> <string>UTC</string>
</tuple> </tuple>
</state> </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