Skip to content
Snippets Groups Projects
Commit 199af375 authored by Jigar Patel's avatar Jigar Patel
Browse files

[FIX] crm_livechat: convert leads from livechat discussions

Fixes a7b89070

opw-2078313

X-Original-Commit: 8ab09cad
parent a3dd3d92
No related branches found
No related tags found
No related merge requests found
......@@ -2,7 +2,7 @@
# Part of Odoo. See LICENSE file for full copyright and licensing details.
from odoo import models, _
from odoo.tools import html2plaintext
from odoo.tools import html2plaintext, html_escape
class MailChannel(models.Model):
......@@ -22,7 +22,7 @@ class MailChannel(models.Model):
msg = self._define_command_lead()['help']
else:
lead = self._convert_visitor_to_lead(partner, channel_partners, key)
msg = _('Created a new lead: <a href="#" data-oe-id="%s" data-oe-model="crm.lead">%s</a>') % (lead.id, lead.name)
msg = _('Created a new lead: <a href="#" data-oe-id="%s" data-oe-model="crm.lead">%s</a>') % (lead.id, html_escape(lead.name))
self._send_transient_message(partner, msg)
def _convert_visitor_to_lead(self, partner, channel_partners, key):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment