From 8e9413829dfa4cb01e99448b3d9cf0551dd00f39 Mon Sep 17 00:00:00 2001 From: Anurag Mishra <32095923+Anurag810@users.noreply.github.com> Date: Thu, 16 May 2019 13:57:35 +0530 Subject: [PATCH] fix: variant item description based on attribute (#17627) * fix: variant item description based on attribute * fix: requested changes * style: removed print --- erpnext/controllers/item_variant.py | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) diff --git a/erpnext/controllers/item_variant.py b/erpnext/controllers/item_variant.py index 646f23879a9..31ae83a0ce2 100644 --- a/erpnext/controllers/item_variant.py +++ b/erpnext/controllers/item_variant.py @@ -287,19 +287,15 @@ def copy_attributes_to_variant(item, variant): variant.set(field.fieldname, item.get(field.fieldname)) variant.variant_of = item.name - if 'description' in allow_fields: - variant.has_variants = 0 - if not variant.description: - variant.description = "" - if item.variant_based_on=='Item Attribute': - if variant.attributes: - attributes_description = "" - for d in variant.attributes: - attributes_description += "