fix: POS Invoice Email Receipt Mail

This commit is contained in:
Nihantra C. Patel 2023-08-11 12:27:18 +05:30 committed by GitHub
parent 5bed119de9
commit 7e34468504
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -49,7 +49,7 @@ erpnext.PointOfSale.PastOrderSummary = class {
title: 'Email Receipt',
fields: [
{fieldname: 'email_id', fieldtype: 'Data', options: 'Email', label: 'Email ID'},
// {fieldname:'remarks', fieldtype:'Text', label:'Remarks (if any)'}
{fieldname:'content', fieldtype:'Small Text', label:'Message (if any)'}
],
primary_action: () => {
this.send_email();
@ -243,6 +243,7 @@ erpnext.PointOfSale.PastOrderSummary = class {
send_email() {
const frm = this.events.get_frm();
const recipients = this.email_dialog.get_values().email_id;
const content = this.email_dialog.get_values().content;
const doc = this.doc || frm.doc;
const print_format = frm.pos_print_format;
@ -251,6 +252,7 @@ erpnext.PointOfSale.PastOrderSummary = class {
args: {
recipients: recipients,
subject: __(frm.meta.name) + ': ' + doc.name,
content: content ? content : __(frm.meta.name) + ': ' + doc.name,
doctype: doc.doctype,
name: doc.name,
send_email: 1,