Go to file
2026-06-13 22:40:36 +07:00
models feat: add computed cash_difference field to pos.session and display in tree view 2026-06-13 22:40:36 +07:00
static/src/xml feat: Update module version to 19.0.1.0.0 for Odoo 19 compatibility. 2026-01-20 16:58:16 +07:00
views feat: add computed cash_difference field to pos.session and display in tree view 2026-06-13 22:40:36 +07:00
__init__.py feat: Update module version to 19.0.1.0.0 for Odoo 19 compatibility. 2026-01-20 16:58:16 +07:00
__manifest__.py feat: add computed cash_difference field to pos.session and display in tree view 2026-06-13 22:40:36 +07:00
.gitignore feat: Update module version to 19.0.1.0.0 for Odoo 19 compatibility. 2026-01-20 16:58:16 +07:00
README.md feat: add closing cash tracking fields and update session validation logic to suppress shortages instead of surpluses 2026-06-09 09:41:44 +07:00

POS Cash Opening Adjustment

This module provides adjustments for the POS opening cash mechanism in Odoo 19.

Features

  • Overrides _set_opening_control_data to properly initialize and track opening_cash_expected and opening_cash_counted while utilizing Odoo's native functionality.
  • Tracks opening cash correctly so that the system correctly calculates differences.
  • Leverages standard Odoo 19 journal handling for robust accounting integration.
  • Phantom Difference Prevention: Relies on standard Odoo mechanisms to ensure no journal items are created when the expected cash mathematically matches the inputted cash (e.g. opening with 150k and closing with 150k, or opening with 200k, selling 100k, and closing with 300k).
  • Shortage Suppression: Automatically adjusts the real balance to match the expected balance when a shortage is detected, avoiding loss/expense journal entries.
  • Surplus Recording: Allows standard Odoo behavior to record a surplus as a profit journal entry.

Technical Details

This module modifies the pos.session object, tracking:

  • opening_cash_expected: The expected cash balance when opening the session.
  • opening_cash_counted: The actual cash counted by the cashier.
  • opening_cash_difference: Computed difference between counted and expected opening cash.

It modifies the standard _validate_session process strictly for suppressing negative discrepancies (shortages where the ending cash register is lower than expected), logging the event into the chatter.

Author

Suherdy Yacob