* src/GrampsDb/_ReadGedcom.py (parse_record): Do not add def_src
to person/family. Need to optimize the performance first. svn: r5782
This commit is contained in:
parent
046b55b81e
commit
d169d9c949
@ -9,6 +9,8 @@
|
|||||||
the constructor.
|
the constructor.
|
||||||
* src/GrampsDb/_GrampsBSDDB.py: Back to durable transactions, set
|
* src/GrampsDb/_GrampsBSDDB.py: Back to durable transactions, set
|
||||||
TXN_NOSYNC flag only on batch transactions.
|
TXN_NOSYNC flag only on batch transactions.
|
||||||
|
* src/GrampsDb/_ReadGedcom.py (parse_record): Do not add def_src
|
||||||
|
to person/family. Need to optimize the performance first.
|
||||||
|
|
||||||
2006-01-17 Martin Hawlisch <Martin.Hawlisch@gmx.de>
|
2006-01-17 Martin Hawlisch <Martin.Hawlisch@gmx.de>
|
||||||
* src/EventView.py (ui_definition): Add filter menu entry
|
* src/EventView.py (ui_definition): Add filter menu entry
|
||||||
|
@ -566,8 +566,8 @@ class GedcomParser:
|
|||||||
|
|
||||||
def parse_gedcom_file(self,use_trans=True):
|
def parse_gedcom_file(self,use_trans=True):
|
||||||
|
|
||||||
self.trans = self.db.transaction_begin()
|
self.trans = self.db.transaction_begin("",not use_trans)
|
||||||
self.trans.set_batch(not use_trans)
|
#self.trans.set_batch(not use_trans)
|
||||||
self.db.disable_signals()
|
self.db.disable_signals()
|
||||||
t = time.time()
|
t = time.time()
|
||||||
self.index = 0
|
self.index = 0
|
||||||
@ -715,10 +715,10 @@ class GedcomParser:
|
|||||||
if child:
|
if child:
|
||||||
child.add_address(self.addr)
|
child.add_address(self.addr)
|
||||||
self.db.commit_person(child, self.trans)
|
self.db.commit_person(child, self.trans)
|
||||||
if len(self.family.get_source_references()) == 0:
|
#if len(self.family.get_source_references()) == 0:
|
||||||
sref = RelLib.SourceRef()
|
# sref = RelLib.SourceRef()
|
||||||
sref.set_base_handle(self.def_src.get_handle())
|
# sref.set_base_handle(self.def_src.get_handle())
|
||||||
self.family.add_source_reference(sref)
|
# self.family.add_source_reference(sref)
|
||||||
self.db.commit_family(self.family, self.trans)
|
self.db.commit_family(self.family, self.trans)
|
||||||
del self.family
|
del self.family
|
||||||
elif matches[2] == "INDI":
|
elif matches[2] == "INDI":
|
||||||
@ -730,10 +730,10 @@ class GedcomParser:
|
|||||||
self.person = self.find_or_create_person(self.map_gid(gid))
|
self.person = self.find_or_create_person(self.map_gid(gid))
|
||||||
self.added[self.person.get_handle()] = 1
|
self.added[self.person.get_handle()] = 1
|
||||||
self.parse_individual()
|
self.parse_individual()
|
||||||
if len(self.person.get_source_references()) == 0:
|
#if len(self.person.get_source_references()) == 0:
|
||||||
sref = RelLib.SourceRef()
|
# sref = RelLib.SourceRef()
|
||||||
sref.set_base_handle(self.def_src.get_handle())
|
# sref.set_base_handle(self.def_src.get_handle())
|
||||||
self.person.add_source_reference(sref)
|
# self.person.add_source_reference(sref)
|
||||||
self.db.commit_person(self.person, self.trans)
|
self.db.commit_person(self.person, self.trans)
|
||||||
del self.person
|
del self.person
|
||||||
elif matches[2] in ["SUBM","SUBN","REPO"]:
|
elif matches[2] in ["SUBM","SUBN","REPO"]:
|
||||||
|
Loading…
Reference in New Issue
Block a user