From bd4c7c533cf17ea9710a7b67377fa616e82ecb9f Mon Sep 17 00:00:00 2001 From: Landry Date: Mon, 11 Nov 2024 15:07:55 +0000 Subject: [PATCH] Updated Addess py file --- erpnext/accounts/custom/address.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/erpnext/accounts/custom/address.py b/erpnext/accounts/custom/address.py index 775a81fd25..e9a26fbae5 100644 --- a/erpnext/accounts/custom/address.py +++ b/erpnext/accounts/custom/address.py @@ -15,7 +15,7 @@ class ERPNextAddress(Address): def link_address(self): """Link address based on owner""" - if self.is_your_company_address: + if self.custom_is_your_company_address: return return super(ERPNextAddress, self).link_address() @@ -23,10 +23,10 @@ class ERPNextAddress(Address): def update_compnay_address(self): for link in self.get("links"): if link.link_doctype == "Company": - self.is_your_company_address = 1 + self.custom_is_your_company_address = 1 def validate_reference(self): - if self.is_your_company_address and not [ + if self.custom_is_your_company_address and not [ row for row in self.links if row.link_doctype == "Company" ]: frappe.throw( @@ -50,7 +50,7 @@ def get_shipping_address(company, address=None): filters = [ ["Dynamic Link", "link_doctype", "=", "Company"], ["Dynamic Link", "link_name", "=", company], - ["Address", "is_your_company_address", "=", 1], + ["Address", "custom_is_your_company_address", "=", 1], ] fields = ["*"] if address and frappe.db.get_value("Dynamic Link", {"parent": address, "link_name": company}):