def has_website_permission(self, permtype="read", verbose=False):
		"""Call `frappe.has_website_permission` if `self.flags.ignore_permissions`
		is not set.

		:param permtype: one of `read`, `write`, `submit`, `cancel`, `delete`"""
		if self.flags.ignore_permissions:
			return True

		return (frappe.has_website_permission(self.doctype, permtype, self, verbose=verbose)
			or self.has_permission(permtype, verbose=verbose))
dataset/ETHPy150Open frappe/frappe/frappe/model/document.py/Document.has_website_permission/original