Browse Source
Overwrite web error message to hide traceback from user
Overwrite web error message to hide traceback from user
Inject sentry_activated into web session Overwrite CrashManager.error QWeb template Provide translations Signed-off-by: Sandy Carter <sandy.carter@savoirfairelinux.com>pull/44/head
Sandy Carter
10 years ago
5 changed files with 106 additions and 2 deletions
-
13sentry_logger/__init__.py
-
8sentry_logger/__openerp__.py
-
32sentry_logger/i18n/fr.po
-
30sentry_logger/i18n/sentry_logger.pot
-
25sentry_logger/static/src/xml/base.xml
@ -0,0 +1,32 @@ |
|||
# Translation of OpenERP Server. |
|||
# This file contains the translation of the following modules: |
|||
# * sentry_logger |
|||
# |
|||
msgid "" |
|||
msgstr "" |
|||
"Project-Id-Version: OpenERP Server 7.0\n" |
|||
"Report-Msgid-Bugs-To: \n" |
|||
"POT-Creation-Date: 2014-10-15 22:09+0000\n" |
|||
"PO-Revision-Date: 2014-10-15 18:11-0500\n" |
|||
"Last-Translator: Sandy Carter <sandy.carter@savoirfairelinux.com>\n" |
|||
"Language-Team: \n" |
|||
"MIME-Version: 1.0\n" |
|||
"Content-Type: text/plain; charset=UTF-8\n" |
|||
"Content-Transfer-Encoding: 8bit\n" |
|||
"Plural-Forms: \n" |
|||
"Language: fr\n" |
|||
"X-Generator: Poedit 1.6.9\n" |
|||
|
|||
#. module: sentry_logger |
|||
#. openerp-web |
|||
#: code:addons/sentry_logger/static/src/xml/base.xml:8 |
|||
#, python-format |
|||
msgid "A detailed report has been sent to the technical support team." |
|||
msgstr "Un rapport a été envoyé à l'équipe technique." |
|||
|
|||
#. module: sentry_logger |
|||
#. openerp-web |
|||
#: code:addons/sentry_logger/static/src/xml/base.xml:7 |
|||
#, python-format |
|||
msgid "An internal OpenERP error has occurred." |
|||
msgstr "Une erreur interne à OpenERP est survenue." |
@ -0,0 +1,30 @@ |
|||
# Translation of OpenERP Server. |
|||
# This file contains the translation of the following modules: |
|||
# * sentry_logger |
|||
# |
|||
msgid "" |
|||
msgstr "" |
|||
"Project-Id-Version: OpenERP Server 7.0\n" |
|||
"Report-Msgid-Bugs-To: \n" |
|||
"POT-Creation-Date: 2014-10-15 22:09+0000\n" |
|||
"PO-Revision-Date: 2014-10-15 22:09+0000\n" |
|||
"Last-Translator: <>\n" |
|||
"Language-Team: \n" |
|||
"MIME-Version: 1.0\n" |
|||
"Content-Type: text/plain; charset=UTF-8\n" |
|||
"Content-Transfer-Encoding: \n" |
|||
"Plural-Forms: \n" |
|||
|
|||
#. module: sentry_logger |
|||
#. openerp-web |
|||
#: code:addons/sentry_logger/static/src/xml/base.xml:8 |
|||
#, python-format |
|||
msgid "A detailed report has been sent to the technical support team." |
|||
msgstr "" |
|||
|
|||
#. module: sentry_logger |
|||
#. openerp-web |
|||
#: code:addons/sentry_logger/static/src/xml/base.xml:7 |
|||
#, python-format |
|||
msgid "An internal OpenERP error has occurred." |
|||
msgstr "" |
@ -0,0 +1,25 @@ |
|||
<?xml version = "1.0" encoding="utf-8"?> |
|||
<templates> |
|||
|
|||
<t t-extend="CrashManager.error"> |
|||
<t t-jquery="div.oe_error_detail" t-operation="replace"> |
|||
|
|||
<!-- Hide traceback from users --> |
|||
<div t-if="session.sentry_activated" class="oe_error_detail"> |
|||
<h2>An internal OpenERP error has occurred.</h2> |
|||
<div class="oe_view_nocontent"> |
|||
A detailed report has been sent to the technical support team. |
|||
</div> |
|||
</div> |
|||
|
|||
<!-- Original error message --> |
|||
<div t-if="!session.sentry_activated" class="oe_error_detail"> |
|||
<pre><t t-esc="error.message"/></pre> |
|||
<hr/> |
|||
<pre><t t-esc="error.data.debug"/></pre> |
|||
</div> |
|||
|
|||
</t> |
|||
</t> |
|||
|
|||
</templates> |
Write
Preview
Loading…
Cancel
Save
Reference in new issue