Digits ZATCA | Tax Total (Fix Issue)
by Digital Integrated Transformation Solutions (DigitsCode) https://www.digitscode.com
Digits ZATCA | Tax Total (Fix Issue)
Temporary fix for the recurring ZATCA chatter warning BR-KSA-EN16931-09 on SAR invoices. Uninstall it when Odoo 18 core restores the second TaxTotal node.
The warning in Odoo
After a successful send, ZATCA accepts the invoice and Odoo posts this yellow message on the invoice chatter. The invoice is valid; the XML structure is incomplete for SAR documents.
Screenshot: chatter warning [202] BR-KSA-EN16931-09
— Only one tax total (BG-22) without tax subtotals (BG-23)
must be provided when tax currency code is provided.
1. Cause
Odoo 18 always sends TaxCurrencyCode (SAR).
A core change then omitted the second TaxTotal on SAR invoices.
2. ZATCA rule
When tax currency code is present, XML must include one
cac:TaxTotal without TaxSubtotal (BT-111).
3. This module
Restores that second node for SAR invoices. Foreign-currency invoices are left unchanged (no duplicate).
Required XML shape
<cbc:DocumentCurrencyCode>SAR</cbc:DocumentCurrencyCode>
<cbc:TaxCurrencyCode>SAR</cbc:TaxCurrencyCode>
<cac:TaxTotal>
<cbc:TaxAmount currencyID="SAR">...</cbc:TaxAmount>
<cac:TaxSubtotal>...</cac:TaxSubtotal> <!-- WITH breakdown -->
</cac:TaxTotal>
<cac:TaxTotal>
<cbc:TaxAmount currencyID="SAR">...</cbc:TaxAmount>
<!-- WITHOUT TaxSubtotal (restored by this module) -->
</cac:TaxTotal>
Install
- Install Digits ZATCA | Tax Total (Fix Issue) (
digits_zatca_tax_total). - Depends only on
l10n_sa_edi. - New invoices sent to ZATCA after install will not show this warning.
- Already-sent invoices stay accepted; they are not re-submitted.
| Availability |
Odoo Online
Odoo.sh
On Premise
|
| Odoo Apps Dependencies |
•
Invoicing (account)
• Discuss (mail) |
| Lines of code | 18 |
| Technical Name |
digits_zatca_tax_total |
| License | OPL-1 |
| Website | https://www.digitscode.com |
Odoo Proprietary License v1.0 This software and associated files (the "Software") may only be used (executed, modified, executed after modifications) if you have purchased a valid license from the authors, typically via Odoo Apps, or if you have received a written agreement from the authors of the Software (see the COPYRIGHT file). You may develop Odoo modules that use the Software as a library (typically by depending on it, importing it and using its resources), but without copying any source code or material from the Software. You may distribute those modules under the license of your choice, provided that this license is compatible with the terms of the Odoo Proprietary License (For example: LGPL, MIT, or proprietary licenses similar to this one). It is forbidden to publish, distribute, sublicense, or sell copies of the Software or modified copies of the Software. The above copyright notice and this permission notice must be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Please log in to comment on this module