Account Move (Invoice) Lines¶
This page documents how to use the manager and record objects for account move (invoice) lines.
Details¶
Name | Value |
---|---|
Odoo Modules | Accounting, OpenStack Integration |
Odoo Model Name | account.move.line |
Manager | account_move_lines |
Record Type | AccountMoveLine |
Manager¶
The account move (invoice) line manager is available as the account_move_lines
attribute on the Odoo client object.
>>> from openstack_odooclient import Client as OdooClient
>>> odoo_client = OdooClient(
... hostname="localhost",
... port=8069,
... protocol="jsonrpc",
... database="odoodb",
... user="test-user",
... password="<password>",
... )
>>> odoo_client.account_move_lines.get(1234)
AccountMoveLine(record={'id': 1234, ...}, fields=None)
For more information on how to use managers, refer to Managers.
Record¶
The account move (invoice) line manager returns AccountMoveLine
record objects.
To import the record class for type hinting purposes:
The record class currently implements the following fields and methods.
For more information on attributes and methods common to all record types, see Record Attributes and Methods.
currency_id
¶
The ID for the currency used in this account move (invoice) line.
currency_name
¶
The name of the currency used in this account move (invoice) line.
currency
¶
The currency used in this account move (invoice) line.
This fetches the full record from Odoo once, and caches it for subsequent accesses.
line_tax_amount
¶
Amount charged in tax on the account move (invoice) line.
move_id
¶
The ID for the account move (invoice) this line is part of.
move_name
¶
The name of the account move (invoice) this line is part of.
move
¶
The account move (invoice) this line is part of.
This fetches the full record from Odoo once, and caches it for subsequent accesses.
name
¶
Name of the product charged on the account move (invoice) line.
os_project_id
¶
The ID for the OpenStack project this account move (invoice) line was generated for.
os_project_name
¶
The name of the OpenStack project this account move (invoice) line was generated for.
os_project
¶
The OpenStack project this account move (invoice) line was generated for.
This fetches the full record from Odoo once, and caches it for subsequent accesses.
os_region
¶
The OpenStack region the account move (invoice) line was created from.
os_resource_id
¶
The OpenStack resource ID for the resource that generated this account move (invoice) line.
os_resource_name
¶
The name of the OpenStack resource tier or flavour, as used by services such as Distil for rating purposes.
For example, if this is the account move (invoice) line for a compute instance, this would be set to the instance's flavour name.
os_resource_type
¶
A human-readable description of the type of resource captured by this account move (invoice) line.
price_subtotal
¶
Amount charged for the product (untaxed) on the account move (invoice) line.
price_unit
¶
Unit price for the product used on the account move (invoice) line.
product_id
¶
The ID for the product charged on the account move (invoice) line.
product_name
¶
The name of the product charged on the account move (invoice) line.
product
¶
The product charged on the account move (invoice) line.
This fetches the full record from Odoo once, and caches it for subsequent accesses.
quantity
¶
Quantity of product charged on the account move (invoice) line.