def get_doctype_info(module):
 doctype_info = frappe.db.sql(u'select "doctype" as type, name, description,\n DCTB  DCTB ifnull(document_type, "") as document_type, custom as custom,\n DCTB  DCTB issingle as issingle\n DCTB  DCTB from `tabDocType` where module=%s and istable=0\n DCTB  DCTB order by custom asc, document_type desc, name asc', module, as_dict=True)
 for d in doctype_info:
  d.description = _((d.description or u''))
 return doctype_info

def get_doctype_info ( module ) : doctype_info = frappe . db . sql ( u'select "doctype" as type, name, description,\n DCTB  DCTB ifnull(document_type, "") as document_type, custom as custom,\n DCTB  DCTB issingle as issingle\n DCTB  DCTB from `tabDocType` where module=%s and istable=0\n DCTB  DCTB order by custom asc, document_type desc, name asc' , module , as_dict = True ) for d in doctype_info : d . description = _ ( ( d . description or u'' ) ) return doctype_info
returns list of non child doctypes for given module .