5895: "name format" option in descendant and ancestortree reports
This commit is contained in:
@ -670,6 +670,7 @@ class AncestorTree(Report):
|
|||||||
|
|
||||||
lang = options.menu.get_option_by_name('trans').get_value()
|
lang = options.menu.get_option_by_name('trans').get_value()
|
||||||
self._locale = self.set_locale(lang)
|
self._locale = self.set_locale(lang)
|
||||||
|
stdoptions.run_name_format_option(self, options.menu)
|
||||||
self._nd = self._name_display
|
self._nd = self._name_display
|
||||||
|
|
||||||
def begin_report(self):
|
def begin_report(self):
|
||||||
@ -895,6 +896,8 @@ class AncestorTreeOptions(MenuReportOptions):
|
|||||||
pid.set_help(_("The center person for the tree"))
|
pid.set_help(_("The center person for the tree"))
|
||||||
menu.add_option(category_name, "pid", pid)
|
menu.add_option(category_name, "pid", pid)
|
||||||
|
|
||||||
|
stdoptions.add_name_format_option(menu, category_name)
|
||||||
|
|
||||||
self.max_gen = NumberOption(_("Generations"), 10, 1, 50)
|
self.max_gen = NumberOption(_("Generations"), 10, 1, 50)
|
||||||
self.max_gen.set_help(_("The number of generations to include "
|
self.max_gen.set_help(_("The number of generations to include "
|
||||||
"in the tree"))
|
"in the tree"))
|
||||||
|
@ -1290,6 +1290,7 @@ class DescendTree(Report):
|
|||||||
|
|
||||||
lang = options.menu.get_option_by_name('trans').get_value()
|
lang = options.menu.get_option_by_name('trans').get_value()
|
||||||
self._locale = self.set_locale(lang)
|
self._locale = self.set_locale(lang)
|
||||||
|
stdoptions.run_name_format_option(self, options.menu)
|
||||||
self._nd = self._name_display
|
self._nd = self._name_display
|
||||||
|
|
||||||
def begin_report(self):
|
def begin_report(self):
|
||||||
@ -1508,6 +1509,8 @@ class DescendTreeOptions(MenuReportOptions):
|
|||||||
self.__pid.set_help(_("The main family for the report"))
|
self.__pid.set_help(_("The main family for the report"))
|
||||||
menu.add_option(category_name, "pid", self.__pid)
|
menu.add_option(category_name, "pid", self.__pid)
|
||||||
|
|
||||||
|
stdoptions.add_name_format_option(menu, category_name)
|
||||||
|
|
||||||
self.showparents = BooleanOption(
|
self.showparents = BooleanOption(
|
||||||
_('Start with the parent(s) of the selected first'),
|
_('Start with the parent(s) of the selected first'),
|
||||||
False)
|
False)
|
||||||
|
Reference in New Issue
Block a user