From c2282eaf083b8fa7802bdeaffc1889b761101d8e Mon Sep 17 00:00:00 2001 From: Sudharsanan11 Date: Wed, 11 Feb 2026 23:45:38 +0530 Subject: [PATCH] fix(manufacturing): add sales order fields in subassembly child table --- .../production_plan_sub_assembly_item.json | 24 ++++++++++++++++++- .../production_plan_sub_assembly_item.py | 2 ++ 2 files changed, 25 insertions(+), 1 deletion(-) diff --git a/erpnext/manufacturing/doctype/production_plan_sub_assembly_item/production_plan_sub_assembly_item.json b/erpnext/manufacturing/doctype/production_plan_sub_assembly_item/production_plan_sub_assembly_item.json index 5fbb83ae579..26d65116396 100644 --- a/erpnext/manufacturing/doctype/production_plan_sub_assembly_item/production_plan_sub_assembly_item.json +++ b/erpnext/manufacturing/doctype/production_plan_sub_assembly_item/production_plan_sub_assembly_item.json @@ -21,6 +21,9 @@ "subcontracting_section", "supplier", "purchase_order", + "column_break_oqry", + "sales_order", + "sales_order_item", "work_order_details_section", "production_plan_item", "wo_produced_qty", @@ -240,13 +243,32 @@ "label": "Ordered Qty", "no_copy": 1, "read_only": 1 + }, + { + "fieldname": "column_break_oqry", + "fieldtype": "Column Break" + }, + { + "fieldname": "sales_order", + "fieldtype": "Link", + "label": "Sales Order", + "options": "Sales Order", + "read_only": 1 + }, + { + "fieldname": "sales_order_item", + "fieldtype": "Data", + "hidden": 1, + "label": "Sales Order Item", + "no_copy": 1, + "print_hide": 1 } ], "grid_page_length": 50, "index_web_pages_for_search": 1, "istable": 1, "links": [], - "modified": "2025-11-03 14:33:50.677717", + "modified": "2026-02-11 13:00:09.092676", "modified_by": "Administrator", "module": "Manufacturing", "name": "Production Plan Sub Assembly Item", diff --git a/erpnext/manufacturing/doctype/production_plan_sub_assembly_item/production_plan_sub_assembly_item.py b/erpnext/manufacturing/doctype/production_plan_sub_assembly_item/production_plan_sub_assembly_item.py index 5cdcc6cf118..72ae9612176 100644 --- a/erpnext/manufacturing/doctype/production_plan_sub_assembly_item/production_plan_sub_assembly_item.py +++ b/erpnext/manufacturing/doctype/production_plan_sub_assembly_item/production_plan_sub_assembly_item.py @@ -34,6 +34,8 @@ class ProductionPlanSubAssemblyItem(Document): qty: DF.Float received_qty: DF.Float required_qty: DF.Float + sales_order: DF.Link | None + sales_order_item: DF.Data | None schedule_date: DF.Datetime | None stock_reserved_qty: DF.Float stock_uom: DF.Link | None