diff options
| author | Christophe Simonis <chs@odoo.com> | 2017-10-20 19:27:04 +0200 |
|---|---|---|
| committer | Christophe Simonis <chs@odoo.com> | 2017-10-20 19:27:04 +0200 |
| commit | 10128fa7e8c743e9c838743204fb8116bcdeefd6 (patch) | |
| tree | 7ffbf2540d01f994886369bd551ea59f7e446040 /addons/web/static/src/js/report | |
| parent | 68bef91d733aaf8f08df5f3daf0821a4c59d4d87 (diff) | |
| parent | dc2a6c6cd2a281b7d9e5d33d8e37d2f6b15d7e78 (diff) | |
[MERGE] forward port branch saas-16 up to dc2a6c6cd2a
Diffstat (limited to 'addons/web/static/src/js/report')
| -rw-r--r-- | addons/web/static/src/js/report/qwebactionmanager.js | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/addons/web/static/src/js/report/qwebactionmanager.js b/addons/web/static/src/js/report/qwebactionmanager.js index 3c8fee859e3..cc875882ce2 100644 --- a/addons/web/static/src/js/report/qwebactionmanager.js +++ b/addons/web/static/src/js/report/qwebactionmanager.js @@ -21,7 +21,7 @@ var WKHTMLTOPDF_MESSAGES = { }; var trigger_download = function (session, response, c, action, options) { - session.get_file({ + return session.get_file({ url: '/report/download', data: {data: JSON.stringify(response)}, complete: framework.unblockUI, @@ -107,7 +107,10 @@ ActionManager.include({ report_urls['qweb-pdf'], action.report_type, //The 'root' report is considered the maine one, so we use its type for all the others. ]; - trigger_download(self.getSession(), response, c, current_action, options); + var success = trigger_download(self.getSession(), response, c, current_action, options); + if (!success) { + self.do_warn(_t('Warning'), _t('A popup window with your report was blocked. You may need to change your browser settings to allow popup windows for this page.'), true); + } treated_actions.push(current_action); current_action = current_action.next_report_to_generate; |
