Merge pull request #32268 from akhilnarang/drop-example-email-address-creation

fix: don't create example email domains and email accounts
This commit is contained in:
Akhil Narang 2025-04-29 12:50:29 +05:30 committed by GitHub
commit 8d42b4d3d6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 12 additions and 34 deletions

View file

@ -19,7 +19,6 @@ def install():
update_genders()
update_salutations()
update_global_search_doctypes()
setup_email_linking()
sync_dashboards()
add_unsubscribe()
@ -56,12 +55,6 @@ def update_salutations():
doc.insert(ignore_permissions=True, ignore_if_duplicate=True)
def setup_email_linking():
doc = frappe.new_doc("Email Account")
doc.email_id = "email_linking@example.com"
doc.insert(ignore_permissions=True, ignore_if_duplicate=True)
def add_unsubscribe():
for unsubscribe in [
{"email": "admin@example.com", "global_unsubscribe": 1},

View file

@ -28,5 +28,14 @@
"smtp_server": "smtp.test.com",
"smtp_port": "587",
"password": "password"
},
{
"doctype": "Email Domain",
"domain_name": "example.com",
"email_id": "account@example.com",
"password": "pass",
"email_server": "imap.example.com",
"use_imap": 1,
"smtp_server": "smtp.example.com"
}
]

View file

@ -103,7 +103,6 @@ frappe.patches.v12_0.setup_tags
frappe.patches.v12_0.update_auto_repeat_status_and_not_submittable
frappe.patches.v12_0.create_notification_settings_for_user
frappe.patches.v11_0.make_all_prepared_report_attachments_private #2019-11-26
frappe.patches.v12_0.setup_email_linking
frappe.patches.v12_0.change_existing_dashboard_chart_filters
frappe.patches.v12_0.set_correct_assign_value_in_docs #2020-07-13
execute:frappe.delete_doc('DocType', 'Test Runner') # 2022-05-19

View file

@ -1,5 +0,0 @@
from frappe.desk.page.setup_wizard.install_fixtures import setup_email_linking
def execute():
setup_email_linking()

View file

@ -499,6 +499,9 @@ def setup_image_doctype():
@whitelist_for_tests
def setup_inbox():
frappe.db.delete("User Email")
doc = frappe.new_doc("Email Account")
doc.email_id = "email_linking@example.com"
doc.insert(ignore_permissions=True, ignore_if_duplicate=True)
user = frappe.get_doc("User", frappe.session.user)
user.append("user_emails", {"email_account": "Email Linking"})

View file

@ -112,27 +112,6 @@ def install_basic_docs():
{"doctype": "Workflow Action Master", "workflow_action_name": "Approve"},
{"doctype": "Workflow Action Master", "workflow_action_name": "Reject"},
{"doctype": "Workflow Action Master", "workflow_action_name": "Review"},
{
"doctype": "Email Domain",
"domain_name": "example.com",
"email_id": "account@example.com",
"password": "pass",
"email_server": "imap.example.com",
"use_imap": 1,
"smtp_server": "smtp.example.com",
},
{
"doctype": "Email Account",
"domain": "example.com",
"email_id": "notifications@example.com",
"default_outgoing": 1,
},
{
"doctype": "Email Account",
"domain": "example.com",
"email_id": "replies@example.com",
"default_incoming": 1,
},
]
for d in install_docs: