LDS uses AutoComp for marriages now
svn: r774
This commit is contained in:
parent
1fe4d3f7e0
commit
2fe72deb50
@ -751,6 +751,10 @@ class EditPerson:
|
|||||||
text = self.notes_field.get_chars(0,-1)
|
text = self.notes_field.get_chars(0,-1)
|
||||||
idval = self.gid.get_text()
|
idval = self.gid.get_text()
|
||||||
|
|
||||||
|
self.pmap = {}
|
||||||
|
for p in self.db.getPlaces():
|
||||||
|
self.pmap[p.get_title()] = p
|
||||||
|
|
||||||
changed = 0
|
changed = 0
|
||||||
name = self.person.getPrimaryName()
|
name = self.person.getPrimaryName()
|
||||||
|
|
||||||
@ -1080,6 +1084,10 @@ class EditPerson:
|
|||||||
self.person.setNickName(nick)
|
self.person.setNickName(nick)
|
||||||
utils.modified()
|
utils.modified()
|
||||||
|
|
||||||
|
self.pmap = {}
|
||||||
|
for p in self.db.getPlaces():
|
||||||
|
self.pmap[p.get_title()] = p
|
||||||
|
|
||||||
self.birth.setDate(self.bdate.get_text())
|
self.birth.setDate(self.bdate.get_text())
|
||||||
bplace = string.strip(self.bplace.get_text())
|
bplace = string.strip(self.bplace.get_text())
|
||||||
self.birth.setPlace(self.get_place(self.bplace,1))
|
self.birth.setPlace(self.get_place(self.bplace,1))
|
||||||
|
@ -39,6 +39,7 @@ import libglade
|
|||||||
import const
|
import const
|
||||||
import Config
|
import Config
|
||||||
import utils
|
import utils
|
||||||
|
import AutoComp
|
||||||
from RelLib import *
|
from RelLib import *
|
||||||
import ImageSelect
|
import ImageSelect
|
||||||
from intl import gettext
|
from intl import gettext
|
||||||
@ -65,6 +66,9 @@ class Marriage:
|
|||||||
self.db = db
|
self.db = db
|
||||||
self.path = db.getSavePath()
|
self.path = db.getSavePath()
|
||||||
self.cb = callback
|
self.cb = callback
|
||||||
|
self.pmap = {}
|
||||||
|
for p in db.getPlaces():
|
||||||
|
self.pmap[p.get_title()] = p
|
||||||
|
|
||||||
self.top = libglade.GladeXML(const.marriageFile,"marriageEditor")
|
self.top = libglade.GladeXML(const.marriageFile,"marriageEditor")
|
||||||
top_window = self.get_widget("marriageEditor")
|
top_window = self.get_widget("marriageEditor")
|
||||||
@ -142,7 +146,8 @@ class Marriage:
|
|||||||
plist = self.db.getPlaceMap().values()
|
plist = self.db.getPlaceMap().values()
|
||||||
ord = self.family.getLdsSeal()
|
ord = self.family.getLdsSeal()
|
||||||
if ord:
|
if ord:
|
||||||
utils.attach_places(plist,self.lds_place,ord.getPlace())
|
if ord.getPlace():
|
||||||
|
self.lds_place.entry.set_text(ord.getPlace().get_title())
|
||||||
self.lds_date.set_text(ord.getDate())
|
self.lds_date.set_text(ord.getDate())
|
||||||
if ord.getTemple() != "":
|
if ord.getTemple() != "":
|
||||||
name = const.lds_temple_to_abrev[ord.getTemple()]
|
name = const.lds_temple_to_abrev[ord.getTemple()]
|
||||||
@ -151,9 +156,9 @@ class Marriage:
|
|||||||
self.lds_temple.entry.set_text(name)
|
self.lds_temple.entry.set_text(name)
|
||||||
self.seal_stat = ord.getStatus()
|
self.seal_stat = ord.getStatus()
|
||||||
else:
|
else:
|
||||||
utils.attach_places(plist,self.lds_place,None)
|
|
||||||
self.lds_temple.entry.set_text("")
|
self.lds_temple.entry.set_text("")
|
||||||
self.seal_stat = 0
|
self.seal_stat = 0
|
||||||
|
self.autoplace = AutoComp.AutoCombo(self.lds_place,self.pmap.keys())
|
||||||
|
|
||||||
self.build_seal_menu()
|
self.build_seal_menu()
|
||||||
|
|
||||||
|
@ -382,13 +382,13 @@ class NewChild:
|
|||||||
|
|
||||||
# must do an apply filter here to make sure the main window gets updated
|
# must do an apply filter here to make sure the main window gets updated
|
||||||
|
|
||||||
self.update(self.family,person)
|
self.update(self.family,person,[])
|
||||||
utils.modified()
|
utils.modified()
|
||||||
utils.destroy_passed_object(obj)
|
utils.destroy_passed_object(obj)
|
||||||
self.new_child = person
|
self.new_child = person
|
||||||
|
|
||||||
def other_update(self,arg1,arg2):
|
def other_update(self,arg1,plist):
|
||||||
self.update(None,self.new_child)
|
self.update(None,self.new_child,plist)
|
||||||
|
|
||||||
def on_edit_new_child(self,obj):
|
def on_edit_new_child(self,obj):
|
||||||
import EditPerson
|
import EditPerson
|
||||||
|
@ -1356,9 +1356,11 @@ def new_after_edit(epo,plist):
|
|||||||
#
|
#
|
||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
def update_after_newchild(family,person):
|
def update_after_newchild(family,person,plist):
|
||||||
load_family(family)
|
load_family(family)
|
||||||
redisplay_person_list(person)
|
redisplay_person_list(person)
|
||||||
|
for p in plist:
|
||||||
|
place_view.new_place_after_edit(p)
|
||||||
|
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
#
|
#
|
||||||
|
Loading…
Reference in New Issue
Block a user