From ac9113890077243a3c1d3f08584d51348f93174d Mon Sep 17 00:00:00 2001 From: Martin Hawlisch Date: Wed, 8 Jun 2005 15:35:31 +0000 Subject: [PATCH] * src/EventView.py (column_names): Add missing column * src/RepositoryView.py (column_names): Add missing columns * src/GrampsDbBase.py: fix column_order methods * src/DisplayModels.py (RepositoryModel): Remove parish column because it is not editable anyway svn: r4805 --- gramps2/ChangeLog | 7 +++++++ gramps2/src/DisplayModels.py | 8 -------- gramps2/src/EventView.py | 1 + gramps2/src/GrampsDbBase.py | 17 +++++++++++------ gramps2/src/RepositoryView.py | 7 +++++++ 5 files changed, 26 insertions(+), 14 deletions(-) diff --git a/gramps2/ChangeLog b/gramps2/ChangeLog index 9e88674b8..8e36675a9 100644 --- a/gramps2/ChangeLog +++ b/gramps2/ChangeLog @@ -1,3 +1,10 @@ +2005-06-08 Martin Hawlisch + * src/EventView.py (column_names): Add missing column + * src/RepositoryView.py (column_names): Add missing columns + * src/GrampsDbBase.py: fix column_order methods + * src/DisplayModels.py (RepositoryModel): Remove parish column because + it is not editable anyway + 2005-06-08 Alex Roitman * src/ChooseParens.py: Support for (int,str) relationships. * src/FamilyView.py (new_child_after_edit): Use tuple relationships. diff --git a/gramps2/src/DisplayModels.py b/gramps2/src/DisplayModels.py index e8d21bea0..b0b179c9d 100644 --- a/gramps2/src/DisplayModels.py +++ b/gramps2/src/DisplayModels.py @@ -574,7 +574,6 @@ class RepositoryModel(BaseModel): self.column_id, self.column_type, self.column_home_url, - self.column_parish, self.column_postal_code, self.column_city, self.column_county, @@ -589,7 +588,6 @@ class RepositoryModel(BaseModel): self.column_id, self.column_type, self.column_home_url, - self.column_parish, self.column_postal_code, self.column_city, self.column_county, @@ -621,12 +619,6 @@ class RepositoryModel(BaseModel): def column_name(self,data): return unicode(data[3]) - def column_parish(self,data): - try: - return data[4].get_parish() - except: - return u'' - def column_city(self,data): try: return data[4].get_city() diff --git a/gramps2/src/EventView.py b/gramps2/src/EventView.py index 5d885b27e..be3dafee8 100644 --- a/gramps2/src/EventView.py +++ b/gramps2/src/EventView.py @@ -50,6 +50,7 @@ column_names = [ _('Description'), _('ID'), _('Type'), + _('Last Change'), _('Date'), _('Place'), _('Cause'), diff --git a/gramps2/src/GrampsDbBase.py b/gramps2/src/GrampsDbBase.py index 9c3c4ffdd..b9b628a07 100644 --- a/gramps2/src/GrampsDbBase.py +++ b/gramps2/src/GrampsDbBase.py @@ -1299,14 +1299,21 @@ class GrampsDbBase(GrampsDBCallback.GrampsDBCallback): """ self._set_column_order(col_list,SOURCE_COL_KEY) - def set_media_column_order(self,list): + def set_media_column_order(self,col_list): """ Stores the Media display common information in the database's metadata. """ self._set_column_order(col_list,MEDIA_COL_KEY) - def set_repository_column_order(self,list): + def set_event_column_order(self,col_list): + """ + Stores the Event display common information in the + database's metadata. + """ + self._set_column_order(col_list,EVENT_COL_KEY) + + def set_repository_column_order(self,col_list): """ Stores the Repository display common information in the database's metadata. @@ -1360,7 +1367,7 @@ class GrampsDbBase(GrampsDBCallback.GrampsDBCallback): Returns the MediaObject display common information stored in the database's metadata. """ - default = [(1,1),(0,5),(0,6),(1,2),(1,3),(0,4)] + default = [(1,1),(1,2),(1,3),(1,5),(0,4)] return self._get_column_order(MEDIA_COL_KEY,default) def get_event_column_order(self): @@ -1376,7 +1383,7 @@ class GrampsDbBase(GrampsDBCallback.GrampsDBCallback): Returns the Repository display common information stored in the database's metadata. """ - default = [(1,1),(0,5),(0,6),(1,2),(1,3),(0,4)] + default = [(1,1),(0,5),(0,6),(1,2),(1,3),(0,4),(0,7),(0,8),(0,9),(0,10)] return self._get_column_order(REPOSITORY_COL_KEY,default) class Transaction: @@ -1481,5 +1488,3 @@ class Transaction: if self.last and self.first: return self.last - self.first + 1 return 0 - - diff --git a/gramps2/src/RepositoryView.py b/gramps2/src/RepositoryView.py index e9c2540f8..20de8d8e0 100644 --- a/gramps2/src/RepositoryView.py +++ b/gramps2/src/RepositoryView.py @@ -52,6 +52,13 @@ column_names = [ _('ID'), _('Type'), _('Home URL'), + _('ZIP/Postal Code'), + _('City'), + _('County'), + _('State'), + _('Country'), + _('Email'), + _('Search URL'), ] _HANDLE_COL = 12