brotherton-erpnext/erpnext/setup/default_success_action.py

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

32 lines
602 B
Python
Raw Normal View History

from frappe import _
doctype_list = [
"Purchase Receipt",
"Purchase Invoice",
"Quotation",
"Sales Order",
"Delivery Note",
"Sales Invoice",
]
2022-03-28 13:22:46 +00:00
def get_message(doctype):
return _("{0} has been submitted successfully").format(_(doctype))
2022-03-28 13:22:46 +00:00
def get_first_success_message(doctype):
return get_message(doctype)
2022-03-28 13:22:46 +00:00
def get_default_success_action():
return [
{
"doctype": "Success Action",
"ref_doctype": doctype,
"message": get_message(doctype),
"first_success_message": get_first_success_message(doctype),
"next_actions": "new\nprint\nemail",
}
for doctype in doctype_list
]