diff options
| author | Aaron Bohy <aab@odoo.com> | 2015-12-02 09:16:16 +0100 |
|---|---|---|
| committer | Aaron Bohy <aab@odoo.com> | 2015-12-03 11:21:47 +0100 |
| commit | 8017a9569cbd648b3ff205c198efb8c5a9530d7d (patch) | |
| tree | 74587eca37d3dbfda9adc81af1d9b3ba5a2d0550 /addons/web_editor/static/src/js/widgets.js | |
| parent | 7bea8412c5a7ac89d1b89ff2ba685d3d99434a5a (diff) | |
[FIX] mail: ondelete cascade on mail_channel_partner relation
The problem occurred when the im_livechat cron 'cron_remove_empty_session'
removed empty livechat channels (a public user clicked on the livechat button,
creating a new channel, but never sent any message in it). The empty channel
was deleted by the cron, but the two records in the mail_channel_partner
relation table (linking the channel with the public user and the livechat
operator) wasn't removed, and the value of their field 'channel_id' was None.
When this happenned, it broke the SQL query of 'channel_search_to_join()', the
RPC call performed when clicking on '+' new to public channels in the client
action, resulting in no result displayed in the dropdown.
With this fix, records in the relation table are automatically deleted when
their corresponding channel or partner is deleted.
Diffstat (limited to 'addons/web_editor/static/src/js/widgets.js')
0 files changed, 0 insertions, 0 deletions
