From beec9a1e5b02a18ff62226df7ab261be4898dfc5 Mon Sep 17 00:00:00 2001 From: Doug Blank Date: Mon, 19 Apr 2010 02:45:26 +0000 Subject: [PATCH] 3868: NarWeb Associations should be a link to the person's webpage svn: r15224 --- src/plugins/webreport/NarrativeWeb.py | 21 ++++++++++++++++----- 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/src/plugins/webreport/NarrativeWeb.py b/src/plugins/webreport/NarrativeWeb.py index 54fde03d7..baed381e8 100644 --- a/src/plugins/webreport/NarrativeWeb.py +++ b/src/plugins/webreport/NarrativeWeb.py @@ -3912,9 +3912,11 @@ class IndividualPage(BasePage): thead += trow assoc_row = [ + (_("Person"), 'Person'), (_('Relationship'), 'Relationship'), + (NHEAD, 'Notes'), (SHEAD, 'Sources'), - (NHEAD, 'Notes') ] + ] trow.extend( Html("th", label, class_="Column" + colclass, inline=True) @@ -3924,14 +3926,23 @@ class IndividualPage(BasePage): table += tbody for person_ref in assoclist: - + if person_ref.ref not in self.report.person_handles: + continue trow = Html("tr") tbody += trow + person = self.report.database.get_person_from_handle(person_ref.ref) + url = self.report.build_url_fname_html(person.handle, "ppl", True) + person_name = self.get_name(person) + person_link = Html("a", person_name, href=url, title=html_escape(person_name)) + index = 0 - for data in [person_ref.get_relation(), - self.get_citation_links(person_ref.get_source_references()), - self.dump_notes(person_ref.get_note_list())]: + for data in [ + person_link, + person_ref.get_relation(), + self.dump_notes(person_ref.get_note_list()), + self.get_citation_links(person_ref.get_source_references()), + ]: # get colclass from assoc_row colclass = assoc_row[index][1]