mirror of
https://github.com/bringout/oca-payment.git
synced 2026-04-24 06:42:02 +02:00
Restructure: move packages from packages/ subdirectory to root
Flattened directory structure by moving payment packages from redundant packages/ subdirectory to the root level of oca-payment repository. Changes: - Moved odoo-bringout-oca-payment-* from packages/ to root - Updated CLAUDE.md to reflect new flat structure - Removed redundant packages/ directory 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
parent
99c650f4f5
commit
7f7e88ab3d
202 changed files with 1 additions and 1 deletions
|
|
@ -0,0 +1,22 @@
|
|||
import logging
|
||||
|
||||
from odoo.tools import sql
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
|
||||
def pre_init_hook(cr):
|
||||
"""Prepare new payment_mode fields.
|
||||
|
||||
Add columns to avoid Memory error on an existing Odoo instance
|
||||
with lots of data.
|
||||
|
||||
The payment_mode_id fields are introduced by this module and computed only
|
||||
from each other or the also newly introduced supplier_payment_mode_id and
|
||||
customer_payment_mode_id on res.partner, so they can stay NULL, nothing
|
||||
to compute.
|
||||
"""
|
||||
if not sql.column_exists(cr, "account_move", "payment_mode_id"):
|
||||
sql.create_column(cr, "account_move", "payment_mode_id", "int4")
|
||||
if not sql.column_exists(cr, "account_move_line", "payment_mode_id"):
|
||||
sql.create_column(cr, "account_move_line", "payment_mode_id", "int4")
|
||||
Loading…
Add table
Add a link
Reference in a new issue