Ver código fonte

[hotfix] minor fixes in the Email Communication subject field (#4278)

version-14
Makarand Bauskar 7 anos atrás
committed by Rushabh Mehta
pai
commit
229f676645
1 arquivos alterados com 6 adições e 1 exclusões
  1. +6
    -1
      frappe/public/js/frappe/views/communication.js

+ 6
- 1
frappe/public/js/frappe/views/communication.js Ver arquivo

@@ -149,7 +149,12 @@ frappe.views.CommunicationComposer = Class.extend({
if (this.frm.subject_field && this.frm.doc[this.frm.subject_field]) {
this.subject = __("Re: {0}", [this.frm.doc[this.frm.subject_field]]);
} else {
this.subject = __(this.frm.doctype) + ': ' + this.frm[this.frm.meta.title_field || name];
let title = this.frm.doc.name;
if(this.frm.meta.title_field && this.frm.doc[this.frm.meta.title_field]
&& this.frm.doc[this.frm.meta.title_field] != this.frm.doc.name) {
title = `${this.frm.doc[this.frm.meta.title_field]} (#${this.frm.doc.name})`;
}
this.subject = `${__(this.frm.doctype)}: ${title}`;
}
}
}


Carregando…
Cancelar
Salvar