diff --git a/erpnext/__init__.py b/erpnext/__init__.py index 4f18687787..0b61c90dec 100644 --- a/erpnext/__init__.py +++ b/erpnext/__init__.py @@ -5,7 +5,7 @@ import frappe from erpnext.hooks import regional_overrides from frappe.utils import getdate -__version__ = '10.1.56' +__version__ = '10.1.57' def get_default_company(user=None): '''Get default company for user''' diff --git a/erpnext/buying/doctype/supplier_quotation/supplier_quotation.py b/erpnext/buying/doctype/supplier_quotation/supplier_quotation.py index b221a08959..5b4356a747 100644 --- a/erpnext/buying/doctype/supplier_quotation/supplier_quotation.py +++ b/erpnext/buying/doctype/supplier_quotation/supplier_quotation.py @@ -60,7 +60,12 @@ class SupplierQuotation(BuyingController): for rfq in rfq_list: doc = frappe.get_doc('Request for Quotation', rfq) doc_sup = frappe.get_all('Request for Quotation Supplier', filters= - {'parent': doc.name, 'supplier': self.supplier}, fields=['name', 'quote_status'])[0] + {'parent': doc.name, 'supplier': self.supplier}, fields=['name', 'quote_status']) + + doc_sup = doc_sup[0] if doc_sup else None + if not doc_sup: + frappe.throw(_("Supplier {0} not found in {1}").format(self.supplier, + " Request for Quotation {0} ".format(doc.name))) quote_status = _('Received') for item in doc.items: @@ -152,4 +157,4 @@ def make_quotation(source_name, target_doc=None): } }, target_doc) - return doclist \ No newline at end of file + return doclist diff --git a/erpnext/setup/setup_wizard/operations/taxes_setup.py b/erpnext/setup/setup_wizard/operations/taxes_setup.py index e0efda095d..8bcec5235b 100644 --- a/erpnext/setup/setup_wizard/operations/taxes_setup.py +++ b/erpnext/setup/setup_wizard/operations/taxes_setup.py @@ -98,4 +98,4 @@ def get_country_wise_tax(country): with open (os.path.join(os.path.dirname(__file__), "..", "data", "country_wise_tax.json")) as countrywise_tax: data = json.load(countrywise_tax).get(country) - return data \ No newline at end of file + return data