mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-01 11:19:09 +00:00
fix: Error when no data is present in AR/AP reeport
(cherry picked from commit 7135a75e5e)
This commit is contained in:
committed by
mergify-bot
parent
12ad34b44a
commit
c84961be85
@@ -169,6 +169,8 @@ class ReceivablePayableReport(object):
|
|||||||
|
|
||||||
def append_subtotal_row(self, party):
|
def append_subtotal_row(self, party):
|
||||||
sub_total_row = self.total_row_map.get(party)
|
sub_total_row = self.total_row_map.get(party)
|
||||||
|
|
||||||
|
if sub_total_row:
|
||||||
self.data.append(sub_total_row)
|
self.data.append(sub_total_row)
|
||||||
self.data.append({})
|
self.data.append({})
|
||||||
self.update_sub_total_row(sub_total_row, 'Total')
|
self.update_sub_total_row(sub_total_row, 'Total')
|
||||||
@@ -232,6 +234,7 @@ class ReceivablePayableReport(object):
|
|||||||
|
|
||||||
if self.filters.get('group_by_party'):
|
if self.filters.get('group_by_party'):
|
||||||
self.append_subtotal_row(self.previous_party)
|
self.append_subtotal_row(self.previous_party)
|
||||||
|
if self.data:
|
||||||
self.data.append(self.total_row_map.get('Total'))
|
self.data.append(self.total_row_map.get('Total'))
|
||||||
|
|
||||||
def append_row(self, row):
|
def append_row(self, row):
|
||||||
|
|||||||
Reference in New Issue
Block a user