Commit 8b40ecdf by Romain Courteaud

[erp5_web_renderjs_ui] Worklist: simplify code

1 parent 19937c97
......@@ -15,25 +15,8 @@
gadget_klass
/////////////////////////////////////////////////////////////////
// ready
/////////////////////////////////////////////////////////////////
// Init local properties
.ready(function (g) {
g.props = {};
})
// Assign the element to a variable
.ready(function (g) {
return g.getElement()
.push(function (element) {
g.props.element = element;
});
})
/////////////////////////////////////////////////////////////////
// Acquired methods
/////////////////////////////////////////////////////////////////
.declareAcquiredMethod("jio_allDocs", "jio_allDocs")
.declareAcquiredMethod("jio_getAttachment", "jio_getAttachment")
.declareAcquiredMethod("translateHtml", "translateHtml")
.declareAcquiredMethod("updateHeader", "updateHeader")
......@@ -101,7 +84,7 @@
})
.push(function (my_translated_html) {
gadget.props.element.querySelector('.document_list').innerHTML =
gadget.element.querySelector('.document_list').innerHTML =
my_translated_html;
});
});
......
......@@ -230,7 +230,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>947.21012.16488.34935</string> </value>
<value> <string>954.47218.14887.48486</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -248,7 +248,7 @@
</tuple>
<state>
<tuple>
<float>1448376284.81</float>
<float>1476956693.83</float>
<string>UTC</string>
</tuple>
</state>
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!