summaryrefslogtreecommitdiff
path: root/addons
diff options
context:
space:
mode:
authorGéry Debongnie <ged@odoo.com>2018-05-28 14:18:43 +0200
committerGéry Debongnie <ged@odoo.com>2018-05-28 14:33:07 +0200
commitd9c035ae428cb8f57e2bb570aa23c41d6ae00bd4 (patch)
tree852770d25425f0551811bd2fd519d5453a7ea941 /addons
parentaa54457fe87f53d4de5879f61ede71e0cfbe8a35 (diff)
[FIX] web: do not hide button in pdf viewer in some cases
The pdf viewer uses an external library to display a pdf file. This library displays a few controls, such as a 'Download' button. However, this button is sometimes displayed in the top bar, sometimes in the top right dropdown menu (depending on the size of the widget). For some unknown reason, the pdf viewer widget disabled the download button. But this was inconsistent: the download button was only hidden when it was in the tob bar, and not in the dropdown menu. With this commit, we simply remove this behaviour.
Diffstat (limited to 'addons')
-rw-r--r--addons/web/static/src/js/fields/basic_fields.js3
1 files changed, 0 insertions, 3 deletions
diff --git a/addons/web/static/src/js/fields/basic_fields.js b/addons/web/static/src/js/fields/basic_fields.js
index c2133e3b707..10057d44984 100644
--- a/addons/web/static/src/js/fields/basic_fields.js
+++ b/addons/web/static/src/js/fields/basic_fields.js
@@ -1305,9 +1305,6 @@ var FieldPdfViewer = FieldBinaryFile.extend({
* @param {DOMElement} iframe
*/
_disableButtons: function (iframe) {
- if (this.mode === 'readonly') {
- $(iframe).contents().find('button#download').hide();
- }
$(iframe).contents().find('button#openFile').hide();
},
/**