diff --git a/erpnext/venue/doctype/item_booking/item_booking.py b/erpnext/venue/doctype/item_booking/item_booking.py index a06ce1fea656e7c4ba9a50af5f5e62b0a0b7426b..5022b9bab17a626b08281e383d20eb17d9bd47ba 100644 --- a/erpnext/venue/doctype/item_booking/item_booking.py +++ b/erpnext/venue/doctype/item_booking/item_booking.py @@ -48,6 +48,8 @@ from erpnext.venue.utils import get_linked_customers if TYPE_CHECKING: from typing import Callable, TypeVar + from erpnext.selling.doctype.quotation.quotation import Quotation + class schedule_line_t(TypedDict): start_time: str end_time: str @@ -1483,9 +1485,7 @@ def clear_draft_bookings(): @frappe.whitelist() def make_quotation(source_name, target_doc=None): def set_missing_values(source, target): - from erpnext.controllers.accounts_controller import get_default_taxes_and_charges - - quotation = frappe.get_doc(target) + quotation: "Quotation" = frappe.get_doc(target) quotation.order_type = "Maintenance" company_currency = frappe.get_cached_value("Company", quotation.company, "default_currency") @@ -1518,14 +1518,8 @@ def make_quotation(source_name, target_doc=None): }, ) - # get default taxes - taxes = get_default_taxes_and_charges( - "Sales Taxes and Charges Template", company=quotation.company - ) - if taxes.get("taxes"): - quotation.update(taxes) - quotation.run_method("set_missing_values") + quotation.run_method("set_other_charges") quotation.run_method("calculate_taxes_and_totals") doclist = get_mapped_doc(