Added fields to Person to reduce queries; should be able to add/edit people and names tomorrow

svn: r13934
This commit is contained in:
Doug Blank
2009-12-29 03:22:03 +00:00
parent 7f2174b225
commit 42ed2c3295
9 changed files with 138 additions and 219 deletions

View File

@@ -49,7 +49,7 @@ log = logging.getLogger(".ExportDjango")
#
#------------------------------------------------------------------------
import ExportOptions
from Utils import create_id
from Utils import create_id, probably_alive
import const
import gen.lib
@@ -95,7 +95,10 @@ def export_all(database, filename, option_box=None, callback=None):
if step == 0:
dji.add_person(data)
elif step == 1:
dji.add_person_detail(data)
djperson = dji.add_person_detail(data)
person = database.get_person_from_handle(person_handle)
djperson.probably_alive = probably_alive(person, database)
djperson.save()
count += 1
callback(100 * count/total)