Commit 3ff6cfe3 authored by Jérome Perrin's avatar Jérome Perrin

fieldset: use startService

parent 499efe61
...@@ -96,7 +96,18 @@ ...@@ -96,7 +96,18 @@
}); });
return queue; return queue;
}) })
.declareMethod("startService", function () {
var i, gadget=this,
promise_list = [];
for (i = 0; i < gadget.props.field_gadget_list.length; i += 1) {
if (gadget.props.field_gadget_list[i].startService) {
promise_list.push(
gadget.props.field_gadget_list[i].startService()
);
}
}
return RSVP.all(promise_list);
})
// getContent of all subfields // getContent of all subfields
.declareMethod("getContent", function () { .declareMethod("getContent", function () {
var i, promise_list = [], gadget = this; var i, promise_list = [], gadget = this;
......
...@@ -548,6 +548,10 @@ ...@@ -548,6 +548,10 @@
edit_popup.popup('open'); edit_popup.popup('open');
return fieldset_gadget[0]; return fieldset_gadget[0];
}) })
.push(function (fieldset_gadget){
fieldset_gadget.startService();
return fieldset_gadget;
})
.push(function (fieldset_gadget) { .push(function (fieldset_gadget) {
// Expose the dialog handling promise so that we can wait for it in // Expose the dialog handling promise so that we can wait for it in
// test. // test.
...@@ -649,6 +653,10 @@ ...@@ -649,6 +653,10 @@
node_edit_popup.popup('open'); node_edit_popup.popup('open');
return fieldset_gadget[0]; return fieldset_gadget[0];
}) })
.push(function (fieldset_gadget){
fieldset_gadget.startService();
return fieldset_gadget;
})
.push(function (fieldset_gadget) { .push(function (fieldset_gadget) {
// Expose the dialog handling promise so that we can wait for it in // Expose the dialog handling promise so that we can wait for it in
// test. // test.
......
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