@@ -79,7 +79,7 @@ def command(dbstate, uistate, track, citation_handle, person_handle):
79
79
db = dbstate .db
80
80
person = db .get_person_from_handle (person_handle )
81
81
person .get_primary_name ().add_citation (citation_handle )
82
- with DbTxn (_ ("Add Person (%s )" ) % name_displayer .display (person ), db ) as trans :
82
+ with DbTxn (_ ("Add Person ({name} )" ). format ( name = name_displayer .display (person ) ), db ) as trans :
83
83
db .commit_person (person , trans )
84
84
85
85
class AlternateName :
@@ -91,7 +91,8 @@ def get_actions(dbstate, citation, form_event):
91
91
alternate = Name ()
92
92
alternate .set_first_name (attr .get_value ())
93
93
alternate .add_citation (citation .handle )
94
- actions .append ((name_displayer .display (person ), attr .get_value (),
94
+ detail = _ ('Given Name: {name}' ).format (name = attr .get_value ())
95
+ actions .append ((name_displayer .display (person ), detail ,
95
96
lambda dbstate , uistate , track , person_handle = person .handle , alternate_ = alternate : AlternateName .command (dbstate , uistate , track , person_handle , alternate_ )))
96
97
return (_ ("Add alternate name" ), actions )
97
98
@@ -100,7 +101,7 @@ def command(dbstate, uistate, track, person_handle, alternate):
100
101
db = dbstate .db
101
102
person = db .get_person_from_handle (person_handle )
102
103
person .add_alternate_name (alternate )
103
- with DbTxn (_ ("Add Person (%s )" ) % name_displayer .display (person ), db ) as trans :
104
+ with DbTxn (_ ("Add Person ({name} )" ). format ( name = name_displayer .display (person ) ), db ) as trans :
104
105
db .commit_person (person , trans )
105
106
106
107
class BirthEvent :
@@ -175,7 +176,7 @@ def command(dbstate, uistate, track, citation_handle, event_date_object, event_p
175
176
event .set_date_object (event_date_object )
176
177
event .set_place_handle (event_place_handle )
177
178
event .add_citation (citation_handle )
178
- with DbTxn (_ ("Add Event (%s )" ) % event .get_gramps_id (), db ) as trans :
179
+ with DbTxn (_ ("Add Event ({id} )" ). format ( id = event .get_gramps_id () ), db ) as trans :
179
180
db .add_event (event , trans )
180
181
181
182
# and reference the event from all people
@@ -185,5 +186,5 @@ def command(dbstate, uistate, track, citation_handle, event_date_object, event_p
185
186
event_ref .set_role (role )
186
187
person = db .get_person_from_handle (person_handle )
187
188
person .add_event_ref (event_ref )
188
- with DbTxn (_ ("Add Event (%s )" ) % name_displayer .display (person ), db ) as trans :
189
+ with DbTxn (_ ("Add Event ({name} )" ). format ( name = name_displayer .display (person ) ), db ) as trans :
189
190
db .commit_person (person , trans )
0 commit comments