diff --git a/odoo_advanced_chatter/__manifest__.py b/odoo_advanced_chatter/__manifest__.py
index 88ac908e2..d7b9c1ef6 100644
--- a/odoo_advanced_chatter/__manifest__.py
+++ b/odoo_advanced_chatter/__manifest__.py
@@ -21,7 +21,7 @@
#############################################################################
{
'name': 'Odoo Advanced Chatter',
- 'version': '17.0.2.0.0',
+ 'version': '17.0.2.0.1',
'category': 'Discuss',
'summary': 'Schedule Log note and Send Message in Chatter',
'description': """We have the capability to schedule log notes and send
diff --git a/odoo_advanced_chatter/doc/RELEASE_NOTES.md b/odoo_advanced_chatter/doc/RELEASE_NOTES.md
index dc389baa2..a00f77608 100644
--- a/odoo_advanced_chatter/doc/RELEASE_NOTES.md
+++ b/odoo_advanced_chatter/doc/RELEASE_NOTES.md
@@ -9,3 +9,8 @@
#### Version 17.0.2.0.0
#### UPDATE
- UPDATE
+
+#### 19.06.2024
+#### Version 17.0.2.0.1
+#### UPDATE
+- BUG FIX
\ No newline at end of file
diff --git a/odoo_advanced_chatter/models/mail_thread.py b/odoo_advanced_chatter/models/mail_thread.py
index 044dde7b4..ac8be11f7 100644
--- a/odoo_advanced_chatter/models/mail_thread.py
+++ b/odoo_advanced_chatter/models/mail_thread.py
@@ -136,8 +136,6 @@ class Message(models.AbstractModel):
if 'email_add_signature' not in msg_values:
msg_values['email_add_signature'] = True
if not msg_values.get('record_name'):
- # use sudo as record access is not always granted (notably when replying
- # a notification) -> final check is done at message creation level
msg_values['record_name'] = self.sudo().display_name
if body_is_html and self.user_has_groups("base.group_user"):
_logger.warning(
@@ -153,7 +151,7 @@ class Message(models.AbstractModel):
'model': self._name,
'res_id': self.id,
# content
- 'body': escape(body), # escape if text, keep if markup
+ 'body': escape(body),
'message_type': message_type,
'parent_id': self._message_compute_parent_id(parent_id),
'subject': subject or False,
diff --git a/odoo_advanced_chatter/static/description/index.html b/odoo_advanced_chatter/static/description/index.html
index 907c75e27..d585fdc4e 100644
--- a/odoo_advanced_chatter/static/description/index.html
+++ b/odoo_advanced_chatter/static/description/index.html
@@ -89,7 +89,7 @@
-
-
+
+
+
+
+
+
+
+ Manage Recipients.
+
We can manage
+ recipients in the Reply Mail.
+
+
+
+
- We can the same corresponding changes in the Mail details also.
+ We can the same corresponding changes in the
+ Mail details also.
diff --git a/odoo_advanced_chatter/static/src/js/chatter.js b/odoo_advanced_chatter/static/src/js/chatter.js
index 3ff8b55f0..4ca86a597 100644
--- a/odoo_advanced_chatter/static/src/js/chatter.js
+++ b/odoo_advanced_chatter/static/src/js/chatter.js
@@ -2,10 +2,17 @@
import { Chatter } from "@mail/core/web/chatter";
import { patch } from "@web/core/utils/patch";
import { _t } from "@web/core/l10n/translation";
+import { useService } from "@web/core/utils/hooks";
//patch the class ChatterContainer to added the click function
patch(Chatter.prototype ,{
setup() {
super.setup();
+ this.orm = useService("orm");
+ this.orm.call(
+ 'mail.wizard.recipient',
+ 'get_user',
+ [this.env.model.user.userId]
+ );
},
replyTo(){
//-----On clicking thr reply to icon a wizard is opened to select the recipient
diff --git a/odoo_advanced_chatter/static/src/js/recipient_list.js b/odoo_advanced_chatter/static/src/js/recipient_list.js
index b4297b997..2c71a58ba 100644
--- a/odoo_advanced_chatter/static/src/js/recipient_list.js
+++ b/odoo_advanced_chatter/static/src/js/recipient_list.js
@@ -6,8 +6,8 @@ import { useState } from "@odoo/owl";
patch(FollowerList.prototype, {
setup() {
super.setup();
- this.state = useState({
- id:[]
+ this.state = useState({
+ id:[]
});
},
async check(ev, follower){
@@ -20,5 +20,5 @@ patch(FollowerList.prototype, {
this.state.id.push(follower.partner.id)
}
this.threadService.check = this.state.id
- }
+ }
})
diff --git a/odoo_advanced_chatter/static/src/js/schedule_mail.js b/odoo_advanced_chatter/static/src/js/schedule_mail.js
index 2a86d6be3..69e4bcd8a 100644
--- a/odoo_advanced_chatter/static/src/js/schedule_mail.js
+++ b/odoo_advanced_chatter/static/src/js/schedule_mail.js
@@ -3,9 +3,16 @@ import { Composer } from "@mail/core/common/composer";
import { patch } from "@web/core/utils/patch";
import { prettifyMessageContent, escapeAndCompactTextContent } from "@mail/utils/common/format";
import { useRef } from "@odoo/owl";
+import { useService } from "@web/core/utils/hooks";
patch(Composer.prototype, {
-setup() {
- super.setup();
+ setup() {
+ super.setup();
+ this.orm = useService("orm");
+ this.orm.call(
+ 'mail.wizard.recipient',
+ 'get_user',
+ [this.env.model.user.userId]
+ )
},
async scheduleLogNote(){
// ------to schedule lognote -------------
@@ -19,23 +26,23 @@ setup() {
? this.messageService.getMentionsFromText(message, {
mentionedChannels: this.props.composer.mentionedChannels,
mentionedPartners: this.props.composer.mentionedPartners,
- })
+ })
: undefined;
$.each(validMentions.partners,(index,mentions) => {
mentioned_list.push(mentions.id)
- });
+ });
var followers_list=[]
$.each( this.props.composer.thread.followers,(index,follower) => {
followers_list.push(follower.partner.id)
- });
+ });
if (recipient){
recipient.forEach(item=>{
const index = followers_list.indexOf(item);
- if (index !== -1) {
- followers_list.splice(index, 1);
+ if (index !== -1) {
+ followers_list.splice(index, 1);
}
})
- }
+ }
if (this.props.type === "note" ){
const action = {
type: 'ir.actions.act_window',
@@ -55,7 +62,7 @@ setup() {
},
};
this.env.services.action.doAction(
- action,
+ action,
{
}
);
diff --git a/odoo_advanced_chatter/wizard/mail_wizard_recipient.py b/odoo_advanced_chatter/wizard/mail_wizard_recipient.py
index 65e8405ea..2f4b781e0 100644
--- a/odoo_advanced_chatter/wizard/mail_wizard_recipient.py
+++ b/odoo_advanced_chatter/wizard/mail_wizard_recipient.py
@@ -19,7 +19,7 @@
# If not, see .
#
#############################################################################
-from odoo import models, fields
+from odoo import models, fields, api
class AddRecipient(models.TransientModel):
@@ -39,3 +39,9 @@ class AddRecipient(models.TransientModel):
added to config parameters"""
self.env['ir.config_parameter'].set_param('reply_to',
self.partner_id.id)
+
+ @api.model
+ def get_user(self, user_id):
+ """if reply mail is sent to the person who sent the mail,
+ then default person will be set in config parameters"""
+ self.env['ir.config_parameter'].set_param('reply_to', user_id)