fix: override modified_by to 'Administrator' to non-custom doctypes

This commit is contained in:
Abhishek Balam 2020-09-21 22:33:04 +05:30
parent 6bddca6598
commit 94e7f23d0a

View file

@ -41,6 +41,10 @@ def write_document_file(doc, record_module=None, create_init=True, folder_name=N
else:
folder = create_folder(module, doc.doctype, doc.name, create_init)
# override modified_by in json file
if not newdoc.custom:
newdoc.modified_by = 'Administrator'
# write the data file
fname = scrub(doc.name)
with open(os.path.join(folder, fname + ".json"), 'w+') as txtfile: