fix: wrapper for '.__' (#7159)

This commit is contained in:
Faris Ansari 2019-03-29 20:22:39 +05:30 committed by GitHub
commit 4bfec7ca19
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1183,6 +1183,12 @@ class Document(BaseDocument):
self.set("__onload", frappe._dict())
self.get("__onload")[key] = value
def get_onload(self, key=None):
if not key:
return self.get("__onload", frappe._dict())
return self.get('__onload')[key]
def update_timeline_doc(self):
if frappe.flags.in_install or not self.meta.get("timeline_field"):
return