4011: "reports" should have a "no private information" button

This commit is contained in:
Paul Franklin 2014-07-26 09:52:31 -07:00
parent 7f8b3e538c
commit 0e805c1f5c

View File

@ -4,7 +4,7 @@
#
# Copyright (C) 2008-2011 Reinhard Müller
# Copyright (C) 2010 Jakim Friant
# Copyright (C) 2013 Paul Franklin
# Copyright (C) 2013-2014 Paul Franklin
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@ -58,10 +58,18 @@ from gramps.gen.constfunc import cuni
class RecordsReport(Report):
def __init__(self, database, options, user):
"""
This report needs the following parameters (class variables)
that come in the options class.
incl_private - Whether to include private data
"""
Report.__init__(self, database, options, user)
menu = options.menu
stdoptions.run_private_data_option(self, menu)
self.filter_option = menu.get_option_by_name('filter')
self.filter = self.filter_option.get_filter()
@ -193,6 +201,8 @@ class RecordsReportOptions(MenuReportOptions):
footer = StringOption(_("Footer text"), "")
menu.add_option(category_name, "footer", footer)
stdoptions.add_private_data_option(menu, category_name)
stdoptions.add_localization_option(menu, category_name)
for (text, varname, default) in RECORDS: