Skip to content

Commit

Permalink
Merge pull request #3 from assoft-portugal/dev
Browse files Browse the repository at this point in the history
SAF-T AO structure update
  • Loading branch information
assoftpt authored Jul 11, 2019
2 parents 505b1a0 + 0790b7b commit aee2849
Show file tree
Hide file tree
Showing 2 changed files with 57 additions and 16 deletions.
17 changes: 16 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,17 @@
# SAF-T-AO
Official XSD from the Government of Angola for use in SAF-T AO
Official XSD from the Government of Angola for use in SAF-T AO.

> The Standard Audit File for Tax Purposes (SAF-T) is a standardized XML file used for exporting the accounting information of a company to the tax authorities. The file contains accounting data that can be exported from an original accounting system for a specific time period.
>
> The SAF-T file is based on a directive by the Organization for Economic Co-operation and Development (OECD).
>
> [Oracle, JD Edwards EnterpriseOne Applications OECD Standard Audit File for Tax Purposes (SAF-T) Localizations Implementation Guide](https://docs.oracle.com/cd/E16582_01/doc.91/e97460/ch_eu_saft_xml.htm#EOAST109).
## VAT implementation in Angola

The of VAT legislation will take effect starting in October 2019. This deadline applies to software billing solutions, SAF-T file, and invoicing rules:

* Software solutions must be compliance with the requirements of the new legal system in order to process sales documents, invoices and other fiscal documents in accord to the legal framework. This rule applies to all the subjects of the VAT scheme.
* Software creators must apply to a software certification program by the government which is mandatory.
* Starting from **1 January 2020** it will be mandatory to produce a monthly SAF-T file and send it to the government tax authorities.
* From 1 January 2020, all taxpayers with an annual turnover of more than AKZ 50,000,000 will be required to produce the above referred SAF-T files and use certified software.
56 changes: 41 additions & 15 deletions XSD/SAFTAO1.01_01.xsd
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@
<doc:Author>AGT - Administração Geral Tributária</doc:Author>
<!-- Contributos para o Projeto -->
<doc:Contributors>
<doc:Contributor>ASSOFT - Associação Portuguesa de Software</doc:Contributor>
<doc:Contributor>Nelson Lopes | https://github.com/cryptolopes</doc:Contributor>
<doc:Contributor name="ASSOFT - Associação Portuguesa de Software" url="https://www.assoft.org/" />
<doc:Contributor name="Nelson Lopes" url="https://github.com/cryptolopes/"/>
</doc:Contributors>
<doc:ModificationDate>2017-07-01</doc:ModificationDate>
<doc:ModificationDate>2017-07-11</doc:ModificationDate>
</xs:documentation>
</xs:annotation>
<!-- Estrutura do ficheiro SAFT-AO-->
Expand Down Expand Up @@ -433,8 +433,7 @@
<xs:element minOccurs="0" maxOccurs="1" ref="ShipFrom"/>
<xs:element minOccurs="0" maxOccurs="1" ref="MovementEndTime"/>
<xs:element maxOccurs="1" ref="MovementStartTime"/>
<!-- Nos documentos resumo (MovementStatus "R"), na falta desta informacao em concreto, a hora de inicio de transporte (MovementStartTime) pode ser indicada com a concatenacao da data constante no campo MovementDate com a hora 00:00:00-->
<xs:element minOccurs="0" maxOccurs="1" ref="ATDocCodeID"/>
<xs:element minOccurs="0" maxOccurs="1" ref="AGTDocCodeID"/>
<xs:element maxOccurs="unbounded" name="Line">
<xs:complexType>
<xs:sequence>
Expand All @@ -451,8 +450,9 @@
<xs:element ref="CreditAmount"/>
</xs:choice>
<xs:element minOccurs="0" name="Tax" type="MovementTax"/>
<xs:element minOccurs="0" ref="TaxExemptionReason"/>
<xs:group minOccurs="0" ref="TaxExemptions" />
<xs:element minOccurs="0" ref="SettlementAmount"/>
<xs:element name="CustomsInformation" type="CustomsInformation" minOccurs="0" />
</xs:sequence>
</xs:complexType>
</xs:element>
Expand Down Expand Up @@ -789,7 +789,7 @@
<xs:element name="Address" type="AddressStructure"/>
<xs:element name="AddressDetail" type="SAFAOtextTypeMandatoryMax250Car"/>
<xs:element name="ARCNo" type="SAFAOtextTypeMandatoryMax21Car" />
<xs:element name="ATDocCodeID" type="SAFAOtextTypeMandatoryMax200Car"/>
<xs:element name="AGTDocCodeID" type="SAFAOtextTypeMandatoryMax200Car"/>
<xs:element name="BillingAddress" type="AddressStructure"/>
<xs:element name="BuildingNumber" type="SAFAOtextTypeMandatoryMax15Car"/>
<xs:element name="BusinessName" type="SAFAOtextTypeMandatoryMax60Car"/>
Expand Down Expand Up @@ -869,7 +869,7 @@
<xs:element name="TaxAmount" type="SAFmonetaryType"/>
<xs:element name="TaxBase" type="SAFmonetaryType" />
<xs:element name="TaxEntity" type="SAFAOtextTypeMandatoryMax20Car"/>
<xs:element name="TaxExemptionReason" type="SAFAOPortugueseTaxExemption"/>
<xs:element name="TaxExemptionReason" type="SAFAOTaxExemption"/>
<xs:element name="TaxExemptionCode" type="SAFAOTaxExemptionCode" />
<xs:element name="TaxExpirationDate" type="SAFdateType"/>
<xs:element name="TaxPayable" type="SAFmonetaryType"/>
Expand Down Expand Up @@ -939,10 +939,10 @@
</xs:element>
<!-- Codigo da moeda (ISO 4217) -->
<xs:element name="CurrencyCode">
<!-- Nao consta o EUR por nao existirem situacoes que requeiram este codigo de moeda -->
<!-- Nao consta o AOA por nao existirem situacoes que requeiram este codigo de moeda -->
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:pattern value="AED|AFN|ALL|AMD|ANG|AOA|ARS|AUD|AWG|AZN|BAM|BBD|BDT|BGN|BHD|BIF|BMD|BND|BOB|BOV|BRL|BSD|BTN|BWP|BYR|BZD|CAD|CDF|CHE|CHF|CHW|CLF|CLP|CNY|COP|COU|CRC|CUC|CUP|CVE|CZK|DJF|DKK|DOP|DZD|EGP|ERN|ETB|FJD|FKP|GBP|GEL|GHS|GIP|GMD|GNF|GTQ|GYD|HKD|HNL|HRK|HTG|HUF|IDR|ILS|INR|IQD|IRR|ISK|JMD|JOD|JPY|KES|KGS|KHR|KMF|KPW|KRW|KWD|KYD|KZT|LAK|LBP|LKR|LRD|LSL|LTL|LVL|LYD|MAD|MDL|MGA|MKD|MMK|MNT|MOP|MRO|MUR|MVR|MWK|MXN|MXV|MYR|MZN|NAD|NGN|NIO|NOK|NPR|NZD|OMR|PAB|PEN|PGK|PHP|PKR|PLN|PYG|QAR|RON|RSD|RUB|RWF|SAR|SBD|SCR|SDG|SEK|SGD|SHP|SLL|SOS|SRD|SSP|STD|SVC|SYP|SZL|THB|TJS|TMT|TND|TOP|TRY|TTD|TWD|TZS|UAH|UGX|USD|USN|USS|UYI|UYU|UZS|VEF|VND|VUV|WST|XAF|XAG|XAU|XBA|XBB|XBC|XBD|XCD|XDR|XFU|XOF|XPD|XPF|XPT|XSU|XUA|YER|ZAR|ZMW|ZWL|EEK|SKK|TMM|ZMK|ZWD|ZWR|"/>
<xs:pattern value="AED|AFN|ALL|AMD|ANG|ARS|AUD|AWG|AZN|BAM|BBD|BDT|BGN|BHD|BIF|BMD|BND|BOB|BOV|BRL|BSD|BTN|BWP|BYR|BZD|CAD|CDF|CHE|CHF|CHW|CLF|CLP|CNY|COP|COU|CRC|CUC|CUP|CVE|CZK|DJF|DKK|DOP|DZD|EGP|ERN|ETB|EUR|FJD|FKP|GBP|GEL|GHS|GIP|GMD|GNF|GTQ|GYD|HKD|HNL|HRK|HTG|HUF|IDR|ILS|INR|IQD|IRR|ISK|JMD|JOD|JPY|KES|KGS|KHR|KMF|KPW|KRW|KWD|KYD|KZT|LAK|LBP|LKR|LRD|LSL|LTL|LVL|LYD|MAD|MDL|MGA|MKD|MMK|MNT|MOP|MRO|MUR|MVR|MWK|MXN|MXV|MYR|MZN|NAD|NGN|NIO|NOK|NPR|NZD|OMR|PAB|PEN|PGK|PHP|PKR|PLN|PYG|QAR|RON|RSD|RUB|RWF|SAR|SBD|SCR|SDG|SEK|SGD|SHP|SLL|SOS|SRD|SSP|STD|SVC|SYP|SZL|THB|TJS|TMT|TND|TOP|TRY|TTD|TWD|TZS|UAH|UGX|USD|USN|USS|UYI|UYU|UZS|VEF|VND|VUV|WST|XAF|XAG|XAU|XBA|XBB|XBC|XBD|XCD|XDR|XFU|XOF|XPD|XPF|XPT|XSU|XUA|YER|ZAR|ZMW|ZWL|EEK|SKK|TMM|ZMK|ZWD|ZWR"/>
<xs:length value="3"/>
</xs:restriction>
</xs:simpleType>
Expand Down Expand Up @@ -999,6 +999,22 @@
</xs:element>
<!-- Codigo unico do documento de venda -->
<xs:element name="InvoiceNo">
<xs:annotation>
<xs:documentation>

Recomenda-se a utlização do seguinte formato:

InvoiceType + ESPAÇO + / + Número Sequencial

Exemplos:
InvoiceType: FT
InvoiceNo: FT S001/1

InvoiceType: NC
InvoiceNo: NC S001/1

</xs:documentation>
</xs:annotation>
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:pattern value="[^ ]+ [^/^ ]+/[0-9]+"/>
Expand Down Expand Up @@ -1077,7 +1093,14 @@
<!-- Estado do documento MovementOfGoods -->
<xs:element name="MovementStatus">
<xs:annotation>
<xs:documentation>N para Normal, T para Por conta de terceiros, A para Documento anulado, F para Documento faturado, quando para este documento tambem existe na tabela 4.1. para Documentos comerciais a clientes (SalesInvoices) o correspondente do tipo fatura ou fatura simplificada, R para Documento de resumo doutros documentos criados noutras aplicacoes e gerado nesta aplicacao </xs:documentation>
<xs:documentation>
Deve ser preenchido com: “N” – Normal;
“T” – Por conta de terceiros;
“A” – Documento anulado;
“F” – Documento facturado, ainda que parcialmente, quando
para este documento também existe na tabela 4.1. – Documentos comerciais a clientes (SalesInvoices) o correspondente do tipo factura.
“R” – Documento de resumo doutros documentos criados noutras aplicações e gerado nesta aplicação.
</xs:documentation>
</xs:annotation>
<xs:simpleType>
<xs:restriction base="xs:string">
Expand All @@ -1093,15 +1116,18 @@
<xs:element name="MovementType">
<xs:annotation>
<xs:documentation>
Restricao: Tipos de Documento (GR para Guia de remessa, GT para Guia de transporte incluindo as globais, GA para Guia de movimentacao de ativos fixos proprios, GC para Guia de consignacao, GD para Guia ou nota de devolucao
Deve ser preenchido com:
“GR” – Guia de remessa;
“GT” – Guia de transporte (incluir aqui as guias globais);
“GA” – Guia de movimentação de activos fixos próprios; “GC” – Guia de consignação;
“GD” – Guia ou nota de devolução.
</xs:documentation>
</xs:annotation>
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="GR"/>
<xs:enumeration value="GT"/>
<xs:enumeration value="GA"/>
<xs:enumeration value="GC"/>
<xs:enumeration value="GD"/>
</xs:restriction>
</xs:simpleType>
Expand Down Expand Up @@ -1433,7 +1459,7 @@
</xs:simpleType>
<xs:simpleType name="SAFTAOMovementTaxCode">
<xs:restriction base="xs:string">
<xs:pattern value="NOR|ISE|OUT|NS"/>
<xs:pattern value="NOR|ISE|OUT"/>
<xs:minLength value="1"/>
<xs:maxLength value="3"/>
</xs:restriction>
Expand Down Expand Up @@ -1474,7 +1500,7 @@
<xs:enumeration value="RG"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="SAFAOPortugueseTaxExemption">
<xs:simpleType name="SAFAOTaxExemption">
<xs:restriction base="xs:string">
<xs:minLength value="6"/>
<xs:maxLength value="60"/>
Expand Down

0 comments on commit aee2849

Please sign in to comment.