From 5018b01dc7e0e5f2c2198367f13ec41b1ed402c7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Theys?= Date: Mon, 10 Feb 2020 12:38:52 +0000 Subject: [IMP] mail, test_mail, hr_holidays: remove obsolete out of office MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The customizable "out of office" text was removed from the editable views as part of task-2053585, but some places in the code were still using it, even though it was never set anymore. This commit removes the obsolete code. Part of task-2171864 closes odoo/odoo#44968 Signed-off-by: Alexandre Kühn (aku) --- addons/mail/static/src/js/models/threads/dm_chat.js | 13 ------------- 1 file changed, 13 deletions(-) (limited to 'addons/mail/static/src/js/models/threads/dm_chat.js') diff --git a/addons/mail/static/src/js/models/threads/dm_chat.js b/addons/mail/static/src/js/models/threads/dm_chat.js index 6b56cd2c80d..b811b5a5cd5 100644 --- a/addons/mail/static/src/js/models/threads/dm_chat.js +++ b/addons/mail/static/src/js/models/threads/dm_chat.js @@ -23,7 +23,6 @@ var DMChat = TwoUserChannel.extend(ChannelSeenMixin, { * @param {integer} params.data.direct_partner[0].id * @param {string} params.data.direct_partner[0].im_status * @param {string} params.data.direct_partner[0].name - * @param {string} [params.data.direct_partner[0].out_of_office_message] * @param {string} [params.data.direct_partner[0].out_of_office_date_end] */ init: function (params) { @@ -34,7 +33,6 @@ var DMChat = TwoUserChannel.extend(ChannelSeenMixin, { this._directPartnerID = data.direct_partner[0].id; this._name = data.custom_channel_name || data.direct_partner[0].name; - this._outOfOfficeMessage = data.direct_partner[0].out_of_office_message; this._outOfOfficeDateEnd = data.direct_partner[0].out_of_office_date_end; this._type = 'dm_chat'; @@ -77,15 +75,6 @@ var DMChat = TwoUserChannel.extend(ChannelSeenMixin, { var formattedDate = date.toLocaleDateString(window.navigator.language, options); return _.str.sprintf(_t("Out of office until %s"), formattedDate); }, - /** - * Get the out of office message of the thread - * - * @override {mail.model.AbstractThread} - * @returns {string} - */ - getOutOfOfficeMessage: function () { - return this._outOfOfficeMessage; - }, /** * @override */ @@ -104,11 +93,9 @@ var DMChat = TwoUserChannel.extend(ChannelSeenMixin, { /** * @param {Object} data - * @param {string} data.outOfOfficeMessage * @param {string} data.outOfOfficeDateEnd */ updateOutOfOfficeInfo: function (data) { - this._outOfOfficeMessage = data.outOfOfficeMessage; this._outOfOfficeDateEnd = data.outOfOfficeDateEnd; this.call('mail_service', 'getMailBus').trigger('updated_out_of_office', { threadID: this.getID(), -- cgit v1.2.3