style: follow simple indenting standard
This commit is contained in:
parent
1bb8dcf176
commit
9f183e6cf2
2 changed files with 11 additions and 2 deletions
|
|
@ -364,7 +364,11 @@ class User(Document):
|
|||
# delete todos
|
||||
frappe.db.delete("ToDo", {"owner": self.name})
|
||||
todo_table = DocType("ToDo")
|
||||
frappe.qb.update(todo_table).set(todo_table.assigned_by, None).where(todo_table.assigned_by == self.name).run()
|
||||
(
|
||||
frappe.qb.update(todo_table)
|
||||
.set(todo_table.assigned_by, None)
|
||||
.where(todo_table.assigned_by == self.name)
|
||||
).run()
|
||||
|
||||
# delete events
|
||||
frappe.db.delete("Event", {"owner": self.name, "event_type": "Private"})
|
||||
|
|
|
|||
|
|
@ -61,7 +61,12 @@ def get_unread_emails():
|
|||
|
||||
communication_doctype = DocType("Communication")
|
||||
user_doctype = DocType("User")
|
||||
distinct_email_accounts = frappe.qb.from_(user_doctype).select(user_doctype.email_account).where(user_doctype.parent == frappe.session.user).distinct()
|
||||
distinct_email_accounts = (
|
||||
frappe.qb.from_(user_doctype)
|
||||
.select(user_doctype.email_account)
|
||||
.where(user_doctype.parent == frappe.session.user)
|
||||
.distinct()
|
||||
)
|
||||
|
||||
return frappe.db.count(communication_doctype, filters=(
|
||||
(communication_doctype.communication_type == "Communication")
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue