CREATE MATERIALIZED VIEW fusion_unreconciled_bank_line_mv pre-computes the data the kanban widget needs (top suggestion, confidence band, attachment count, partner reconcile hint) so that listing 50-100 lines is one indexed query instead of N+1. Refresh strategy: - Triggered on fusion.reconcile.suggestion create/write (best-effort, never poisons the originating transaction) - Cron (every 5 min) — added in Task 25 The MV is created in the model's init() (Odoo calls this on install/upgrade). The SQL DDL is idempotent (CREATE MATERIALIZED VIEW IF NOT EXISTS / CREATE INDEX IF NOT EXISTS) and includes a UNIQUE(id) index so REFRESH MATERIALIZED VIEW CONCURRENTLY is supported. _refresh() falls back to a blocking refresh on the first call after creation. Made-with: Cursor
9 lines
324 B
Python
9 lines
324 B
Python
from . import fusion_reconcile_pattern
|
|
from . import fusion_reconcile_precedent
|
|
from . import fusion_reconcile_suggestion
|
|
from . import fusion_bank_rec_widget
|
|
from . import account_bank_statement_line
|
|
from . import account_reconcile_model
|
|
from . import fusion_reconcile_engine
|
|
from . import fusion_unreconciled_bank_line_mv
|