share_6.py 275 B

1234567
  1. def get_shared_doctypes(user=None):
  2. """Return list of doctypes in which documents are shared for the given user."""
  3. if not user:
  4. user = frappe.session.user
  5. return frappe.db.sql_list("select distinct share_doctype from tabDocShare where (user=%s or everyone=1)", user)