mirror of
https://github.com/OCA/pms.git
synced 2025-01-29 00:17:45 +02:00
[FIX]pms: fixed sending email to the creator user of the folio
This commit is contained in:
@@ -1401,7 +1401,7 @@ class PmsFolio(models.Model):
|
||||
)
|
||||
ctx = dict(
|
||||
model="pms.folio",
|
||||
default_res_model="pms.folio",
|
||||
default_model="pms.folio",
|
||||
default_res_id=self.id,
|
||||
template_id=template and template.id or False,
|
||||
composition_mode="comment",
|
||||
@@ -1421,6 +1421,13 @@ class PmsFolio(models.Model):
|
||||
"context": ctx,
|
||||
}
|
||||
|
||||
def _message_post_after_hook(self, message, msg_vals):
|
||||
res = super(PmsFolio, self)._message_post_after_hook(message, msg_vals)
|
||||
for folio in self:
|
||||
for follower in folio.message_follower_ids:
|
||||
follower.unlink()
|
||||
return res
|
||||
|
||||
def action_view_invoice(self):
|
||||
invoices = self.mapped("move_ids")
|
||||
action = self.env["ir.actions.actions"]._for_xml_id(
|
||||
|
||||
Reference in New Issue
Block a user