Wednesday, July 6, 2016

Update Field Value In Other Doctype Using Python

Use frappe.get_doc in a function and call it accordingly

doc = frappe.get_doc(doctype-name, document-name)

# get property
doc.title

# set property to the document
doc.first_name = 'My Name'

# save a document to the database
doc.save()

1 comment:

  1. Python is a preferable scripting language and easy to learn syntax for the new programmers. Our Python training in bangalore. for data science and Python helps all developers to become better programmers.

    ReplyDelete