From fbd2ee096b33762f218865f908aa82a5ae70118a Mon Sep 17 00:00:00 2001 From: Rushabh Mehta Date: Thu, 29 Aug 2013 13:59:22 +0530 Subject: [PATCH 1/2] [communications] [minor] Code cleanup so it can be extended by custom script --- core/doctype/communication/communication.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/core/doctype/communication/communication.py b/core/doctype/communication/communication.py index 14daa88691..2b2fc7e6a1 100644 --- a/core/doctype/communication/communication.py +++ b/core/doctype/communication/communication.py @@ -71,6 +71,8 @@ def make(doctype=None, name=None, content=None, subject=None, d.communication_medium = communication_medium if send_email: send_comm_email(d, name, sent_via, print_html, attachments, send_me_a_copy) + + comm.ignore_permissions = True comm.insert() @webnotes.whitelist() From ace7d787ea4efee8246bd055c655cbeb1ecc214e Mon Sep 17 00:00:00 2001 From: Rushabh Mehta Date: Thu, 29 Aug 2013 14:00:26 +0530 Subject: [PATCH 2/2] [communications] [minor] Code cleanup so it can be extended by custom script --- core/doctype/communication/communication.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/doctype/communication/communication.py b/core/doctype/communication/communication.py index 2b2fc7e6a1..80c7765bd5 100644 --- a/core/doctype/communication/communication.py +++ b/core/doctype/communication/communication.py @@ -28,8 +28,8 @@ class DocType(): else: parent.doc.status = "Open" - parent.bean.ignore_permissions = True - parent.bean.save() + parent.ignore_permissions = True + parent.save() @webnotes.whitelist() def make(doctype=None, name=None, content=None, subject=None,