|
|
@ -673,6 +673,9 @@ class SerializacaoXML(Serializacao): |
|
|
return raiz |
|
|
return raiz |
|
|
|
|
|
|
|
|
def serializar_evento(self, evento, tag_raiz='evento', retorna_string=False): |
|
|
def serializar_evento(self, evento, tag_raiz='evento', retorna_string=False): |
|
|
|
|
|
if six.PY2: |
|
|
|
|
|
tz = datetime.now().strftime("%z") |
|
|
|
|
|
else: |
|
|
tz = datetime.now().astimezone().strftime('%z') |
|
|
tz = datetime.now().astimezone().strftime('%z') |
|
|
tz = "{}:{}".format(tz[:-2], tz[-2:]) |
|
|
tz = "{}:{}".format(tz[:-2], tz[-2:]) |
|
|
raiz = etree.Element(tag_raiz, versao='1.00', xmlns=NAMESPACE_NFE) |
|
|
raiz = etree.Element(tag_raiz, versao='1.00', xmlns=NAMESPACE_NFE) |
|
|
|