Files
odoo_account_ebics/account_ebics/__init__.py
T
Luc De Meyer 2d301e87f8 [IMP] Add upload state tracking on EBICS payment files
account_ebics:
- Add pain_state and ebics_order_number to ebics.file
- Set these fields after a successful upload
- Add neutralized property to api.Environment

account_ebics_batch_payment:
- Add EBICS notebook page with upload info to batch payment form
- Post chatter message with OrderID after upload

account_ebics_payment_order:
- Fix broken postprocess: replace deprecated active_model/active_id
  context keys with model/id
2026-10-11 20:59:48 +02:00

32 lines
734 B
Python

import functools
import logging
from odoo import api
_logger = logging.getLogger(__name__)
try:
from . import models
from . import wizards
except Exception:
_logger.warning("Import Error, check if fintech lib has been installed")
@functools.cached_property
def neutralized(self):
return bool(
self["ir.config_parameter"].sudo().get_param("database.is_neutralized")
or self["ir.ui.view"]
.sudo()
.search_count(
[
("key", "in", ("web.neutralize_banner", "website.neutralize_ribbon")),
("active", "=", True),
]
)
)
api.Environment.neutralized = neutralized
neutralized.__set_name__(api.Environment, "neutralized")