From 260162db1bd4fc66a82b38fb92e4bffae9580ee8 Mon Sep 17 00:00:00 2001
From: Rushabh Mehta %(head)s: %(body)s %(head)s: """ +\
+ "".join(map(lambda b: " %s [" + \
k.capitalize() + \
"]
- """
+ return """""" + \
- args['body'] + \
- """\
-
-
- """)
-
- body_rows.append("""" \
- + r + """\
-
- ")
-
- table_body = "" + "".join(body_rows) + ""
-
- table_head = """\
-
- """
-
- return """" \
- + args['head'] + """\
-
- " \
- + table_head \
- + table_body \
- + "
"
currency_amount_str = "%s %s"
@@ -669,50 +639,33 @@ class DocType:
new_section = False
+ def set_new_section(new_section):
+ if not new_section:
+ table_list.append("No Updates For:
")
+ new_section = True
+ return new_section
+
for k in bd_keys:
if self.doc.fields[k]:
if k in result:
if not body_dict[k].get('value') and not new_section:
- if len(table_list) % 2 != 0:
- table_list.append("")
- table_list.append("
")
- table_list.append("
")
- new_section = True
+ new_section = set_new_section(new_section)
table_list.append(body_dict[k]['table'])
elif k in ['collections', 'payments']:
+ new_section = set_new_section(new_section)
table_list.append(\
- "
Missing: Account of type 'Bank or Cash'\
-
[" + \
"Bank Balance" + \
"]
Alert: GL Entry not found for Account of type 'Bank or Cash'\
-
%s
-%s
-%s
-