Table Of Contents

Previous topic

doclist — Doclist Module

Next topic

code — Code Execution Module

This Page

doctype — DocType

_DocType object

doctype.get(dt)
returns a doclist of DocType, dt
class doctype._DocType(name)

The _DocType object is created internally using the module’s get method.

name
name of the doctype
is_modified()

returns 3 objects:

  • last modified date of the DocType
  • whether the doctypes is modified after it was cached
  • last modified date of the DocType from the cache
get_parent_dt()
return the first parent DocType of the current doctype
make_doclist()

returns the doclist for consumption by the client

  • it cleans up the server code
  • executes all $import tags in client code
  • replaces link: in the Select fields
  • loads all related Search Criteria
  • updates the cache
doctype.get()
execute Request to load a DocType
doctype.update_doctype(doclist)

method to be called to update the DocType

  • creates field names from labels
  • updates schema
  • saves compiled code
  • marks cache for clearing