Odoo Mindscape. Understand Odoo faster. Explore modules, fields, dependencies and version differences in one place instead of digging through the source code.

Module: Account Payment Batch OCA

Entity: account.payment.line

Compute Method: _compute_payment_line

Inputs Method Outputs
for line in self:
            communication = False
            communication_type = "free"
            currency_id = line.company_id.currency_id.id
            amount_currency = 0.0
            move_line = line.move_line_id
            partner_id = False
            if move_line and move_line.partner_id:
                partner_id = move_line.partner_id.id
                communication_type = move_line.move_id.reference_type
                communication = (
                    move_line.move_id._get_payment_order_communication_full()
                )
                currency_id = move_line.currency_id.id
                amount_currency = move_line.amount_residual_currency
                if line.order_id.payment_type == "outbound":
                    amount_currency *= -1
            line.communication = communication
            line.communication_type = communication_type
            line.currency_id = currency_id
            line.amount_currency = amount_currency
            line.partner_id = partner_id

Back to entity