Merge pull request #4058 from pratu16x7/setup-fixes
[setup] suppress post-setup messages
This commit is contained in:
commit
46eee356ff
2 changed files with 4 additions and 2 deletions
|
|
@ -112,7 +112,9 @@ class User(Document):
|
|||
self.get("roles")]):
|
||||
return
|
||||
|
||||
if self.name not in STANDARD_USERS and self.user_type == "System User" and not self.get_other_system_managers():
|
||||
if (self.name not in STANDARD_USERS and self.user_type == "System User" and not self.get_other_system_managers()
|
||||
and cint(frappe.db.get_single_value('System Settings', 'setup_complete'))):
|
||||
|
||||
msgprint(_("Adding System Manager to this User as there must be atleast one System Manager"))
|
||||
self.append("roles", {
|
||||
"doctype": "Has Role",
|
||||
|
|
|
|||
|
|
@ -53,7 +53,7 @@ def get_outgoing_email_account(raise_exception_not_set=True, append_to=None):
|
|||
if not email_account:
|
||||
email_account = get_default_outgoing_email_account(raise_exception_not_set=raise_exception_not_set)
|
||||
|
||||
if not email_account and raise_exception_not_set:
|
||||
if not email_account and raise_exception_not_set and cint(frappe.db.get_single_value('System Settings', 'setup_complete')):
|
||||
frappe.throw(_("Please setup default Email Account from Setup > Email > Email Account"),
|
||||
frappe.OutgoingEmailError)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue