Skip to content
Health
70/100
fair
  • Security25/25
    No findings
  • Activity25/25
    Last human commit 3 months ago
  • Required by15/25
    1 module depends on it
  • Maturity5/25
    In 1 Odoo series since 16.0

Heuristic over the facts below, not an audit · How it's computed

Security findings
Grave / minor (static analysis)
Required by
1
Modules depending on it
External deps
0 pip · 0 bin
Python packages / system binaries
License
AGPL-3
No conflicts with its dependencies
Folder size
0.21 MB
Module directory on disk
Code analysis 1 migration note 4 models 3 views 0 HTTP endpoints

Description

This module extends the UBL vendor bill import process to improve how vendor bill lines are linked to purchase order lines.

Instead of replacing the imported UBL lines with the purchase order lines (standard behavior), this module:

  1. Reads the OrderReference in the UBL document.

  2. Identifies the corresponding Purchase Order using the vendor reference (partner_ref) or the purchase order ref.

  3. Matches each UBL line with a purchase order line based on:

    • product name,
    • supplier product name
  4. Links the vendor bill line to the matched PO line

  5. When a user manually selects a purchase order line from the bill:

    • the system stores the supplier product name,
    • future imports will auto-match using that supplier information.

This ensures accurate line-level linking while preserving the supplier’s invoice data.

Dependencies

Odoo dependencies
Python dependencies
None
System dependencies
None
Required by
account_edi_ubl_cii_purchase_match_product_packaging

Code analysis

Extracted from the source by best-effort static analysis (no code is executed); details may be incomplete.

Views touched 3

XML IDNameModelTypeStatus
account_move_form_view account.move form Inherits account.view_move_form
account_move_line_select_purchase_line_wizard_form_view account.move.line.select.purchase.line.wizard form New
purchase_order_line_form_view purchase.order.line form Inherits purchase.purchase_order_line_form2

HTTP endpoints 0

No HTTP endpoints found for this module.

Models touched 4

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (8)
  • purchase_mismatch Boolean
    compute='_compute_purchase_mismatch' help='Checked when this invoice has at least one line that does not fully match its related purchase order line.'
  • purchase_mismatch_details Text
    compute='_compute_purchase_mismatch' help='Human-readable description of the differences between invoice lines and their related purchase order lines.'
  • purchase_other_mismatch Boolean
    compute='_compute_purchase_mismatch' help='Checked when this invoice has at least one line with a non-quantity mismatch against its related purchase order line.'
  • purchase_other_mismatch_count Integer
    compute='_compute_purchase_mismatch' help='Number of invoice lines with non-quantity mismatches.'
  • purchase_other_mismatch_summary Char
    compute='_compute_purchase_mismatch' help='Short summary of non-quantity mismatches.'
  • purchase_quantity_mismatch Boolean
    compute='_compute_purchase_mismatch' help='Checked when this invoice has at least one line with a quantity mismatch against its related purchase order line.'
  • purchase_quantity_mismatch_count Integer
    compute='_compute_purchase_mismatch' help='Number of invoice lines with quantity mismatches.'
  • purchase_quantity_mismatch_summary Char
    compute='_compute_purchase_mismatch' help='Short summary of quantity mismatches.'
Public methods (0)

No public methods.

New fields (7)
  • purchase_line_mismatch Boolean
    compute='_compute_purchase_line_mismatch' help='Checked when this invoice line does not fully match its related purchase order line.'
  • purchase_line_mismatch_summary Char
    compute='_compute_purchase_line_mismatch' help='Short description of the purchase order matching issue.'
  • purchase_line_other_mismatch Boolean
    compute='_compute_purchase_line_mismatch' help='Checked when this invoice line has a non-quantity mismatch with its related purchase order line.'
  • purchase_line_other_mismatch_details Text
    compute='_compute_purchase_line_mismatch' help='Human-readable description of the non-quantity differences between this invoice line and the related purchase order line.'
  • purchase_line_quantity_mismatch Boolean
    compute='_compute_purchase_line_mismatch' help='Checked when this invoice line has a quantity mismatch with its related purchase order line.'
  • purchase_line_quantity_mismatch_details Text
    compute='_compute_purchase_line_mismatch' help='Human-readable description of the quantity differences between this invoice line and the related purchase order line.'
  • supplier_product_code Char
    readonly=True
Public methods (3)
  • action_select_purchase_line(self)
  • action_show_purchase_line(self)
  • action_show_purchase_line_mismatch_details(self)

New fields (16)
  • currency_id Many2one
    related='move_line_id.currency_id'
  • description Char
    related='move_line_id.name'
  • move_line_id Many2one → account.move.line
    comodel_name='account.move.line' readonly=True required=True
  • move_line_price_subtotal Monetary
    related='move_line_id.price_subtotal' string='Move line Subtotal'
  • move_line_price_unit Float
    related='move_line_id.price_unit' string='Move line Unit Price'
  • move_line_quantity Float
    related='move_line_id.quantity'
  • partner_id Many2one → res.partner
    comodel_name='res.partner' readonly=True
  • po_line_price_subtotal Monetary
    related='purchase_order_line_id.price_subtotal' string='PO line Subtotal'
  • po_line_price_unit Float
    related='purchase_order_line_id.price_unit' string='PO line Unit Price'
  • po_line_product_uom_qty Float
    related='purchase_order_line_id.product_uom_qty' string='Ordered Qty'
  • po_line_qty_invoiced Float
    related='purchase_order_line_id.qty_invoiced'
  • po_line_qty_received Float
    related='purchase_order_line_id.qty_received'
  • product_domain Binary
    compute='_compute_product_domain'
  • product_id Many2one → product.product
    comodel_name='product.product' domain='product_domain'
  • purchase_order_ids Many2many → purchase.order
    comodel_name='purchase.order' domain="[('partner_id', '=', partner_id), ('state', 'in', ('purchase', 'done'))]" relation='account_move_line_purchase_match_wizard_rel'
  • purchase_order_line_id Many2one → purchase.order.line
    comodel_name='purchase.order.line' compute='_compute_purchase_order_line_id' domain="[('order_id', 'in', purchase_order_ids), ('product_id', '=', product_id)]" readonly=False store=True string='Line'
Public methods (1)
  • select_purchase_line(self)