Machete Anexo ID NIE901

FossilOrigin-Name: ce5cd5e95d640dd97a277bfc072e376566bac007c33f9ff521a70470f39dc5bb
This commit is contained in:
pingara
2022-04-22 01:55:01 +00:00
parent 29db6b0342
commit ac1678b1cc
2 changed files with 35 additions and 14 deletions

View File

@@ -32,9 +32,10 @@ POLICY_NAME = u'Política de firma para facturas electrónicas de la República
NAMESPACES = {
'facho': 'http://git.disroot.org/Etrivial/facho',
'atd': 'urn:oasis:names:specification:ubl:schema:xsd:AttachedDocument-2',
'no': 'dian:gov:co:facturaelectronica:NominaIndividual',
'fe': 'http://www.dian.gov.co/contratos/facturaelectronica/v1',
'xs': 'http://www.w3.org/2001/XMLSchema-instance',
'cac': 'urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2',
'cbc': 'urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2',
'cdt': 'urn:DocumentInformation:names:specification:ubl:colombia:schema:xsd:DocumentInformationAggregateComponents-1',
@@ -46,6 +47,7 @@ NAMESPACES = {
'udt': 'urn:un:unece:uncefact:data:specification:UnqualifiedDataTypesSchemaModule:2',
'xsi': 'http://www.w3.org/2001/XMLSchema-instance',
'xades': 'http://uri.etsi.org/01903/v1.3.2#',
'xades141': 'http://uri.etsi.org/01903/v1.4.1#',
'ds': 'http://www.w3.org/2000/09/xmldsig#',
'sig': 'http://www.w3.org/2000/09/xmldsig#',
}
@@ -87,7 +89,8 @@ class FeXML(FachoXML):
# MACHETE(bit4bit) la DIAN espera que la etiqueta raiz no este en un namespace
return super().tostring(**kw)\
.replace("fe:", "")\
.replace("xmlns:fe", "xmlns")
.replace("xmlns:no", "xmlns")\
.replace("change", "xsi:schemaLocation")
class DianXMLExtensionCUDFE(FachoXMLExtension):