You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

32 lines
602 B

  1. from frappe import _
  2. doctype_list = [
  3. "Purchase Receipt",
  4. "Purchase Invoice",
  5. "Quotation",
  6. "Sales Order",
  7. "Delivery Note",
  8. "Sales Invoice",
  9. ]
  10. def get_message(doctype):
  11. return _("{0} has been submitted successfully").format(_(doctype))
  12. def get_first_success_message(doctype):
  13. return get_message(doctype)
  14. def get_default_success_action():
  15. return [
  16. {
  17. "doctype": "Success Action",
  18. "ref_doctype": doctype,
  19. "message": get_message(doctype),
  20. "first_success_message": get_first_success_message(doctype),
  21. "next_actions": "new\nprint\nemail",
  22. }
  23. for doctype in doctype_list
  24. ]