diff options
| author | niv-openerp <nicolas.vanhoren@openerp.com> | 2013-01-08 17:41:04 +0100 |
|---|---|---|
| committer | niv-openerp <nicolas.vanhoren@openerp.com> | 2013-01-08 17:41:04 +0100 |
| commit | b8180f4c09995a76e5f1e6ca1ff868a9bdff7d31 (patch) | |
| tree | 4af557714c42be790d61ba48291fa9da7e3f82c7 /addons/web/static/src | |
| parent | c46be224e6f81309bd2a4bd23b97097a5b1c0051 (diff) | |
[FIX] problem when multiple instances of the web client run in tabs and we disconnect from one tab, now displays a better error message
lp bug: https://launchpad.net/bugs/1093671 fixed
bzr revid: nicolas.vanhoren@openerp.com-20130108164104-7wv2yxlrczqmicvb
Diffstat (limited to 'addons/web/static/src')
| -rw-r--r-- | addons/web/static/src/js/chrome.js | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/addons/web/static/src/js/chrome.js b/addons/web/static/src/js/chrome.js index 26d30ea98a2..30a51026684 100644 --- a/addons/web/static/src/js/chrome.js +++ b/addons/web/static/src/js/chrome.js @@ -247,6 +247,11 @@ instance.web.CrashManager = instance.web.Class.extend({ if (!this.active) { return; } + // yes, exception handling is shitty + if (error.code === 300 && error.data && error.data.type == "client_exception" && error.data.debug.match("SessionExpiredException")) { + this.show_warning({type: "Session Expired", data: { fault_code: "Your OpenERP session expired. Please refresh the current web page." }}); + return; + } if (error.data.fault_code) { var split = ("" + error.data.fault_code).split('\n')[0].split(' -- '); if (split.length > 1) { |
