Fix bug that wasn't taking account of the fact that event references in Person and Family have attributes which themselves can have Citations.
* In Person, add event_ref_list to get_citation_child_list (therefore it is no longer needed in get_handle_referents) * Similarly in Family, add event_ref_list to get_citation_child_list * Enhance upgrade to add upgrade of event_ref_list for person and family * Add has_citation_reference, replace_citation_references and remove_citation_references to EventRef * Change name of remove_citation_refs to remove_citation_references to be consistent with has_citation_reference (singular) and replace_citation_references Fix editcitation because it was displaying the wrong privacy button for sources. Also remove FIXME for editcitation for db signal connect, because comment explains why it is not needed. svn: r18469
This commit is contained in:
@@ -1022,7 +1022,7 @@ class CheckIntegrity(object):
|
||||
if item[0] == 'Citation' and
|
||||
item[1] not in known_handles ]
|
||||
if bad_handles:
|
||||
person.remove_citation_refs(bad_handles)
|
||||
person.remove_citation_references(bad_handles)
|
||||
self.db.commit_person(person,self.trans)
|
||||
new_bad_handles = [handle for handle in bad_handles if handle
|
||||
not in self.invalid_citation_references]
|
||||
@@ -1038,7 +1038,7 @@ class CheckIntegrity(object):
|
||||
if item[0] == 'Citation' and
|
||||
item[1] not in known_handles ]
|
||||
if bad_handles:
|
||||
family.remove_citation_refs(bad_handles)
|
||||
family.remove_citation_references(bad_handles)
|
||||
self.db.commit_family(family, self.trans)
|
||||
new_bad_handles = [handle for handle in bad_handles if handle
|
||||
not in self.invalid_citation_references]
|
||||
@@ -1054,7 +1054,7 @@ class CheckIntegrity(object):
|
||||
if item[0] == 'Citation' and
|
||||
item[1] not in known_handles ]
|
||||
if bad_handles:
|
||||
place.remove_citation_refs(bad_handles)
|
||||
place.remove_citation_references(bad_handles)
|
||||
self.db.commit_place(place,self.trans)
|
||||
new_bad_handles = [handle for handle in bad_handles if handle
|
||||
not in self.invalid_citation_references]
|
||||
@@ -1070,7 +1070,7 @@ class CheckIntegrity(object):
|
||||
if item[0] == 'Citation' and
|
||||
item[1] not in known_handles ]
|
||||
if bad_handles:
|
||||
repo.remove_citation_refs(bad_handles)
|
||||
repo.remove_citation_references(bad_handles)
|
||||
self.db.commit_repository(repo, self.trans)
|
||||
new_bad_handles = [handle for handle in bad_handles if handle
|
||||
not in self.invalid_citation_references]
|
||||
@@ -1087,7 +1087,7 @@ class CheckIntegrity(object):
|
||||
if item[0] == 'Citation' and
|
||||
item[1] not in known_handles ]
|
||||
if bad_handles:
|
||||
citation.remove_citation_refs(bad_handles)
|
||||
citation.remove_citation_references(bad_handles)
|
||||
self.db.commit_citation(citation, self.trans)
|
||||
new_bad_handles = [handle for handle in bad_handles if handle
|
||||
not in self.invalid_citation_references]
|
||||
@@ -1103,7 +1103,7 @@ class CheckIntegrity(object):
|
||||
if item[0] == 'Citation' and
|
||||
item[1] not in known_handles ]
|
||||
if bad_handles:
|
||||
obj.remove_citation_refs(bad_handles)
|
||||
obj.remove_citation_references(bad_handles)
|
||||
self.db.commit_media_object(obj, self.trans)
|
||||
new_bad_handles = [handle for handle in bad_handles if handle
|
||||
not in self.invalid_citation_references]
|
||||
@@ -1119,7 +1119,7 @@ class CheckIntegrity(object):
|
||||
if item[0] == 'Citation' and
|
||||
item[1] not in known_handles ]
|
||||
if bad_handles:
|
||||
event.remove_citation_refs(bad_handles)
|
||||
event.remove_citation_references(bad_handles)
|
||||
self.db.commit_event(event, self.trans)
|
||||
new_bad_handles = [handle for handle in bad_handles if handle
|
||||
not in self.invalid_citation_references]
|
||||
|
Reference in New Issue
Block a user