From ef78eb3454e91b927eaf4252ddb4eb3f1cdd31a1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Francisco=20Rold=C3=A1n?= Date: Mon, 21 Oct 2024 10:38:08 -0300 Subject: [PATCH] =?UTF-8?q?Nombre=20del=20Plan=20de=20suscripci=C3=B3n=20e?= =?UTF-8?q?n=20la=20Factura=20(#885)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * feat: subscription plan * feat: ocultar plan en impresion --- .../doctype/sales_invoice_item/sales_invoice_item.json | 10 +++++++++- erpnext/accounts/doctype/subscription/subscription.py | 1 + 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/erpnext/accounts/doctype/sales_invoice_item/sales_invoice_item.json b/erpnext/accounts/doctype/sales_invoice_item/sales_invoice_item.json index 65d348511d2c..aed43ec0d364 100644 --- a/erpnext/accounts/doctype/sales_invoice_item/sales_invoice_item.json +++ b/erpnext/accounts/doctype/sales_invoice_item/sales_invoice_item.json @@ -97,6 +97,7 @@ "so_detail", "sales_invoice_item", "subscription_plan", + "subscription_plan_name", "column_break_74", "delivery_note", "dn_detail", @@ -868,13 +869,20 @@ "fieldtype": "Link", "label": "Subscription Plan", "options": "Subscription Plan", + "print_hide": 1, + "read_only": 1 + }, + { + "fieldname": "subscription_plan_name", + "fieldtype": "Data", + "label": "Nombre del Plan de Suscripci\u00f3n", "read_only": 1 } ], "idx": 1, "istable": 1, "links": [], - "modified": "2024-10-03 16:39:41.672280", + "modified": "2024-10-21 09:41:57.759598", "modified_by": "Administrator", "module": "Accounts", "name": "Sales Invoice Item", diff --git a/erpnext/accounts/doctype/subscription/subscription.py b/erpnext/accounts/doctype/subscription/subscription.py index 347069d62698..60eb13570eb3 100644 --- a/erpnext/accounts/doctype/subscription/subscription.py +++ b/erpnext/accounts/doctype/subscription/subscription.py @@ -491,6 +491,7 @@ def get_items_from_plans(self, plans, prorate=0): if doctype == "Sales Invoice": item["subscription_plan"] = plan_doc.name + item["subscription_plan_name"] = plan_doc.name if deferred: item.update({