diff options
| author | Jérome Maes <jem@openerp.com> | 2017-08-11 11:58:49 +0200 |
|---|---|---|
| committer | Jérome Maes <jem@openerp.com> | 2017-08-16 14:56:43 +0200 |
| commit | fe5fa6973cc8ae3dc4d2779ba619b3bf76a2ca7f (patch) | |
| tree | 4a1ed6d7406098004ee717f72f6bdce0b8103538 /addons | |
| parent | f9827cb5b44a02749075f8185f36f143aad6bcce (diff) | |
[IMP] http_routing: use converter defined in the module
Otherwise, the slug part of route can be used only when website is installed.
Diffstat (limited to 'addons')
| -rw-r--r-- | addons/http_routing/models/ir_http.py | 10 | ||||
| -rw-r--r-- | addons/portal/models/mail_message.py | 1 |
2 files changed, 10 insertions, 1 deletions
diff --git a/addons/http_routing/models/ir_http.py b/addons/http_routing/models/ir_http.py index 93015232b54..f9e6959e8d7 100644 --- a/addons/http_routing/models/ir_http.py +++ b/addons/http_routing/models/ir_http.py @@ -179,6 +179,16 @@ class IrHttp(models.AbstractModel): rerouting_limit = 10 @classmethod + def _get_converters(cls): + """ Get the converters list for custom url pattern werkzeug need to + match Rule. This override adds the website ones. + """ + return dict( + super(IrHttp, cls)._get_converters(), + model=ModelConverter, + ) + + @classmethod def _get_languages(cls): return request.env['res.lang'].search([]) diff --git a/addons/portal/models/mail_message.py b/addons/portal/models/mail_message.py index 6a242609d14..4a5d1f804d9 100644 --- a/addons/portal/models/mail_message.py +++ b/addons/portal/models/mail_message.py @@ -13,7 +13,6 @@ class MailMessage(models.Model): 'id', 'body', 'date', 'author_id', 'email_from', # base message fields 'message_type', 'subtype_id', 'subject', # message specific 'model', 'res_id', 'record_name', # document related - 'website_published', ]) @api.multi |
