Fix import_as_dict to utilize user gramps_id prefixes (#626)
Issue #10622 Found when comparing dbs with large prefixes 'I%05d'; using database differences or import_merge addons.
This commit is contained in:
parent
21408ab9d2
commit
94bd8470d7
@ -138,6 +138,16 @@ def import_as_dict(filename, user, skp_imp_adds=True):
|
||||
db = make_database("sqlite")
|
||||
db.load(":memory:")
|
||||
db.set_feature("skip-import-additions", skp_imp_adds)
|
||||
db.set_prefixes(
|
||||
config.get('preferences.iprefix'),
|
||||
config.get('preferences.oprefix'),
|
||||
config.get('preferences.fprefix'),
|
||||
config.get('preferences.sprefix'),
|
||||
config.get('preferences.cprefix'),
|
||||
config.get('preferences.pprefix'),
|
||||
config.get('preferences.eprefix'),
|
||||
config.get('preferences.rprefix'),
|
||||
config.get('preferences.nprefix'))
|
||||
status = import_from_filename(db, filename, user)
|
||||
return db if status else None
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user