From 2482bf32c03dcc0c5cf083c59e944452f1cf4db1 Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Mon, 15 Oct 2012 12:32:58 +0530 Subject: [PATCH 1/2] fix in recurring invoice error email --- accounts/doctype/gl_control/gl_control.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/accounts/doctype/gl_control/gl_control.py b/accounts/doctype/gl_control/gl_control.py index 005567e761..e8091dfc34 100644 --- a/accounts/doctype/gl_control/gl_control.py +++ b/accounts/doctype/gl_control/gl_control.py @@ -438,14 +438,15 @@ def manage_recurring_invoices(): def notify_errors(inv, owner): + from webnotes.utils import get_request_site_address exception_msg = """ Dear User, - An error occured while creating recurring invoice from %s. + An error occured while creating recurring invoice from %s (at %s). May be there are some invalid email ids mentioned in the invoice. - To stop sending repetitive error notifications from the system, we have unchecked \ + To stop sending repetitive error notifications from the system, we have unchecked "Convert into Recurring" field in the invoice %s. @@ -458,11 +459,11 @@ def notify_errors(inv, owner): Regards, Administrator - """ % (inv, inv) + """ % (inv, get_request_site_address(), inv) subj = "[Urgent] Error while creating recurring invoice from %s" % inv import webnotes.utils recipients = webnotes.utils.get_system_managers_list() - recipients += ['support@erpnext.com', owner] + recipients += [webnotes.conn.get_value("Profile", owner, "email")] assign_task_to_owner(inv, exception_msg, recipients) sendmail(recipients, subject=subj, msg = exception_msg) From 1a2f23254b4786495e7c0ea8d104455e5ebee3fe Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Mon, 15 Oct 2012 12:41:05 +0530 Subject: [PATCH 2/2] changed label from Cheque No and Date to Reference Number and Date --- .../journal_voucher/journal_voucher.txt | 48 ++++++++++++++----- 1 file changed, 37 insertions(+), 11 deletions(-) diff --git a/accounts/doctype/journal_voucher/journal_voucher.txt b/accounts/doctype/journal_voucher/journal_voucher.txt index be102a03fa..7c1fa78dbf 100644 --- a/accounts/doctype/journal_voucher/journal_voucher.txt +++ b/accounts/doctype/journal_voucher/journal_voucher.txt @@ -3,9 +3,9 @@ # These values are common in all dictionaries { - u'creation': '2012-05-04 10:21:24', + u'creation': '2012-10-02 18:51:46', u'docstatus': 0, - u'modified': '2012-10-02 16:43:51', + u'modified': '2012-10-15 12:38:42', u'modified_by': u'Administrator', u'owner': u'Administrator' }, @@ -235,11 +235,13 @@ # DocField { + 'colour': u'White:FFF', + 'description': u'eg. Cheque Number', u'doctype': u'DocField', 'fieldname': u'cheque_no', 'fieldtype': u'Data', 'in_filter': 1, - 'label': u'Cheque No', + 'label': u'Reference Number', 'no_copy': 1, 'oldfieldname': u'cheque_no', 'oldfieldtype': u'Data', @@ -252,7 +254,7 @@ u'doctype': u'DocField', 'fieldname': u'cheque_date', 'fieldtype': u'Date', - 'label': u'Cheque Date', + 'label': u'Reference Date', 'no_copy': 1, 'oldfieldname': u'cheque_date', 'oldfieldtype': u'Date', @@ -743,6 +745,30 @@ 'trigger': u'Client' }, + # DocPerm + { + 'amend': 1, + 'cancel': 1, + 'create': 1, + u'doctype': u'DocPerm', + 'permlevel': 0, + 'role': u'Accounts User', + 'submit': 1, + 'write': 1 + }, + + # DocPerm + { + 'amend': 0, + 'cancel': 0, + 'create': 0, + u'doctype': u'DocPerm', + 'permlevel': 1, + 'role': u'Accounts User', + 'submit': 0, + 'write': 0 + }, + # DocPerm { 'amend': 0, @@ -769,14 +795,14 @@ # DocPerm { - 'amend': 1, - 'cancel': 1, - 'create': 1, + 'amend': 0, + 'cancel': 0, + 'create': 0, u'doctype': u'DocPerm', 'permlevel': 0, - 'role': u'Accounts User', - 'submit': 1, - 'write': 1 + 'role': u'Auditor', + 'submit': 0, + 'write': 0 }, # DocPerm @@ -786,7 +812,7 @@ 'create': 0, u'doctype': u'DocPerm', 'permlevel': 1, - 'role': u'Accounts User', + 'role': u'Auditor', 'submit': 0, 'write': 0 }