From e803d84b93a493d60fc7f2f41fcd3b3e437cffdc Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Fri, 24 Jan 2014 18:55:34 +0530 Subject: [PATCH] Minor fix in query report and doc --- webnotes/model/doc.py | 3 +-- webnotes/widgets/query_report.py | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/webnotes/model/doc.py b/webnotes/model/doc.py index b8d0a7dc80..a0b1e81640 100755 --- a/webnotes/model/doc.py +++ b/webnotes/model/doc.py @@ -348,8 +348,7 @@ class Document: self.fields[f] = self._validate_link(link_list, f) if old_val and not self.fields[f]: - s = link_list[f][1] + ': ' + old_val - err_list.append(s) + err_list.append("{}: {}".format(link_list[f][1], old_val)) return err_list diff --git a/webnotes/widgets/query_report.py b/webnotes/widgets/query_report.py index 7e29bfa463..93f965d3bd 100644 --- a/webnotes/widgets/query_report.py +++ b/webnotes/widgets/query_report.py @@ -52,7 +52,7 @@ def get_script(report_name): return script @webnotes.whitelist() -def run(report_name, filters=None): +def run(report_name, filters=()): from webnotes.plugins import get_code_and_execute report = webnotes.doc("Report", report_name)