Merge pull request #30385 from deepeshgarg007/quotation_gst

fix(India): Auto tax fetching based on GSTIN
This commit is contained in:
Deepesh Garg
2022-03-29 10:25:57 +05:30
committed by GitHub
6 changed files with 344 additions and 88 deletions

View File

@@ -355,4 +355,5 @@ erpnext.patches.v13_0.update_accounts_in_loan_docs
erpnext.patches.v13_0.remove_unknown_links_to_prod_plan_items # 24-03-2022 erpnext.patches.v13_0.remove_unknown_links_to_prod_plan_items # 24-03-2022
erpnext.patches.v13_0.rename_non_profit_fields erpnext.patches.v13_0.rename_non_profit_fields
erpnext.patches.v13_0.enable_ksa_vat_docs #1 erpnext.patches.v13_0.enable_ksa_vat_docs #1
erpnext.patches.v13_0.update_expense_claim_status_for_paid_advances erpnext.patches.v13_0.create_gst_custom_fields_in_quotation
erpnext.patches.v13_0.update_expense_claim_status_for_paid_advances

View File

@@ -0,0 +1,29 @@
import frappe
from frappe.custom.doctype.custom_field.custom_field import create_custom_fields
def execute():
company = frappe.get_all('Company', filters = {'country': 'India'}, fields=['name'])
if not company:
return
sales_invoice_gst_fields = [
dict(fieldname='billing_address_gstin', label='Billing Address GSTIN',
fieldtype='Data', insert_after='customer_address', read_only=1,
fetch_from='customer_address.gstin', print_hide=1, length=15),
dict(fieldname='customer_gstin', label='Customer GSTIN',
fieldtype='Data', insert_after='shipping_address_name',
fetch_from='shipping_address_name.gstin', print_hide=1, length=15),
dict(fieldname='place_of_supply', label='Place of Supply',
fieldtype='Data', insert_after='customer_gstin',
print_hide=1, read_only=1, length=50),
dict(fieldname='company_gstin', label='Company GSTIN',
fieldtype='Data', insert_after='company_address',
fetch_from='company_address.gstin', print_hide=1, read_only=1, length=15),
]
custom_fields = {
'Quotation': sales_invoice_gst_fields
}
create_custom_fields(custom_fields, update=True)

View File

@@ -547,6 +547,7 @@ def get_custom_fields():
'Journal Entry': journal_entry_fields, 'Journal Entry': journal_entry_fields,
'Sales Order': sales_invoice_gst_fields, 'Sales Order': sales_invoice_gst_fields,
'Tax Category': inter_state_gst_field, 'Tax Category': inter_state_gst_field,
'Quotation': sales_invoice_gst_fields,
'Item': [ 'Item': [
dict(fieldname='gst_hsn_code', label='HSN/SAC', dict(fieldname='gst_hsn_code', label='HSN/SAC',
fieldtype='Link', options='GST HSN Code', insert_after='item_group'), fieldtype='Link', options='GST HSN Code', insert_after='item_group'),

View File

@@ -178,7 +178,7 @@ def test_method():
def get_place_of_supply(party_details, doctype): def get_place_of_supply(party_details, doctype):
if not frappe.get_meta('Address').has_field('gst_state'): return if not frappe.get_meta('Address').has_field('gst_state'): return
if doctype in ("Sales Invoice", "Delivery Note", "Sales Order"): if doctype in ("Sales Invoice", "Delivery Note", "Sales Order", "Quotation"):
address_name = party_details.customer_address or party_details.shipping_address_name address_name = party_details.customer_address or party_details.shipping_address_name
elif doctype in ("Purchase Invoice", "Purchase Order", "Purchase Receipt"): elif doctype in ("Purchase Invoice", "Purchase Order", "Purchase Receipt"):
address_name = party_details.shipping_address or party_details.supplier_address address_name = party_details.shipping_address or party_details.supplier_address
@@ -204,7 +204,7 @@ def get_regional_address_details(party_details, doctype, company):
party_details.taxes = [] party_details.taxes = []
return party_details return party_details
if doctype in ("Sales Invoice", "Delivery Note", "Sales Order"): if doctype in ("Sales Invoice", "Delivery Note", "Sales Order", "Quotation"):
master_doctype = "Sales Taxes and Charges Template" master_doctype = "Sales Taxes and Charges Template"
tax_template_by_category = get_tax_template_based_on_category(master_doctype, company, party_details) tax_template_by_category = get_tax_template_based_on_category(master_doctype, company, party_details)
@@ -240,7 +240,7 @@ def update_party_details(party_details, doctype):
party_details.update(get_fetch_values(doctype, address_field, party_details.get(address_field))) party_details.update(get_fetch_values(doctype, address_field, party_details.get(address_field)))
def is_internal_transfer(party_details, doctype): def is_internal_transfer(party_details, doctype):
if doctype in ("Sales Invoice", "Delivery Note", "Sales Order"): if doctype in ("Sales Invoice", "Delivery Note", "Sales Order", "Quotation"):
destination_gstin = party_details.company_gstin destination_gstin = party_details.company_gstin
elif doctype in ("Purchase Invoice", "Purchase Order", "Purchase Receipt"): elif doctype in ("Purchase Invoice", "Purchase Order", "Purchase Receipt"):
destination_gstin = party_details.supplier_gstin destination_gstin = party_details.supplier_gstin

View File

@@ -31,6 +31,8 @@
"col_break98", "col_break98",
"shipping_address_name", "shipping_address_name",
"shipping_address", "shipping_address",
"company_address",
"company_address_display",
"customer_group", "customer_group",
"territory", "territory",
"currency_and_price_list", "currency_and_price_list",
@@ -116,7 +118,9 @@
{ {
"fieldname": "customer_section", "fieldname": "customer_section",
"fieldtype": "Section Break", "fieldtype": "Section Break",
"options": "fa fa-user" "options": "fa fa-user",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"allow_on_submit": 1, "allow_on_submit": 1,
@@ -126,7 +130,9 @@
"hidden": 1, "hidden": 1,
"label": "Title", "label": "Title",
"no_copy": 1, "no_copy": 1,
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "naming_series", "fieldname": "naming_series",
@@ -138,7 +144,9 @@
"options": "SAL-QTN-.YYYY.-", "options": "SAL-QTN-.YYYY.-",
"print_hide": 1, "print_hide": 1,
"reqd": 1, "reqd": 1,
"set_only_once": 1 "set_only_once": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"default": "Customer", "default": "Customer",
@@ -150,7 +158,9 @@
"oldfieldtype": "Select", "oldfieldtype": "Select",
"options": "DocType", "options": "DocType",
"print_hide": 1, "print_hide": 1,
"reqd": 1 "reqd": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"bold": 1, "bold": 1,
@@ -163,7 +173,9 @@
"oldfieldtype": "Link", "oldfieldtype": "Link",
"options": "quotation_to", "options": "quotation_to",
"print_hide": 1, "print_hide": 1,
"search_index": 1 "search_index": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"bold": 1, "bold": 1,
@@ -172,12 +184,16 @@
"hidden": 1, "hidden": 1,
"in_global_search": 1, "in_global_search": 1,
"label": "Customer Name", "label": "Customer Name",
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "column_break1", "fieldname": "column_break1",
"fieldtype": "Column Break", "fieldtype": "Column Break",
"oldfieldtype": "Column Break", "oldfieldtype": "Column Break",
"show_days": 1,
"show_seconds": 1,
"width": "50%" "width": "50%"
}, },
{ {
@@ -191,6 +207,8 @@
"options": "Quotation", "options": "Quotation",
"print_hide": 1, "print_hide": 1,
"read_only": 1, "read_only": 1,
"show_days": 1,
"show_seconds": 1,
"width": "150px" "width": "150px"
}, },
{ {
@@ -203,6 +221,8 @@
"print_hide": 1, "print_hide": 1,
"remember_last_selected_value": 1, "remember_last_selected_value": 1,
"reqd": 1, "reqd": 1,
"show_days": 1,
"show_seconds": 1,
"width": "150px" "width": "150px"
}, },
{ {
@@ -217,12 +237,16 @@
"oldfieldtype": "Date", "oldfieldtype": "Date",
"reqd": 1, "reqd": 1,
"search_index": 1, "search_index": 1,
"show_days": 1,
"show_seconds": 1,
"width": "100px" "width": "100px"
}, },
{ {
"fieldname": "valid_till", "fieldname": "valid_till",
"fieldtype": "Date", "fieldtype": "Date",
"label": "Valid Till" "label": "Valid Till",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"default": "Sales", "default": "Sales",
@@ -234,7 +258,9 @@
"oldfieldtype": "Select", "oldfieldtype": "Select",
"options": "\nSales\nMaintenance\nShopping Cart", "options": "\nSales\nMaintenance\nShopping Cart",
"print_hide": 1, "print_hide": 1,
"reqd": 1 "reqd": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"collapsible": 1, "collapsible": 1,
@@ -242,14 +268,18 @@
"fieldname": "contact_section", "fieldname": "contact_section",
"fieldtype": "Section Break", "fieldtype": "Section Break",
"label": "Address and Contact", "label": "Address and Contact",
"options": "fa fa-bullhorn" "options": "fa fa-bullhorn",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "customer_address", "fieldname": "customer_address",
"fieldtype": "Link", "fieldtype": "Link",
"label": "Customer Address", "label": "Customer Address",
"options": "Address", "options": "Address",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "address_display", "fieldname": "address_display",
@@ -257,7 +287,9 @@
"label": "Address", "label": "Address",
"oldfieldname": "customer_address", "oldfieldname": "customer_address",
"oldfieldtype": "Small Text", "oldfieldtype": "Small Text",
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "contact_person", "fieldname": "contact_person",
@@ -266,20 +298,26 @@
"oldfieldname": "contact_person", "oldfieldname": "contact_person",
"oldfieldtype": "Link", "oldfieldtype": "Link",
"options": "Contact", "options": "Contact",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "contact_display", "fieldname": "contact_display",
"fieldtype": "Small Text", "fieldtype": "Small Text",
"in_global_search": 1, "in_global_search": 1,
"label": "Contact", "label": "Contact",
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "contact_mobile", "fieldname": "contact_mobile",
"fieldtype": "Small Text", "fieldtype": "Small Text",
"label": "Mobile No", "label": "Mobile No",
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "contact_email", "fieldname": "contact_email",
@@ -288,12 +326,16 @@
"label": "Contact Email", "label": "Contact Email",
"options": "Email", "options": "Email",
"print_hide": 1, "print_hide": 1,
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"depends_on": "eval:doc.quotaion_to=='Customer' && doc.party_name", "depends_on": "eval:doc.quotaion_to=='Customer' && doc.party_name",
"fieldname": "col_break98", "fieldname": "col_break98",
"fieldtype": "Column Break", "fieldtype": "Column Break",
"show_days": 1,
"show_seconds": 1,
"width": "50%" "width": "50%"
}, },
{ {
@@ -301,14 +343,18 @@
"fieldtype": "Link", "fieldtype": "Link",
"label": "Shipping Address", "label": "Shipping Address",
"options": "Address", "options": "Address",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "shipping_address", "fieldname": "shipping_address",
"fieldtype": "Small Text", "fieldtype": "Small Text",
"label": "Shipping Address", "label": "Shipping Address",
"print_hide": 1, "print_hide": 1,
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"depends_on": "eval:doc.quotaion_to=='Customer' && doc.party_name", "depends_on": "eval:doc.quotaion_to=='Customer' && doc.party_name",
@@ -319,21 +365,27 @@
"oldfieldname": "customer_group", "oldfieldname": "customer_group",
"oldfieldtype": "Link", "oldfieldtype": "Link",
"options": "Customer Group", "options": "Customer Group",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "territory", "fieldname": "territory",
"fieldtype": "Link", "fieldtype": "Link",
"label": "Territory", "label": "Territory",
"options": "Territory", "options": "Territory",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"collapsible": 1, "collapsible": 1,
"fieldname": "currency_and_price_list", "fieldname": "currency_and_price_list",
"fieldtype": "Section Break", "fieldtype": "Section Break",
"label": "Currency and Price List", "label": "Currency and Price List",
"options": "fa fa-tag" "options": "fa fa-tag",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "currency", "fieldname": "currency",
@@ -344,6 +396,8 @@
"options": "Currency", "options": "Currency",
"print_hide": 1, "print_hide": 1,
"reqd": 1, "reqd": 1,
"show_days": 1,
"show_seconds": 1,
"width": "100px" "width": "100px"
}, },
{ {
@@ -356,11 +410,15 @@
"precision": "9", "precision": "9",
"print_hide": 1, "print_hide": 1,
"reqd": 1, "reqd": 1,
"show_days": 1,
"show_seconds": 1,
"width": "100px" "width": "100px"
}, },
{ {
"fieldname": "column_break2", "fieldname": "column_break2",
"fieldtype": "Column Break", "fieldtype": "Column Break",
"show_days": 1,
"show_seconds": 1,
"width": "50%" "width": "50%"
}, },
{ {
@@ -372,6 +430,8 @@
"options": "Price List", "options": "Price List",
"print_hide": 1, "print_hide": 1,
"reqd": 1, "reqd": 1,
"show_days": 1,
"show_seconds": 1,
"width": "100px" "width": "100px"
}, },
{ {
@@ -381,7 +441,9 @@
"options": "Currency", "options": "Currency",
"print_hide": 1, "print_hide": 1,
"read_only": 1, "read_only": 1,
"reqd": 1 "reqd": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"description": "Rate at which Price list currency is converted to company's base currency", "description": "Rate at which Price list currency is converted to company's base currency",
@@ -390,7 +452,9 @@
"label": "Price List Exchange Rate", "label": "Price List Exchange Rate",
"precision": "9", "precision": "9",
"print_hide": 1, "print_hide": 1,
"reqd": 1 "reqd": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"default": "0", "default": "0",
@@ -399,13 +463,17 @@
"label": "Ignore Pricing Rule", "label": "Ignore Pricing Rule",
"no_copy": 1, "no_copy": 1,
"permlevel": 1, "permlevel": 1,
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "items_section", "fieldname": "items_section",
"fieldtype": "Section Break", "fieldtype": "Section Break",
"oldfieldtype": "Section Break", "oldfieldtype": "Section Break",
"options": "fa fa-shopping-cart" "options": "fa fa-shopping-cart",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"allow_bulk_edit": 1, "allow_bulk_edit": 1,
@@ -416,29 +484,39 @@
"oldfieldtype": "Table", "oldfieldtype": "Table",
"options": "Quotation Item", "options": "Quotation Item",
"reqd": 1, "reqd": 1,
"show_days": 1,
"show_seconds": 1,
"width": "40px" "width": "40px"
}, },
{ {
"fieldname": "pricing_rule_details", "fieldname": "pricing_rule_details",
"fieldtype": "Section Break", "fieldtype": "Section Break",
"label": "Pricing Rules" "label": "Pricing Rules",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "pricing_rules", "fieldname": "pricing_rules",
"fieldtype": "Table", "fieldtype": "Table",
"label": "Pricing Rule Detail", "label": "Pricing Rule Detail",
"options": "Pricing Rule Detail", "options": "Pricing Rule Detail",
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "sec_break23", "fieldname": "sec_break23",
"fieldtype": "Section Break" "fieldtype": "Section Break",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "total_qty", "fieldname": "total_qty",
"fieldtype": "Float", "fieldtype": "Float",
"label": "Total Quantity", "label": "Total Quantity",
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "base_total", "fieldname": "base_total",
@@ -446,7 +524,9 @@
"label": "Total (Company Currency)", "label": "Total (Company Currency)",
"options": "Company:company:default_currency", "options": "Company:company:default_currency",
"print_hide": 1, "print_hide": 1,
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "base_net_total", "fieldname": "base_net_total",
@@ -457,18 +537,24 @@
"options": "Company:company:default_currency", "options": "Company:company:default_currency",
"print_hide": 1, "print_hide": 1,
"read_only": 1, "read_only": 1,
"show_days": 1,
"show_seconds": 1,
"width": "100px" "width": "100px"
}, },
{ {
"fieldname": "column_break_28", "fieldname": "column_break_28",
"fieldtype": "Column Break" "fieldtype": "Column Break",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "total", "fieldname": "total",
"fieldtype": "Currency", "fieldtype": "Currency",
"label": "Total", "label": "Total",
"options": "currency", "options": "currency",
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "net_total", "fieldname": "net_total",
@@ -476,32 +562,42 @@
"label": "Net Total", "label": "Net Total",
"options": "currency", "options": "currency",
"print_hide": 1, "print_hide": 1,
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "total_net_weight", "fieldname": "total_net_weight",
"fieldtype": "Float", "fieldtype": "Float",
"label": "Total Net Weight", "label": "Total Net Weight",
"print_hide": 1, "print_hide": 1,
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "taxes_section", "fieldname": "taxes_section",
"fieldtype": "Section Break", "fieldtype": "Section Break",
"label": "Taxes and Charges", "label": "Taxes and Charges",
"oldfieldtype": "Section Break", "oldfieldtype": "Section Break",
"options": "fa fa-money" "options": "fa fa-money",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "tax_category", "fieldname": "tax_category",
"fieldtype": "Link", "fieldtype": "Link",
"label": "Tax Category", "label": "Tax Category",
"options": "Tax Category", "options": "Tax Category",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "column_break_34", "fieldname": "column_break_34",
"fieldtype": "Column Break" "fieldtype": "Column Break",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "shipping_rule", "fieldname": "shipping_rule",
@@ -509,11 +605,15 @@
"label": "Shipping Rule", "label": "Shipping Rule",
"oldfieldtype": "Button", "oldfieldtype": "Button",
"options": "Shipping Rule", "options": "Shipping Rule",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "section_break_36", "fieldname": "section_break_36",
"fieldtype": "Section Break" "fieldtype": "Section Break",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "taxes_and_charges", "fieldname": "taxes_and_charges",
@@ -522,7 +622,9 @@
"oldfieldname": "charge", "oldfieldname": "charge",
"oldfieldtype": "Link", "oldfieldtype": "Link",
"options": "Sales Taxes and Charges Template", "options": "Sales Taxes and Charges Template",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "taxes", "fieldname": "taxes",
@@ -530,13 +632,17 @@
"label": "Sales Taxes and Charges", "label": "Sales Taxes and Charges",
"oldfieldname": "other_charges", "oldfieldname": "other_charges",
"oldfieldtype": "Table", "oldfieldtype": "Table",
"options": "Sales Taxes and Charges" "options": "Sales Taxes and Charges",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"collapsible": 1, "collapsible": 1,
"fieldname": "sec_tax_breakup", "fieldname": "sec_tax_breakup",
"fieldtype": "Section Break", "fieldtype": "Section Break",
"label": "Tax Breakup" "label": "Tax Breakup",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "other_charges_calculation", "fieldname": "other_charges_calculation",
@@ -545,11 +651,15 @@
"no_copy": 1, "no_copy": 1,
"oldfieldtype": "HTML", "oldfieldtype": "HTML",
"print_hide": 1, "print_hide": 1,
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "section_break_39", "fieldname": "section_break_39",
"fieldtype": "Section Break" "fieldtype": "Section Break",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "base_total_taxes_and_charges", "fieldname": "base_total_taxes_and_charges",
@@ -559,11 +669,15 @@
"oldfieldtype": "Currency", "oldfieldtype": "Currency",
"options": "Company:company:default_currency", "options": "Company:company:default_currency",
"print_hide": 1, "print_hide": 1,
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "column_break_42", "fieldname": "column_break_42",
"fieldtype": "Column Break" "fieldtype": "Column Break",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "total_taxes_and_charges", "fieldname": "total_taxes_and_charges",
@@ -571,26 +685,34 @@
"label": "Total Taxes and Charges", "label": "Total Taxes and Charges",
"options": "currency", "options": "currency",
"print_hide": 1, "print_hide": 1,
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"collapsible": 1, "collapsible": 1,
"collapsible_depends_on": "discount_amount", "collapsible_depends_on": "discount_amount",
"fieldname": "section_break_44", "fieldname": "section_break_44",
"fieldtype": "Section Break", "fieldtype": "Section Break",
"label": "Additional Discount and Coupon Code" "label": "Additional Discount and Coupon Code",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "coupon_code", "fieldname": "coupon_code",
"fieldtype": "Link", "fieldtype": "Link",
"label": "Coupon Code", "label": "Coupon Code",
"options": "Coupon Code" "options": "Coupon Code",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "referral_sales_partner", "fieldname": "referral_sales_partner",
"fieldtype": "Link", "fieldtype": "Link",
"label": "Referral Sales Partner", "label": "Referral Sales Partner",
"options": "Sales Partner" "options": "Sales Partner",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"default": "Grand Total", "default": "Grand Total",
@@ -598,7 +720,9 @@
"fieldtype": "Select", "fieldtype": "Select",
"label": "Apply Additional Discount On", "label": "Apply Additional Discount On",
"options": "\nGrand Total\nNet Total", "options": "\nGrand Total\nNet Total",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "base_discount_amount", "fieldname": "base_discount_amount",
@@ -606,31 +730,41 @@
"label": "Additional Discount Amount (Company Currency)", "label": "Additional Discount Amount (Company Currency)",
"options": "Company:company:default_currency", "options": "Company:company:default_currency",
"print_hide": 1, "print_hide": 1,
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "column_break_46", "fieldname": "column_break_46",
"fieldtype": "Column Break" "fieldtype": "Column Break",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "additional_discount_percentage", "fieldname": "additional_discount_percentage",
"fieldtype": "Float", "fieldtype": "Float",
"label": "Additional Discount Percentage", "label": "Additional Discount Percentage",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "discount_amount", "fieldname": "discount_amount",
"fieldtype": "Currency", "fieldtype": "Currency",
"label": "Additional Discount Amount", "label": "Additional Discount Amount",
"options": "currency", "options": "currency",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "totals", "fieldname": "totals",
"fieldtype": "Section Break", "fieldtype": "Section Break",
"oldfieldtype": "Section Break", "oldfieldtype": "Section Break",
"options": "fa fa-money", "options": "fa fa-money",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "base_grand_total", "fieldname": "base_grand_total",
@@ -641,6 +775,8 @@
"options": "Company:company:default_currency", "options": "Company:company:default_currency",
"print_hide": 1, "print_hide": 1,
"read_only": 1, "read_only": 1,
"show_days": 1,
"show_seconds": 1,
"width": "200px" "width": "200px"
}, },
{ {
@@ -650,7 +786,9 @@
"no_copy": 1, "no_copy": 1,
"options": "Company:company:default_currency", "options": "Company:company:default_currency",
"print_hide": 1, "print_hide": 1,
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"description": "In Words will be visible once you save the Quotation.", "description": "In Words will be visible once you save the Quotation.",
@@ -662,6 +800,8 @@
"oldfieldtype": "Data", "oldfieldtype": "Data",
"print_hide": 1, "print_hide": 1,
"read_only": 1, "read_only": 1,
"show_days": 1,
"show_seconds": 1,
"width": "200px" "width": "200px"
}, },
{ {
@@ -673,6 +813,8 @@
"options": "Company:company:default_currency", "options": "Company:company:default_currency",
"print_hide": 1, "print_hide": 1,
"read_only": 1, "read_only": 1,
"show_days": 1,
"show_seconds": 1,
"width": "200px" "width": "200px"
}, },
{ {
@@ -680,6 +822,8 @@
"fieldtype": "Column Break", "fieldtype": "Column Break",
"oldfieldtype": "Column Break", "oldfieldtype": "Column Break",
"print_hide": 1, "print_hide": 1,
"show_days": 1,
"show_seconds": 1,
"width": "50%" "width": "50%"
}, },
{ {
@@ -691,6 +835,8 @@
"oldfieldtype": "Currency", "oldfieldtype": "Currency",
"options": "currency", "options": "currency",
"read_only": 1, "read_only": 1,
"show_days": 1,
"show_seconds": 1,
"width": "200px" "width": "200px"
}, },
{ {
@@ -700,7 +846,9 @@
"no_copy": 1, "no_copy": 1,
"options": "currency", "options": "currency",
"print_hide": 1, "print_hide": 1,
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"bold": 1, "bold": 1,
@@ -711,6 +859,8 @@
"oldfieldtype": "Currency", "oldfieldtype": "Currency",
"options": "currency", "options": "currency",
"read_only": 1, "read_only": 1,
"show_days": 1,
"show_seconds": 1,
"width": "200px" "width": "200px"
}, },
{ {
@@ -722,19 +872,25 @@
"oldfieldtype": "Data", "oldfieldtype": "Data",
"print_hide": 1, "print_hide": 1,
"read_only": 1, "read_only": 1,
"show_days": 1,
"show_seconds": 1,
"width": "200px" "width": "200px"
}, },
{ {
"fieldname": "payment_schedule_section", "fieldname": "payment_schedule_section",
"fieldtype": "Section Break", "fieldtype": "Section Break",
"label": "Payment Terms" "label": "Payment Terms",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "payment_terms_template", "fieldname": "payment_terms_template",
"fieldtype": "Link", "fieldtype": "Link",
"label": "Payment Terms Template", "label": "Payment Terms Template",
"options": "Payment Terms Template", "options": "Payment Terms Template",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "payment_schedule", "fieldname": "payment_schedule",
@@ -742,7 +898,9 @@
"label": "Payment Schedule", "label": "Payment Schedule",
"no_copy": 1, "no_copy": 1,
"options": "Payment Schedule", "options": "Payment Schedule",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"collapsible": 1, "collapsible": 1,
@@ -751,7 +909,9 @@
"fieldtype": "Section Break", "fieldtype": "Section Break",
"label": "Terms and Conditions", "label": "Terms and Conditions",
"oldfieldtype": "Section Break", "oldfieldtype": "Section Break",
"options": "fa fa-legal" "options": "fa fa-legal",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "tc_name", "fieldname": "tc_name",
@@ -761,20 +921,26 @@
"oldfieldtype": "Link", "oldfieldtype": "Link",
"options": "Terms and Conditions", "options": "Terms and Conditions",
"print_hide": 1, "print_hide": 1,
"report_hide": 1 "report_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "terms", "fieldname": "terms",
"fieldtype": "Text Editor", "fieldtype": "Text Editor",
"label": "Term Details", "label": "Term Details",
"oldfieldname": "terms", "oldfieldname": "terms",
"oldfieldtype": "Text Editor" "oldfieldtype": "Text Editor",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"collapsible": 1, "collapsible": 1,
"fieldname": "print_settings", "fieldname": "print_settings",
"fieldtype": "Section Break", "fieldtype": "Section Break",
"label": "Print Settings" "label": "Print Settings",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"allow_on_submit": 1, "allow_on_submit": 1,
@@ -784,7 +950,9 @@
"oldfieldname": "letter_head", "oldfieldname": "letter_head",
"oldfieldtype": "Select", "oldfieldtype": "Select",
"options": "Letter Head", "options": "Letter Head",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"allow_on_submit": 1, "allow_on_submit": 1,
@@ -792,11 +960,15 @@
"fieldname": "group_same_items", "fieldname": "group_same_items",
"fieldtype": "Check", "fieldtype": "Check",
"label": "Group same items", "label": "Group same items",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "column_break_73", "fieldname": "column_break_73",
"fieldtype": "Column Break" "fieldtype": "Column Break",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"allow_on_submit": 1, "allow_on_submit": 1,
@@ -808,19 +980,25 @@
"oldfieldtype": "Link", "oldfieldtype": "Link",
"options": "Print Heading", "options": "Print Heading",
"print_hide": 1, "print_hide": 1,
"report_hide": 1 "report_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "language", "fieldname": "language",
"fieldtype": "Data", "fieldtype": "Data",
"label": "Print Language", "label": "Print Language",
"print_hide": 1, "print_hide": 1,
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "subscription_section", "fieldname": "subscription_section",
"fieldtype": "Section Break", "fieldtype": "Section Break",
"label": "Auto Repeat Section" "label": "Auto Repeat Section",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "auto_repeat", "fieldname": "auto_repeat",
@@ -829,14 +1007,18 @@
"no_copy": 1, "no_copy": 1,
"options": "Auto Repeat", "options": "Auto Repeat",
"print_hide": 1, "print_hide": 1,
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"allow_on_submit": 1, "allow_on_submit": 1,
"depends_on": "eval: doc.auto_repeat", "depends_on": "eval: doc.auto_repeat",
"fieldname": "update_auto_repeat_reference", "fieldname": "update_auto_repeat_reference",
"fieldtype": "Button", "fieldtype": "Button",
"label": "Update Auto Repeat Reference" "label": "Update Auto Repeat Reference",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"collapsible": 1, "collapsible": 1,
@@ -845,7 +1027,9 @@
"label": "More Information", "label": "More Information",
"oldfieldtype": "Section Break", "oldfieldtype": "Section Break",
"options": "fa fa-file-text", "options": "fa fa-file-text",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "campaign", "fieldname": "campaign",
@@ -854,7 +1038,9 @@
"oldfieldname": "campaign", "oldfieldname": "campaign",
"oldfieldtype": "Link", "oldfieldtype": "Link",
"options": "Campaign", "options": "Campaign",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "source", "fieldname": "source",
@@ -863,7 +1049,9 @@
"oldfieldname": "source", "oldfieldname": "source",
"oldfieldtype": "Select", "oldfieldtype": "Select",
"options": "Lead Source", "options": "Lead Source",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"allow_on_submit": 1, "allow_on_submit": 1,
@@ -874,13 +1062,17 @@
"no_copy": 1, "no_copy": 1,
"oldfieldname": "order_lost_reason", "oldfieldname": "order_lost_reason",
"oldfieldtype": "Small Text", "oldfieldtype": "Small Text",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "column_break4", "fieldname": "column_break4",
"fieldtype": "Column Break", "fieldtype": "Column Break",
"oldfieldtype": "Column Break", "oldfieldtype": "Column Break",
"print_hide": 1, "print_hide": 1,
"show_days": 1,
"show_seconds": 1,
"width": "50%" "width": "50%"
}, },
{ {
@@ -895,7 +1087,9 @@
"options": "Draft\nOpen\nReplied\nOrdered\nLost\nCancelled\nExpired", "options": "Draft\nOpen\nReplied\nOrdered\nLost\nCancelled\nExpired",
"print_hide": 1, "print_hide": 1,
"read_only": 1, "read_only": 1,
"reqd": 1 "reqd": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "enq_det", "fieldname": "enq_det",
@@ -905,13 +1099,17 @@
"oldfieldname": "enq_det", "oldfieldname": "enq_det",
"oldfieldtype": "Text", "oldfieldtype": "Text",
"print_hide": 1, "print_hide": 1,
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "supplier_quotation", "fieldname": "supplier_quotation",
"fieldtype": "Link", "fieldtype": "Link",
"label": "Supplier Quotation", "label": "Supplier Quotation",
"options": "Supplier Quotation" "options": "Supplier Quotation",
"show_days": 1,
"show_seconds": 1
}, },
{ {
"fieldname": "opportunity", "fieldname": "opportunity",
@@ -919,7 +1117,9 @@
"label": "Opportunity", "label": "Opportunity",
"options": "Opportunity", "options": "Opportunity",
"print_hide": 1, "print_hide": 1,
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"allow_on_submit": 1, "allow_on_submit": 1,
@@ -927,7 +1127,9 @@
"fieldtype": "Table MultiSelect", "fieldtype": "Table MultiSelect",
"label": "Lost Reasons", "label": "Lost Reasons",
"options": "Quotation Lost Reason Detail", "options": "Quotation Lost Reason Detail",
"read_only": 1 "read_only": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"depends_on": "packed_items", "depends_on": "packed_items",
@@ -935,7 +1137,9 @@
"fieldtype": "Table", "fieldtype": "Table",
"label": "Bundle Items", "label": "Bundle Items",
"options": "Packed Item", "options": "Packed Item",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
}, },
{ {
"collapsible": 1, "collapsible": 1,
@@ -945,14 +1149,32 @@
"fieldtype": "Section Break", "fieldtype": "Section Break",
"label": "Bundle Items", "label": "Bundle Items",
"options": "fa fa-suitcase", "options": "fa fa-suitcase",
"print_hide": 1 "print_hide": 1,
"show_days": 1,
"show_seconds": 1
},
{
"fieldname": "company_address",
"fieldtype": "Link",
"label": "Company Address Name",
"options": "Address",
"show_days": 1,
"show_seconds": 1
},
{
"fieldname": "company_address_display",
"fieldtype": "Small Text",
"label": "Company Address",
"read_only": 1,
"show_days": 1,
"show_seconds": 1
} }
], ],
"icon": "fa fa-shopping-cart", "icon": "fa fa-shopping-cart",
"idx": 82, "idx": 82,
"is_submittable": 1, "is_submittable": 1,
"links": [], "links": [],
"modified": "2021-11-30 01:33:21.106073", "modified": "2022-03-23 16:49:36.297403",
"modified_by": "Administrator", "modified_by": "Administrator",
"module": "Selling", "module": "Selling",
"name": "Quotation", "name": "Quotation",

View File

@@ -0,0 +1,3 @@
{% include "erpnext/regional/india/taxes.js" %}
erpnext.setup_auto_gst_taxation('Quotation');