[minor] fixed AttributeError: 'GrossProfitGenerator' object has no attribute 'grouped_data' (#11195)

This commit is contained in:
Makarand Bauskar 2017-10-16 11:27:22 +05:30 committed by Nabin Hait
parent d3214fed57
commit 80f333950b

View File

@ -107,6 +107,8 @@ class GrossProfitGenerator(object):
def process(self):
self.grouped = {}
self.grouped_data = []
for row in self.si_list:
if self.skip_row(row, self.product_bundles):
continue
@ -150,7 +152,6 @@ class GrossProfitGenerator(object):
def get_average_rate_based_on_group_by(self):
# sum buying / selling totals for group
self.grouped_data = []
for key in self.grouped.keys():
if self.filters.get("group_by") != "Invoice":
for i, row in enumerate(self.grouped[key]):