mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-02 19:59:12 +00:00
fix: Production Plan: load document defaults for plan items & remove name column from listview (#26584) (#27184)
(cherry picked from commit 69d88a9212)
Co-authored-by: Richard Case <64409021+casesolved-co-uk@users.noreply.github.com>
This commit is contained in:
@@ -213,7 +213,6 @@ class ProductionPlan(Document):
|
|||||||
})
|
})
|
||||||
|
|
||||||
pi = self.append('po_items', {
|
pi = self.append('po_items', {
|
||||||
'include_exploded_items': 1,
|
|
||||||
'warehouse': data.warehouse,
|
'warehouse': data.warehouse,
|
||||||
'item_code': data.item_code,
|
'item_code': data.item_code,
|
||||||
'description': data.description or item_details.description,
|
'description': data.description or item_details.description,
|
||||||
@@ -224,6 +223,7 @@ class ProductionPlan(Document):
|
|||||||
'planned_start_date': now_datetime(),
|
'planned_start_date': now_datetime(),
|
||||||
'product_bundle_item': data.parent_item
|
'product_bundle_item': data.parent_item
|
||||||
})
|
})
|
||||||
|
pi._set_defaults()
|
||||||
|
|
||||||
if self.get_items_from == "Sales Order":
|
if self.get_items_from == "Sales Order":
|
||||||
pi.sales_order = data.parent
|
pi.sales_order = data.parent
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
frappe.listview_settings['Production Plan'] = {
|
frappe.listview_settings['Production Plan'] = {
|
||||||
|
hide_name_column: true,
|
||||||
add_fields: ["status"],
|
add_fields: ["status"],
|
||||||
filters: [["status", "!=", "Closed"]],
|
filters: [["status", "!=", "Closed"]],
|
||||||
get_indicator: function (doc) {
|
get_indicator: function (doc) {
|
||||||
|
|||||||
Reference in New Issue
Block a user