From 28c96999e2be59021fcb883f08a6b1d90a456151 Mon Sep 17 00:00:00 2001 From: Diptanil Saha Date: Mon, 27 Jul 2026 23:29:57 +0530 Subject: [PATCH] fix(quotation): carry forward communications from opportunity (#57507) --- erpnext/selling/doctype/quotation/quotation.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/erpnext/selling/doctype/quotation/quotation.py b/erpnext/selling/doctype/quotation/quotation.py index 8eaf33c084d..b1bca9e3e39 100644 --- a/erpnext/selling/doctype/quotation/quotation.py +++ b/erpnext/selling/doctype/quotation/quotation.py @@ -301,6 +301,7 @@ class Quotation(SellingController): # update enquiry status self.update_opportunity("Quotation") self.update_lead() + self.carry_forward_communication() def on_cancel(self): if self.lost_reasons: @@ -312,6 +313,18 @@ class Quotation(SellingController): self.update_opportunity("Open") self.update_lead() + def carry_forward_communication(self): + from erpnext.crm.utils import copy_comments, link_communications + + if not ( + self.opportunity + and frappe.get_single_value("CRM Settings", "carry_forward_communication_and_comments") + ): + return + + copy_comments("Opportunity", self.opportunity, self) + link_communications("Opportunity", self.opportunity, self) + def print_other_charges(self, docname): print_lst = [] for d in self.get("taxes"):