From 0709ed56063eeb726024b44dd4d902caef33a954 Mon Sep 17 00:00:00 2001 From: Doug Blank Date: Fri, 18 Apr 2008 03:35:38 +0000 Subject: [PATCH] removed the need for quickviews to have an active person set---most reports don't have anything to do with active person, but there may be issues somewhere that need to be taken care of. svn: r10580 --- src/QuickReports.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/QuickReports.py b/src/QuickReports.py index b54689355..dfaa9f11e 100644 --- a/src/QuickReports.py +++ b/src/QuickReports.py @@ -152,8 +152,8 @@ def run_quick_report_by_name_direct(report_name, database, document, handle): def run_report(dbstate, uistate, category, handle, func, **kwargs): from docgen import TextBufDoc from Simple import make_basic_stylesheet - - if dbstate.active and handle: + + if handle: d = TextBufDoc(make_basic_stylesheet(), None, None) d.dbstate = dbstate d.uistate = uistate @@ -181,3 +181,7 @@ def run_report(dbstate, uistate, category, handle, func, **kwargs): retval = func(dbstate.db, d, obj, **kwargs) d.close() return retval + else: + print "QuickView Error: failed to run report: no obj" + else: + print "QuickView Error: handle is not set"