Commit 29344b84 authored by Xiaowu Zhang's avatar Xiaowu Zhang

erp5_web_renderjs_ui: only show unselect&select on dialog

parent c5a2a785
......@@ -157,8 +157,26 @@
function getListboxClipboardActionList() {
var action_list = ensureArray(this.state.erp5_document._links.action_object_list_action || []),
i,
pt = this.state.form_definition.pt,
result_list = [],
icon;
if (pt === 'form_dialog') {
return this.getTranslationList(['Select All', 'Unselect All'])
.push(function (translation_list) {
return [
{
title: translation_list[0],
icon: 'check-square-o',
action: 'select_all_document_list'
},
{
title: translation_list[1],
icon: 'ban',
action: 'unselect_all_document_list'
}
];
});
}
return this.getTranslationList(['Select All', 'Unselect All', 'Copy'])
.push(function (translation_list) {
result_list = [
......
......@@ -234,7 +234,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>984.64003.17482.44305</string> </value>
<value> <string>984.64066.39037.55261</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>1593681243.48</float>
<float>1593684737.69</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -350,5 +350,6 @@
update_button.disabled = false;
}
});
declareGadgetClassCanHandleListboxClipboardAction(rJS(window));
}(window, rJS, RSVP, calculatePageTitle, domsugar, ensureArray));
\ No newline at end of file
......@@ -228,7 +228,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>981.55111.20815.20787</string> </value>
<value> <string>984.39653.64795.20104</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -246,7 +246,7 @@
</tuple>
<state>
<tuple>
<float>1581696457.29</float>
<float>1593684092.28</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