diff --git a/erpnext/accounts/doctype/subscription/subscription.py b/erpnext/accounts/doctype/subscription/subscription.py index 39f3d82d82f2..347069d62698 100644 --- a/erpnext/accounts/doctype/subscription/subscription.py +++ b/erpnext/accounts/doctype/subscription/subscription.py @@ -489,7 +489,8 @@ def get_items_from_plans(self, plans, prorate=0): item = {'item_code': item_code, 'qty': plan.qty, 'rate': get_plan_rate(plan.plan, plan.qty, party, self.current_invoice_start, self.current_invoice_end, prorate_factor, doctype, company), 'cost_center': plan_doc.cost_center} - item["subscription_plan"] = plan_doc.name + if doctype == "Sales Invoice": + item["subscription_plan"] = plan_doc.name if deferred: item.update({