Align code with DTD/schema

svn: r17117
This commit is contained in:
Michiel Nauta 2011-04-13 17:32:28 +00:00
parent ac9fd67e10
commit 9c38eddab2
3 changed files with 4 additions and 3 deletions

View File

@ -139,7 +139,7 @@ GENDER has values of M, F, or U.
<!ELEMENT surname (#PCDATA)>
<!ATTLIST surname
prefix CDATA #IMPLIED
primary (1|0) #IMPLIED
prim (1|0) #IMPLIED
derivation CDATA #IMPLIED
connector CDATA #IMPLIED
>

View File

@ -255,7 +255,7 @@
<element name="surname">
<text/>
<optional><attribute name="prefix"><text/></attribute></optional>
<optional><attribute name="primary"><choice>
<optional><attribute name="prim"><choice>
<value>1</value>
<value>0</value>
</choice></attribute></optional>

View File

@ -1791,6 +1791,7 @@ class GrampsParser(UpdateCallback):
self.reporef.ref = handle
self.reporef.call_number = attrs.get('callno', '')
if 'medium' in attrs:
self.reporef.media_type.set_from_xml_str(attrs['medium'])
self.reporef.private = bool(attrs.get("priv"))
# we count here on self.source being available