the mail.action_mail_redirect client action that redirects to the correct
form view, like the link used in notification emails.
bzr revid: tde@openerp.com-
20140213151638-ev2va4y3tmm9m7i8
},
on_record_clicked: function (event) {
- event.stopPropagation();
var state = {
'model': this.model,
'id': this.res_id,
'title': this.record_name
};
session.webclient.action_manager.do_push_state(state);
- this.do_action({
- res_model: state.model,
- res_id: state.id,
- type: 'ir.actions.act_window',
- views: [[false, 'form']]
- });
- return false;
},
/* Call the on_compose_message on the thread of this message. */
<!-- message itself -->
<div class="oe_msg_content">
<h1 t-if="(widget.show_record_name or widget.subject) and !widget.thread_level" class="oe_msg_title">
- <a t-if="widget.options.show_link and widget.show_record_name" class="oe_mail_action_model" t-attf-href="#model=#{widget.model}&id=#{widget.res_id}">
+ <a t-if="widget.options.show_link and widget.show_record_name" class="oe_mail_action_model"
+ t-attf-href="#action=mail.action_mail_redirect&model=#{widget.model}&res_id=#{widget.res_id}">
<t t-esc="widget.record_name"/>
</a>
<span t-if="!widget.options.show_link and widget.show_record_name"><t t-esc="widget.record_name"/></span>