Skip to content

Commit

Permalink
feat(RFQ): make sending attachments configurable (backport #36359) (#…
Browse files Browse the repository at this point in the history
…36535)

* feat(RFQ): make sending attachments configurable (#36359)

(cherry picked from commit 8cc3df7)

# Conflicts:
#	erpnext/buying/doctype/request_for_quotation/request_for_quotation.json

* chore: resolve conflicts

---------

Co-authored-by: Raffael Meyer <14891507+barredterra@users.noreply.github.com>
  • Loading branch information
mergify[bot] and barredterra authored Aug 7, 2023
1 parent 9c108a8 commit 5881960
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
"col_break_email_1",
"email_template",
"preview",
"send_attached_files",
"sec_break_email_2",
"message_for_supplier",
"terms_section_break",
Expand Down Expand Up @@ -285,13 +286,20 @@
"fieldname": "named_place",
"fieldtype": "Data",
"label": "Named Place"
},
{
"default": "1",
"description": "If enabled, all files attached to this document will be attached to each email",
"fieldname": "send_attached_files",
"fieldtype": "Check",
"label": "Send Attached Files"
}
],
"icon": "fa fa-shopping-cart",
"index_web_pages_for_search": 1,
"is_submittable": 1,
"links": [],
"modified": "2023-01-31 23:22:06.684694",
"modified": "2023-07-27 16:41:48.468873",
"modified_by": "Administrator",
"module": "Buying",
"name": "Request for Quotation",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,9 @@ def supplier_rfq_mail(self, data, update_password_link, rfq_link, preview=False)
if preview:
return message

attachments = self.get_attachments()
attachments = None
if self.send_attached_files:
attachments = self.get_attachments()

self.send_email(data, sender, subject, message, attachments)

Expand Down

0 comments on commit 5881960

Please sign in to comment.