How to add jinja templates in Standard Reply…for ex: {{ doc.name }} etc…
@Ram_Gopal_Rao AFAIK, Same functionality was developed for email alert
You can fork and add this feature for standard reply so it will be helpful for all.
If you want quick fix, you can addd your custom standard reply by overriding existing script as follows.
frappe.views.CommunicationComposer = frappe.views.CommunicationComposer.extend({
make_fun: function(){
var me = this;
var content_field = me.dialog.fields_dict.content;
var subject_field = me.dialog.fields_dict.subject;
var rec = me.dialog.fields_dict.recipients.get_value();
recipients_field.set_input(rec +"Custom@gmail.com")
},
make: function(){
this._super();
this.make_fun();
}
});`
Regards,
Sambhaji Kolate,
Hi @Ram_Gopal_Rao,
If you are using version 7 then new feature has added where you can put jinja template inside the standard reply’s response field, template example is as below
Dear {{ customer }}
Thanks, We have successfully received payment against invoice no {{ name }}
Thanks, Rohit
I’m using cloud version of ERPNext. Is it possible to custom standard reply in cloud version?
Dear Rohit,
do we need to use doc. i.e to get customer name {{ doc.customer }} or {{ customer }} ?
@Ram_Gopal_Rao custom script is possible in cloud hosted.
You can write above custom script.
Regards,
Sambhaji Kolate,
@Ram_Gopal_Rao
Thia feature is developed on V7.
If you have test instance on your local, you can test this.
Very good feature, but we can not set default standard reply for doctype.
what about setting up standard reply per doctype, it will be useful to send quotation, invoices and delivery note.
Currently we do this using custom script for each doctype, but this feature will be very helpful for non technical person.
Thanks,
Sam
Seems like a good idea. Please raise a github feature request for the same.
Allready created one issue in github