fix(erpsetup): Breakpilot in the invoice mail and the logo alt text
ci / shared (pull_request) Failing after 13s
ci / test (pull_request) Successful in 26m58s
ci / image (pull_request) Skipped

Customer-visible text only. ERPNext record names (print formats, letter
head, e-mail template, item group) keep BreakPilot: renaming them would
create new records. A test keeps the customer text on Breakpilot.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Sharang ParnerkarandClaude Opus 5.5 committed 2026-11-09 10:56:48 +01:00
1 parent bc40a63589
commit 175703f062
2 files changed
+18 -3

No files matched your search

+3 -3
View File
@@ -99,7 +99,7 @@ func emailTemplateDoc() map[string]any {
return map[string]any{
"doctype": "Email Template", "name": emailTemplateRE, "enabled": 1,
"reference_doctype": "Sales Invoice",
"subject": "Rechnung {{ name }} – BreakPilot",
"subject": "Rechnung {{ name }} – Breakpilot",
"use_html": 1, "response_html": invoiceMailHTML,
}
}
@@ -132,7 +132,7 @@ func logoFileDoc() map[string]any {
}
}
const logoSVG = `<img alt="BreakPilot" width="30" height="29" style="display:block;" src="` + logoFileURL + `">`
const logoSVG = `<img alt="Breakpilot" width="30" height="29" style="display:block;" src="` + logoFileURL + `">`
// Shared Jinja: the company's own address and its bank account.
const companyVars = `{%- set bp_addr = frappe.db.get_value("Address", {"is_your_company_address": 1, "is_primary_address": 1, "disabled": 0}, ["address_line1", "pincode", "city", "email_id"], as_dict=1) or {"address_line1": "In Steinäckern 16", "pincode": "78351", "city": "Bodman-Ludwigshafen", "email_id": "kontakt@breakpilot.com"} -%}
@@ -370,7 +370,7 @@ var invoiceMailHTML = brand.Replace(`<div style="font-family:Arial,Helvetica,san
<p>Bei Fragen zur Rechnung antworten Sie einfach auf diese E-Mail.</p>
<table style="font-size:13px;line-height:1.5;color:$INK;border-collapse:collapse;margin-top:18px;"><tr><td>
<div style="font-size:12px;color:#71769B;">Mit freundlichen Grüßen</div>
<div style="font-size:16px;font-weight:bold;margin:1px 0 10px;">Ihr BreakPilot-Team</div>
<div style="font-size:16px;font-weight:bold;margin:1px 0 10px;">Ihr Breakpilot-Team</div>
<div style="font-weight:bold;">{{ company }}</div>
<div style="color:#43466A;">In Steinäckern 16, 78351 Bodman-Ludwigshafen</div>
<div style="color:#43466A;"><a href="mailto:kontakt@breakpilot.com" style="color:$ACCENT;text-decoration:none;">kontakt@breakpilot.com</a> · <a href="https://www.breakpilot.com" style="color:$ACCENT;text-decoration:none;">www.breakpilot.com</a></div>
+15
View File
@@ -794,3 +794,18 @@ func TestQuoteNamesLBVersions(t *testing.T) {
t.Error("Prüfwerk Standard description does not name the code graph (LB Prüfwerk 1.0.3 § 4 Abs. 4)")
}
}
// What customers read is spelled "Breakpilot": the documents, the letter
// head and footer, and the invoice e-mail with its subject. ERPNext record
// names (print formats, letter head, item group) keep the old spelling,
// because renaming them would create new records.
func TestCustomerTextSpellsBreakpilot(t *testing.T) {
for name, s := range map[string]string{
"document": documentHTML, "letter head": letterHeadHTML, "letter footer": letterFooterHTML,
"invoice mail": invoiceMailHTML, "logo": logoSVG, "mail subject": emailTemplateDoc()["subject"].(string),
} {
if strings.Contains(s, "BreakPilot") {
t.Errorf("%s still spells BreakPilot", name)
}
}
}