mirror of
https://github.com/frappe/erpnext.git
synced 2026-04-26 01:58:31 +00:00
fix: add filter query for address field
This commit is contained in:
@@ -2854,7 +2854,7 @@ def save_company_master_details(name, company, details):
|
||||
details = frappe.parse_json(details)
|
||||
|
||||
if details.get("email"):
|
||||
validate_email_address(details.email, throw=True)
|
||||
validate_email_address(details.get("email"), throw=True)
|
||||
|
||||
company_fields = ["company_logo", "website", "phone_no", "email"]
|
||||
company_fields_to_update = {field: details.get(field) for field in company_fields if details.get(field)}
|
||||
|
||||
@@ -104,6 +104,7 @@ frappe.realtime.on("sales_invoice_before_print", (data) => {
|
||||
options: "Address",
|
||||
get_query: function () {
|
||||
return {
|
||||
query: "frappe.contacts.doctype.address.address.address_query",
|
||||
filters: {
|
||||
link_doctype: "Company",
|
||||
link_name: data.company,
|
||||
|
||||
Reference in New Issue
Block a user