This commit is contained in:
gsinghpal
2026-03-16 08:14:56 -04:00
parent fdca9518ab
commit e56974d46f
196 changed files with 19739 additions and 3471 deletions

View File

@@ -0,0 +1,29 @@
# -*- coding: utf-8 -*-
# Copyright 2024-2026 Nexa Systems Inc.
# License OPL-1 (Odoo Proprietary License v1.0)
from . import models
from . import wizard
from . import controllers
def _pre_init_hook(env):
"""Re-assign loaner data record ownership from fusion_claims before install.
Prevents duplicate stock locations, sequences, and product categories
when migrating loaner functionality from fusion_claims to this module.
"""
env.cr.execute("""
UPDATE ir_model_data SET module = 'fusion_loaners_management'
WHERE module = 'fusion_claims'
AND name IN (
'stock_location_loaner',
'seq_loaner_checkout',
'product_category_loaner',
'product_category_loaner_rollator',
'product_category_loaner_wheelchair',
'product_category_loaner_powerchair',
'model_fusion_loaner_checkout',
'model_fusion_loaner_history'
)
""")