Skip to Content

Tax Balance Hook

English | Slovenščina

License: AGPL-3 Version: 18.0

Find the taxes relevant to a reporting period using Tax Dates and, in DDV-O mode, tax tags. This integration adapts OCA tax-balance discovery and date domains to the date field selected by the Slovenian tax extension.

Use it through the existing tax-balance workflow; it adds no separate screen or report.

Table of contents

Documentation

  • User Manual: illustrated tax-balance period selection, calculation bases, source investigation and troubleshooting.

Features

  • Uses account.tax._get_tax_balance_date_field() when available. Otherwise it selects journal-item tax_date.

  • Falls back to accounting date if the selected field does not exist on account.move.line.

  • Applies the chosen field to candidate-tax discovery, the SQL discovery helper and partial tax-balance date domains.

  • Discovers taxes through tax_line_id and tax_ids in standard mode.

  • With tax_balance_use_tags, discovers taxes whose repartition tags occur on journal items within the selected companies and period.

Configuration

  • Install with account_tax_balance, pmis_account_dates and l10n_si_tax_addons.

  • Select the company, period and calculation basis through the tax-balance workflow provided by those dependencies.

  • The addon adds no settings screen, reports or menu items.

Usage

Review tax balances:

  1. Open the tax-balance wizard.

  2. Select the intended company, reporting dates and calculation basis.

  3. Run the calculation and inspect the matching tax and journal-item details.

  4. If dates appear unexpected, inspect the selected date field and the source journal items' Tax Dates.

Data model notes

  • A post_load_hook() replaces three methods on the upstream account_tax_balance implementation of account.tax.

  • Original methods are retained once under their corresponding *_original attributes.

  • Date/company filtering is shared across the patched helpers; report amounts and reporting semantics remain the responsibility of the tax-balance and Slovenian tax addons.

  • The tag-based candidate search is implemented in the ORM discovery helper. The SQL helper retains tax-ID discovery.

Known limitations

  • Falling back to accounting date is based on field availability, not on a particular journal item having an empty Tax Date.

  • This addon does not fill missing dates or change posted journal items.

  • The hook patches upstream Python methods at process load rather than adding a per-company setting.

Bug Tracker

Bugs are tracked on PMISuite Repository Issues. In case of trouble, please check there if your issue has already been reported. If you spotted it first, help us smashing it by providing a detailed and welcomed feedback.

Credits

Authors

Contributors

  • Matjaž Kalič (MENTIS)

  • Matjaž Mozetič (LUXIM)

Maintainers

LUXIM MATMOZ

Current maintainer:

sysadminmatmoz

Luxim is an independent R&D and deployment company focused on solving complex problems in the Odoo ecosystem.

Odoo Community Association

Luxim is an active member of OCA (Odoo Community Association).