reconcile: Fix edge case in helper when only one unreconciled transaction.
This commit is contained in:
parent
21852845c0
commit
6b1ce7d73a
1 changed files with 3 additions and 2 deletions
|
@ -17,6 +17,7 @@ Not implemented:
|
|||
import argparse
|
||||
from dateutil.relativedelta import relativedelta
|
||||
import datetime
|
||||
import decimal
|
||||
import io
|
||||
import tempfile
|
||||
import textwrap
|
||||
|
@ -175,9 +176,9 @@ for desc, query in QUERIES.items():
|
|||
print(f'{desc}\n See {grep_output_file.name}')
|
||||
grep_rows = [format_record_for_grep(row, homedir) for row in rrows]
|
||||
print(tabulate(grep_rows), file=grep_output_file)
|
||||
elif len(rrows) == 1:
|
||||
elif len(rrows) == 1 and isinstance(rrows[0][0], decimal.Decimal):
|
||||
result = rrows[0][0]
|
||||
print(f'{desc:<55} {result:>11,.2f}')
|
||||
print(f'{desc:<55} {result:11,.2f}')
|
||||
else:
|
||||
headers = [c[0].capitalize() for c in rtypes]
|
||||
print(desc)
|
||||
|
|
Loading…
Reference in a new issue