8153 GEDCOM 5.5.1 Support Custom Event on export
This commit is contained in:
parent
0c179a2a47
commit
9fe3f6ad05
@ -578,14 +578,15 @@ class GedcomWriter(UpdateCallback):
|
|||||||
if event.get_description().strip():
|
if event.get_description().strip():
|
||||||
self._writeln(2, 'TYPE', event.get_description())
|
self._writeln(2, 'TYPE', event.get_description())
|
||||||
else:
|
else:
|
||||||
self._writeln(1, 'EVEN')
|
descr = event.get_description()
|
||||||
|
if descr:
|
||||||
|
self._writeln(1, 'EVEN', descr)
|
||||||
|
else:
|
||||||
|
self._writeln(1, 'EVEN')
|
||||||
if val.strip():
|
if val.strip():
|
||||||
self._writeln(2, 'TYPE', val)
|
self._writeln(2, 'TYPE', val)
|
||||||
else:
|
else:
|
||||||
self._writeln(2, 'TYPE', str(event.get_type()))
|
self._writeln(2, 'TYPE', str(event.get_type()))
|
||||||
descr = event.get_description()
|
|
||||||
if descr:
|
|
||||||
self._writeln(2, 'NOTE', "Description: " + descr)
|
|
||||||
self._dump_event_stats(event, event_ref)
|
self._dump_event_stats(event, event_ref)
|
||||||
if etype == EventType.ADOPT and not adop_written:
|
if etype == EventType.ADOPT and not adop_written:
|
||||||
adop_written = True
|
adop_written = True
|
||||||
@ -855,13 +856,14 @@ class GedcomWriter(UpdateCallback):
|
|||||||
if event.get_description().strip() != "":
|
if event.get_description().strip() != "":
|
||||||
self._writeln(2, 'TYPE', event.get_description())
|
self._writeln(2, 'TYPE', event.get_description())
|
||||||
else:
|
else:
|
||||||
self._writeln(1, 'EVEN')
|
descr = event.get_description()
|
||||||
|
if descr:
|
||||||
|
self._writeln(1, 'EVEN', descr)
|
||||||
|
else:
|
||||||
|
self._writeln(1, 'EVEN')
|
||||||
the_type = str(event.get_type())
|
the_type = str(event.get_type())
|
||||||
if the_type:
|
if the_type:
|
||||||
self._writeln(2, 'TYPE', the_type)
|
self._writeln(2, 'TYPE', the_type)
|
||||||
descr = event.get_description()
|
|
||||||
if descr:
|
|
||||||
self._writeln(2, 'NOTE', "Description: " + descr)
|
|
||||||
|
|
||||||
def _family_event_attrs(self, attr_list, level):
|
def _family_event_attrs(self, attr_list, level):
|
||||||
"""
|
"""
|
||||||
|
Loading…
Reference in New Issue
Block a user