mirror of
https://github.com/frappe/erpnext.git
synced 2026-04-21 07:38:29 +00:00
feat: default print format for Request for Quotation
(cherry picked from commit 2af0d9cf6c)
This commit is contained in:
@@ -9,8 +9,6 @@
|
|||||||
"field_order": [
|
"field_order": [
|
||||||
"naming_series",
|
"naming_series",
|
||||||
"company",
|
"company",
|
||||||
"billing_address",
|
|
||||||
"billing_address_display",
|
|
||||||
"vendor",
|
"vendor",
|
||||||
"column_break1",
|
"column_break1",
|
||||||
"transaction_date",
|
"transaction_date",
|
||||||
@@ -43,7 +41,13 @@
|
|||||||
"select_print_heading",
|
"select_print_heading",
|
||||||
"letter_head",
|
"letter_head",
|
||||||
"more_info",
|
"more_info",
|
||||||
"opportunity"
|
"opportunity",
|
||||||
|
"address_and_contact_tab",
|
||||||
|
"billing_address",
|
||||||
|
"billing_address_display",
|
||||||
|
"column_break_czul",
|
||||||
|
"shipping_address",
|
||||||
|
"shipping_address_display"
|
||||||
],
|
],
|
||||||
"fields": [
|
"fields": [
|
||||||
{
|
{
|
||||||
@@ -346,6 +350,27 @@
|
|||||||
"fieldtype": "Check",
|
"fieldtype": "Check",
|
||||||
"hidden": 1,
|
"hidden": 1,
|
||||||
"label": "Use HTML"
|
"label": "Use HTML"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"fieldname": "address_and_contact_tab",
|
||||||
|
"fieldtype": "Tab Break",
|
||||||
|
"label": "Address & Contact"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"fieldname": "column_break_czul",
|
||||||
|
"fieldtype": "Column Break"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"fieldname": "shipping_address",
|
||||||
|
"fieldtype": "Link",
|
||||||
|
"label": "Company Shipping Address",
|
||||||
|
"options": "Address"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"fieldname": "shipping_address_display",
|
||||||
|
"fieldtype": "Text Editor",
|
||||||
|
"label": "Shipping Address Details",
|
||||||
|
"read_only": 1
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"grid_page_length": 50,
|
"grid_page_length": 50,
|
||||||
@@ -353,7 +378,7 @@
|
|||||||
"index_web_pages_for_search": 1,
|
"index_web_pages_for_search": 1,
|
||||||
"is_submittable": 1,
|
"is_submittable": 1,
|
||||||
"links": [],
|
"links": [],
|
||||||
"modified": "2026-03-09 17:15:29.774614",
|
"modified": "2026-03-19 15:27:56.730649",
|
||||||
"modified_by": "Administrator",
|
"modified_by": "Administrator",
|
||||||
"module": "Buying",
|
"module": "Buying",
|
||||||
"name": "Request for Quotation",
|
"name": "Request for Quotation",
|
||||||
|
|||||||
@@ -56,6 +56,8 @@ class RequestforQuotation(BuyingController):
|
|||||||
select_print_heading: DF.Link | None
|
select_print_heading: DF.Link | None
|
||||||
send_attached_files: DF.Check
|
send_attached_files: DF.Check
|
||||||
send_document_print: DF.Check
|
send_document_print: DF.Check
|
||||||
|
shipping_address: DF.Link | None
|
||||||
|
shipping_address_display: DF.TextEditor | None
|
||||||
status: DF.Literal["", "Draft", "Submitted", "Cancelled"]
|
status: DF.Literal["", "Draft", "Submitted", "Cancelled"]
|
||||||
subject: DF.Data
|
subject: DF.Data
|
||||||
suppliers: DF.Table[RequestforQuotationSupplier]
|
suppliers: DF.Table[RequestforQuotationSupplier]
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@@ -4324,6 +4324,8 @@ def get_missing_company_details(doctype, docname):
|
|||||||
company = frappe.db.get_value(doctype, docname, "company")
|
company = frappe.db.get_value(doctype, docname, "company")
|
||||||
if doctype in ["Purchase Order", "Purchase Invoice"]:
|
if doctype in ["Purchase Order", "Purchase Invoice"]:
|
||||||
company_address = frappe.db.get_value(doctype, docname, "billing_address")
|
company_address = frappe.db.get_value(doctype, docname, "billing_address")
|
||||||
|
elif doctype in ["Request for Quotation"]:
|
||||||
|
company_address = frappe.db.get_value(doctype, docname, "shipping_address")
|
||||||
else:
|
else:
|
||||||
company_address = frappe.db.get_value(doctype, docname, "company_address")
|
company_address = frappe.db.get_value(doctype, docname, "company_address")
|
||||||
|
|
||||||
@@ -4423,6 +4425,7 @@ def update_doc_company_address(current_doctype, docname, company_address, detail
|
|||||||
"Sales Invoice": ("company_address", "company_address_display"),
|
"Sales Invoice": ("company_address", "company_address_display"),
|
||||||
"Delivery Note": ("company_address", "company_address_display"),
|
"Delivery Note": ("company_address", "company_address_display"),
|
||||||
"POS Invoice": ("company_address", "company_address_display"),
|
"POS Invoice": ("company_address", "company_address_display"),
|
||||||
|
"Request for Quotation": ("shipping_address", "shipping_address_display"),
|
||||||
}
|
}
|
||||||
|
|
||||||
address_field, display_field = address_field_map.get(
|
address_field, display_field = address_field_map.get(
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ const doctype_list = [
|
|||||||
"Purchase Order",
|
"Purchase Order",
|
||||||
"Purchase Invoice",
|
"Purchase Invoice",
|
||||||
"POS Invoice",
|
"POS Invoice",
|
||||||
|
"Request for Quotation",
|
||||||
];
|
];
|
||||||
const allowed_print_formats = [
|
const allowed_print_formats = [
|
||||||
"Sales Order Standard",
|
"Sales Order Standard",
|
||||||
@@ -19,6 +20,7 @@ const allowed_print_formats = [
|
|||||||
"Purchase Invoice with Item Image",
|
"Purchase Invoice with Item Image",
|
||||||
"POS Invoice Standard",
|
"POS Invoice Standard",
|
||||||
"POS Invoice with Item Image",
|
"POS Invoice with Item Image",
|
||||||
|
"Request for Quotation with Item Image",
|
||||||
];
|
];
|
||||||
const allowed_letterheads = ["Company Letterhead", "Company Letterhead - Grey"];
|
const allowed_letterheads = ["Company Letterhead", "Company Letterhead - Grey"];
|
||||||
|
|
||||||
|
|||||||
@@ -310,6 +310,7 @@ def set_default_print_formats():
|
|||||||
"Purchase Order": "Purchase Order with Item Image",
|
"Purchase Order": "Purchase Order with Item Image",
|
||||||
"Purchase Invoice": "Purchase Invoice with Item Image",
|
"Purchase Invoice": "Purchase Invoice with Item Image",
|
||||||
"POS Invoice": "POS Invoice with Item Image",
|
"POS Invoice": "POS Invoice with Item Image",
|
||||||
|
"Request for Quotation": "Request for Quotation with Item Image",
|
||||||
}
|
}
|
||||||
|
|
||||||
for doctype, print_format in default_map.items():
|
for doctype, print_format in default_map.items():
|
||||||
|
|||||||
Reference in New Issue
Block a user