Sales Expense

sale_expense
REPOSITORY
REPOSITORYodoo/odoo
GIT
GIThttps://github.com/odoo/odoo.git
GIT FOLDER
GIT FOLDERhttps://github.com/odoo/odoo/tree/19.0/sale_expense
VERSION
VERSION 1.0
CATEGORY
CATEGORYSales/Sales
LICENSE
LICENSELGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLEYes
AUTHORS
AUTHORSOdoo S.A.
MAINTAINERS
MAINTAINERSOdoo S.A.
COMMITTERS
COMMITTERSRaphael Collet, Odoo Translation Bot, Julien Castiaux, Victor Feyens, Andrea Grazioso (agr-odoo), Tiffany Chang (tic), Gorash, Mathieu Duckerts-Antoine, Victor Piryns (pivi), Thomas Becquevort (thbe), Dylan Kiss (dyki), Julien Alardot (jual), yosa-odoo, kcv-odoo, Léo Gizard, Logan Staelens, Mohammad Abdulmoneim (abdu), Michaël Mattiello, Corentin Lombard, Krzysztof Magusiak (krma), hatr-odoo, Harrison Hutton, Abo Taha
WEBSITE
WEBSITE
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 01:51:46
ODOO DEPENDENCIES
ODOO DEPENDENCIES odoo/odoo:
    - sale_management
    - sale
    - sales_team
    - base
    - mail
    - base_setup
    - web
    - bus
    - web_tour
    - html_editor
    - account_payment
    - account
    - onboarding
    - product
    - uom
    - analytic
    - portal
    - http_routing
    - auth_signup
    - digest
    - resource
    - payment
    - utm
    - hr_expense
    - hr
    - phone_validation
    - resource_mail
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION
Reinvoice Employee Expense
==========================

Create some products for which you can re-invoice the costs.
This module allow to reinvoice employee expense, by setting the SO directly on the expense.

Code Analysis

Views touched (7)
XML IDNameModelTypeStatus
hr_expense_form_view_inherit_sale_expense hr.expense.form.inherit.sale.expense hr.expense button Inherits hr_expense.hr_expense_view_form
hr_expense_split_view_inherit_sale_expense hr.expense.split.view.inherit.sale.expense hr.expense.split.wizard xpath Inherits hr_expense.hr_expense_split
hr_expense_tree_view_inherit_sale_expense hr.expense.list.inherit.sale.expense hr.expense xpath Inherits hr_expense.view_expenses_tree
product_product_view_form_inherit_sale_expense product.template.expense product.product xpath Inherits hr_expense.product_product_expense_form_view
product_product_view_list_inherit_sale_expense product.product.view.list.inherit.sale.expense product.product xpath Inherits hr_expense.product_product_expense_categories_tree_view
sale_order_form_view_inherit sale.order.form.inherit.sale.expense sale.order button Inherits sale.view_order_form
sale_order_reinvoice_tree_view sale.order.list.reinvoice.expense sale.order field Inherits sale.sale_order_tree
Models touched (7)

New fields (0)

No new fields.

Public methods (2)
  • button_draft(self)
  • unlink(self)

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (3)
  • can_be_reinvoiced Boolean
    compute='_compute_can_be_reinvoiced' args: 'Can be reinvoiced'
  • sale_order_id Many2one → sale.order
    check_company=True compute='_compute_sale_order_id' domain="[('state', '=', 'sale')]" help='If the category has an expense policy, it will be reinvoiced on this sales order' index='btree_not_null' readonly=False store=True string='Customer to Reinvoice' tracking=True args: 'sale.order'
  • sale_order_line_id Many2one → sale.order.line
    comodel_name='sale.order.line' compute='_compute_sale_order_id' index='btree_not_null' readonly=True store=True
Public methods (2)
  • action_open_sale_order(self)
  • action_post(self)

New fields (2)
  • can_be_reinvoiced Boolean
    compute='_compute_can_be_reinvoiced' args: 'Can be reinvoiced'
  • sale_order_id Many2one → sale.order
    compute='_compute_sale_order_id' domain="[('state', '=', 'sale'), ('company_id', '=', company_id)]" readonly=False store=True string='Customer to Reinvoice' args: 'sale.order'
Public methods (0)

No public methods.

New fields (1)
  • expense_policy_tooltip Char
    compute='_compute_expense_policy_tooltip'
Public methods (0)

No public methods.

New fields (2)
  • expense_count Integer
    compute='_compute_expense_count' compute_sudo=True args: '# of Expenses'
  • expense_ids One2many → hr.expense
    comodel_name='hr.expense' domain=[('state', 'in', ('posted', 'in_payment', 'paid'))] inverse_name='sale_order_id' readonly=True string='Expenses'
Public methods (0)

No public methods.

New fields (1)
  • expense_ids One2many → hr.expense
    comodel_name='hr.expense' inverse_name='sale_order_line_id' readonly=True string='Expenses'
Public methods (0)

No public methods.

REPOSITORY
REPOSITORYodoo/odoo
GIT
GIThttps://github.com/odoo/odoo.git
GIT FOLDER
GIT FOLDERhttps://github.com/odoo/odoo/tree/18.0/sale_expense
VERSION
VERSION 1.0
CATEGORY
CATEGORYSales/Sales
LICENSE
LICENSELGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLEYes
AUTHORS
AUTHORS
MAINTAINERS
MAINTAINERS
COMMITTERS
COMMITTERSRaphael Collet, Odoo Translation Bot, Martin Trigaux, Odoo Online, Tiffany Chang (tic), Gorash, william-andre, Louis Wicket (wil), Maximilien (malb), Victor Piryns (pivi), Thomas Becquevort (thbe), Gauthier Wala (gawa), Dylan Kiss (dyki), Julien Alardot (jual), Sarah Bellefroid, Hesham, Ethan Vincent, Maxime de Neuville, yosa-odoo, kcv-odoo, Louis (wil), Logan Staelens, Corentin Lombard, Krzysztof Magusiak (krma)
WEBSITE
WEBSITE
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 01:25:59
ODOO DEPENDENCIES
ODOO DEPENDENCIES odoo/odoo:
    - sale_management
    - sale
    - sales_team
    - base
    - mail
    - base_setup
    - web
    - bus
    - web_tour
    - html_editor
    - account_payment
    - account
    - onboarding
    - product
    - uom
    - analytic
    - portal
    - web_editor
    - http_routing
    - auth_signup
    - digest
    - resource
    - payment
    - utm
    - hr_expense
    - hr
    - phone_validation
    - resource_mail
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION
Reinvoice Employee Expense
==========================

Create some products for which you can re-invoice the costs.
This module allow to reinvoice employee expense, by setting the SO directly on the expense.

Code Analysis

Views touched (8)
XML IDNameModelTypeStatus
hr_expense_form_view_inherit_sale_expense hr.expense.form.inherit.sale.expense hr.expense xpath Inherits hr_expense.hr_expense_view_form
hr_expense_sheet_form_view_inherit_sale_expense hr.expense.sheet.form.inherit.sale.expense hr.expense.sheet xpath Inherits hr_expense.view_hr_expense_sheet_form
hr_expense_sheet_view_form hr.expense.sheet.view.form.inherit.sale.expense hr.expense.sheet button Inherits hr_expense.view_hr_expense_sheet_form
hr_expense_split_view_inherit_sale_expense hr.expense.split.view.inherit.sale.expense hr.expense.split.wizard xpath Inherits hr_expense.hr_expense_split
hr_expense_tree_view_inherit_sale_expense hr.expense.list.inherit.sale.expense hr.expense xpath Inherits hr_expense.view_expenses_tree
product_product_view_form_inherit_sale_expense product.template.expense product.product xpath Inherits hr_expense.product_product_expense_form_view
product_product_view_list_inherit_sale_expense product.product.view.list.inherit.sale.expense product.product xpath Inherits hr_expense.product_product_expense_categories_tree_view
sale_order_form_view_inherit sale.order.form.inherit.sale.expense sale.order data Inherits sale.view_order_form
Models touched (7)

New fields (0)

No new fields.

Public methods (1)
  • button_draft(self)

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (2)
  • can_be_reinvoiced Boolean
    compute='_compute_can_be_reinvoiced' args: 'Can be reinvoiced'
  • sale_order_id Many2one → sale.order
    compute='_compute_sale_order_id' domain="[('state', '=', 'sale'), ('company_id', '=', company_id)]" help='If the category has an expense policy, it will be reinvoiced on this sales order' index='btree_not_null' readonly=False store=True string='Customer to Reinvoice' tracking=True args: 'sale.order'
Public methods (0)

No public methods.

New fields (1)
  • sale_order_count Integer
    compute='_compute_sale_order_count'
Public methods (2)
  • action_open_sale_orders(self)
  • action_reset_expense_sheets(self)

New fields (2)
  • can_be_reinvoiced Boolean
    compute='_compute_can_be_reinvoiced' args: 'Can be reinvoiced'
  • sale_order_id Many2one → sale.order
    compute='_compute_sale_order_id' domain="[('state', '=', 'sale'), ('company_id', '=', company_id)]" readonly=False store=True string='Customer to Reinvoice' args: 'sale.order'
Public methods (1)
  • default_get(self, fields)

New fields (1)
  • expense_policy_tooltip Char
    compute='_compute_expense_policy_tooltip'
Public methods (0)

No public methods.

New fields (2)
  • expense_count Integer
    compute='_compute_expense_count' compute_sudo=True args: '# of Expenses'
  • expense_ids One2many → hr.expense
    copy=False domain=[('state', '=', 'done')] readonly=True string='Expenses' args: 'hr.expense', 'sale_order_id'
Public methods (0)

No public methods.

REPOSITORY
REPOSITORYodoo/odoo
GIT
GIThttps://github.com/odoo/odoo.git
GIT FOLDER
GIT FOLDERhttps://github.com/odoo/odoo/tree/17.0/sale_expense
VERSION
VERSION 1.0
CATEGORY
CATEGORYSales/Sales
LICENSE
LICENSELGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLEYes
AUTHORS
AUTHORS
MAINTAINERS
MAINTAINERS
COMMITTERS
COMMITTERSRaphael Collet, Odoo Translation Bot, Martin Trigaux, Damien Bouvy, Odoo Online, Victor Feyens, Andrea Grazioso (agr-odoo), oco-odoo, Tiffany Chang (tic), Rémy Voet (ryv), Gorash, Demesmaeker, Louis Wicket (wil), Thomas Becquevort (thbe), Dylan Kiss (dyki), Julien Alardot (jual), Michael (mcm), Preksha Chouhan, Sarah Bellefroid, Ethan Vincent, det, Julien Carion (juca), Louis (wil), Bastien PIERRE
WEBSITE
WEBSITE
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 01:02:10
ODOO DEPENDENCIES
ODOO DEPENDENCIES odoo/odoo:
    - sale_management
    - sale
    - sales_team
    - base
    - mail
    - base_setup
    - web
    - bus
    - web_tour
    - account_payment
    - account
    - onboarding
    - product
    - uom
    - analytic
    - portal
    - web_editor
    - http_routing
    - auth_signup
    - digest
    - resource
    - payment
    - utm
    - hr_expense
    - hr
    - phone_validation
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION
Reinvoice Employee Expense
==========================

Create some products for which you can re-invoice the costs.
This module allow to reinvoice employee expense, by setting the SO directly on the expense.

Code Analysis

Views touched (8)
XML IDNameModelTypeStatus
hr_expense_form_view_inherit_sale_expense hr.expense.form.inherit.sale.expense hr.expense xpath Inherits hr_expense.hr_expense_view_form
hr_expense_sheet_form_view_inherit_sale_expense hr.expense.sheet.form.inherit.sale.expense hr.expense.sheet xpath Inherits hr_expense.view_hr_expense_sheet_form
hr_expense_sheet_view_form hr.expense.sheet.view.form.inherit.sale.expense hr.expense.sheet button Inherits hr_expense.view_hr_expense_sheet_form
hr_expense_split_view_inherit_sale_expense hr.expense.split.view.inherit.sale.expense hr.expense.split.wizard xpath Inherits hr_expense.hr_expense_split
hr_expense_tree_view_inherit_sale_expense hr.expense.tree.inherit.sale.expense hr.expense xpath Inherits hr_expense.view_expenses_tree
product_product_view_form_inherit_sale_expense product.template.expense product.product xpath Inherits hr_expense.product_product_expense_form_view
product_product_view_list_inherit_sale_expense product.product.view.list.inherit.sale.expense product.product xpath Inherits hr_expense.product_product_expense_categories_tree_view
sale_order_form_view_inherit sale.order.form.inherit.sale.expense sale.order data Inherits sale.view_order_form
Models touched (7)

New fields (0)

No new fields.

Public methods (1)
  • button_draft(self)

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (2)
  • can_be_reinvoiced Boolean
    compute='_compute_can_be_reinvoiced' args: 'Can be reinvoiced'
  • sale_order_id Many2one → sale.order
    compute='_compute_sale_order_id' domain="[('state', '=', 'sale'), ('company_id', '=', company_id)]" help='If the category has an expense policy, it will be reinvoiced on this sales order' readonly=False store=True string='Customer to Reinvoice' tracking=True args: 'sale.order'
Public methods (0)

No public methods.

New fields (1)
  • sale_order_count Integer
    compute='_compute_sale_order_count'
Public methods (2)
  • action_open_sale_orders(self)
  • action_reset_expense_sheets(self)

New fields (2)
  • can_be_reinvoiced Boolean
    compute='_compute_can_be_reinvoiced' args: 'Can be reinvoiced'
  • sale_order_id Many2one → sale.order
    compute='_compute_sale_order_id' domain="[('state', '=', 'sale'), ('company_id', '=', company_id)]" readonly=False store=True string='Customer to Reinvoice' args: 'sale.order'
Public methods (1)
  • default_get(self, fields)

New fields (1)
  • expense_policy_tooltip Char
    compute='_compute_expense_policy_tooltip'
Public methods (0)

No public methods.

New fields (2)
  • expense_count Integer
    compute='_compute_expense_count' compute_sudo=True args: '# of Expenses'
  • expense_ids One2many → hr.expense
    copy=False domain=[('state', '=', 'done')] readonly=True string='Expenses' args: 'hr.expense', 'sale_order_id'
Public methods (0)

No public methods.

REPOSITORY
REPOSITORYodoo/odoo
GIT
GIThttps://github.com/odoo/odoo.git
GIT FOLDER
GIT FOLDERhttps://github.com/odoo/odoo/tree/16.0/sale_expense
VERSION
VERSION 1.0
CATEGORY
CATEGORYSales/Sales
LICENSE
LICENSELGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLEYes
AUTHORS
AUTHORS
MAINTAINERS
MAINTAINERS
COMMITTERS
COMMITTERSRaphael Collet, Odoo Translation Bot, Martin Trigaux, Denis Ledoux, Yannick Tivisse, Victor Feyens, Andrea Grazioso (agr-odoo), Kevin Baptiste, Jacky (trj), sofiagvaladze, william-andre, william, Thomas Becquevort (thbe), Julien Alardot (jual), Michael (mcm), Sarah Bellefroid, yosa-odoo, det, Martin Trigaux (mat)
WEBSITE
WEBSITE
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:40:54
ODOO DEPENDENCIES
ODOO DEPENDENCIES odoo/odoo:
    - sale_management
    - sale
    - sales_team
    - base
    - mail
    - base_setup
    - web
    - bus
    - web_tour
    - account_payment
    - account
    - product
    - uom
    - analytic
    - portal
    - web_editor
    - http_routing
    - auth_signup
    - digest
    - resource
    - payment
    - utm
    - hr_expense
    - hr_contract
    - hr
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION
Reinvoice Employee Expense
==========================

Create some products for which you can re-invoice the costs.
This module allow to reinvoice employee expense, by setting the SO directly on the expense.

Code Analysis

Views touched (8)
XML IDNameModelTypeStatus
hr_expense_form_view_inherit_sale_expense hr.expense.form.inherit.sale.expense hr.expense xpath Inherits hr_expense.hr_expense_view_form
hr_expense_sheet_form_view_inherit_sale_expense hr.expense.sheet.form.inherit.sale.expense hr.expense.sheet xpath Inherits hr_expense.view_hr_expense_sheet_form
hr_expense_sheet_view_form hr.expense.sheet.view.form.inherit.sale.expense hr.expense.sheet button Inherits hr_expense.view_hr_expense_sheet_form
hr_expense_split_view_inherit_sale_expense hr.expense.split.view.inherit.sale.expense hr.expense.split.wizard xpath Inherits hr_expense.hr_expense_split
hr_expense_tree_view_inherit_sale_expense hr.expense.tree.inherit.sale.expense hr.expense xpath Inherits hr_expense.view_expenses_tree
product_product_view_form_inherit_sale_expense product.template.expense product.product xpath Inherits hr_expense.product_product_expense_form_view
product_product_view_list_inherit_sale_expense product.product.view.list.inherit.sale.expense product.product xpath Inherits hr_expense.product_product_expense_categories_tree_view
sale_order_form_view_inherit sale.order.form.inherit.sale.expense sale.order data Inherits sale.view_order_form
Models touched (7)

New fields (1)
  • expense_sheet_id One2many → hr.expense.sheet
    comodel_name='hr.expense.sheet' inverse_name='account_move_id' readonly=True string='Expense Sheet'
Public methods (1)
  • button_draft(self)

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (2)
  • can_be_reinvoiced Boolean
    compute='_compute_can_be_reinvoiced' args: 'Can be reinvoiced'
  • sale_order_id Many2one → sale.order
    compute='_compute_sale_order_id' domain="[('state', '=', 'sale'), ('company_id', '=', company_id)]" help='If the category has an expense policy, it will be reinvoiced on this sales order' readonly=False states={'done': [('readonly', True)], 'refused': [('readonly', True)]} store=True string='Customer to Reinvoice' tracking=True args: 'sale.order'
Public methods (1)
  • action_move_create(self)
    When posting expense, if the AA is given, we will track cost in that If a SO is set, this means we want to reinvoice the expense. But to do so, we need the analytic entries to be generated, so a AA is required to reinvoice. So, we ensure the AA if a SO is given.

New fields (1)
  • sale_order_count Integer
    compute='_compute_sale_order_count'
Public methods (2)
  • action_open_sale_orders(self)
  • reset_expense_sheets(self)

New fields (2)
  • can_be_reinvoiced Boolean
    compute='_compute_can_be_reinvoiced' args: 'Can be reinvoiced'
  • sale_order_id Many2one → sale.order
    compute='_compute_sale_order_id' domain="[('state', '=', 'sale'), ('company_id', '=', company_id)]" readonly=False store=True string='Customer to Reinvoice' args: 'sale.order'
Public methods (1)
  • default_get(self, fields)

New fields (1)
  • expense_policy_tooltip Char
    compute='_compute_expense_policy_tooltip'
Public methods (0)

No public methods.

New fields (2)
  • expense_count Integer
    compute='_compute_expense_count' compute_sudo=True args: '# of Expenses'
  • expense_ids One2many → hr.expense
    copy=False domain=[('state', '=', 'done')] readonly=True string='Expenses' args: 'hr.expense', 'sale_order_id'
Public methods (0)

No public methods.

REPOSITORY
REPOSITORYodoo/odoo
GIT
GIThttps://github.com/odoo/odoo.git
GIT FOLDER
GIT FOLDERhttps://github.com/odoo/odoo/tree/15.0/sale_expense
VERSION
VERSION 1.0
CATEGORY
CATEGORYSales/Sales
LICENSE
LICENSELGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLEYes
AUTHORS
AUTHORS
MAINTAINERS
MAINTAINERS
COMMITTERS
COMMITTERSOdoo Translation Bot, Martin Trigaux, Barad Mahendra, Yannick Tivisse, Xavier-Do, Julien Mougenot, Tiffany Chang (tic), jdoutreloux, sofiagvaladze, william-andre, Jinjiu Liu, Julien Alardot (jual), Kartik Chavda
WEBSITE
WEBSITE
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:25:30
ODOO DEPENDENCIES
ODOO DEPENDENCIES odoo/odoo:
    - sale_management
    - sale
    - sales_team
    - base
    - mail
    - base_setup
    - web
    - bus
    - web_tour
    - payment
    - account
    - product
    - uom
    - analytic
    - portal
    - web_editor
    - http_routing
    - auth_signup
    - digest
    - resource
    - utm
    - hr_expense
    - hr_contract
    - hr
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION
Reinvoice Employee Expense
==========================

Create some products for which you can re-invoice the costs.
This module allow to reinvoice employee expense, by setting the SO directly on the expense.

Code Analysis

Views touched (7)
XML IDNameModelTypeStatus
hr_expense_form_view_inherit_account_manager hr.expense.form.inherit.sale.expense hr.expense xpath Inherits sale_expense.hr_expense_form_view_inherit_sale_expense
hr_expense_form_view_inherit_sale_expense hr.expense.form.inherit.sale.expense hr.expense xpath Inherits hr_expense.hr_expense_view_form
hr_expense_form_view_inherit_saleman hr.expense.form.inherit.saleman hr.expense xpath Inherits sale_expense.hr_expense_form_view_inherit_sale_expense
hr_expense_sheet_form_view_inherit_sale_expense hr.expense.sheet.form.inherit.sale.expense hr.expense.sheet xpath Inherits hr_expense.view_hr_expense_sheet_form
hr_expense_tree_view_inherit_sale_expense hr.expense.tree.inherit.sale.expense hr.expense xpath Inherits hr_expense.view_expenses_tree
product_product_view_form_inherit_sale_expense product.template.expense product.product xpath Inherits hr_expense.product_product_expense_form_view
sale_order_form_view_inherit sale.order.form.inherit.sale.expense sale.order data Inherits sale.view_order_form
Models touched (6)

New fields (1)
  • expense_sheet_id One2many → hr.expense.sheet
    comodel_name='hr.expense.sheet' inverse_name='account_move_id' readonly=True string='Expense Sheet'
Public methods (1)
  • button_draft(self)

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (3)
  • analytic_account_id Many2one
    compute='_compute_analytic_account_id' readonly=False store=True
  • can_be_reinvoiced Boolean
    compute='_compute_can_be_reinvoiced' args: 'Can be reinvoiced'
  • sale_order_id Many2one → sale.order
    compute='_compute_sale_order_id' domain="[('state', '=', 'sale'), ('company_id', '=', company_id)]" help='If the category has an expense policy, it will be reinvoiced on this sales order' readonly=False states={'done': [('readonly', True)], 'refused': [('readonly', True)]} store=True string='Customer to Reinvoice' tracking=True args: 'sale.order'
Public methods (1)
  • action_move_create(self)
    When posting expense, if the AA is given, we will track cost in that If a SO is set, this means we want to reinvoice the expense. But to do so, we need the analytic entries to be generated, so a AA is required to reinvoice. So, we ensure the AA if a SO is given.

New fields (0)

No new fields.

Public methods (1)
  • reset_expense_sheets(self)

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (2)
  • expense_count Integer
    compute='_compute_expense_count' compute_sudo=True args: '# of Expenses'
  • expense_ids One2many → hr.expense
    copy=False domain=[('state', '=', 'done')] readonly=True string='Expenses' args: 'hr.expense', 'sale_order_id'
Public methods (0)

No public methods.

REPOSITORY
REPOSITORYodoo/odoo
GIT
GIThttps://github.com/odoo/odoo.git
GIT FOLDER
GIT FOLDERhttps://github.com/odoo/odoo/tree/14.0/sale_expense
VERSION
VERSION 1.0
CATEGORY
CATEGORYSales/Sales
LICENSE
LICENSELGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLEYes
AUTHORS
AUTHORS
MAINTAINERS
MAINTAINERS
COMMITTERS
COMMITTERSOdoo Translation Bot, Martin Trigaux, Olivier Dony, Thibault Delavallée, Christophe Simonis, Goffin Simon, Yannick Tivisse, Laurent Smet, Julien Castiaux, Xavier-Do, Julien Mougenot, Anh Thao Pham (pta), jbm-odoo, Kevin Baptiste, jdoutreloux, lbs-odoo
WEBSITE
WEBSITE
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:14:31
ODOO DEPENDENCIES
ODOO DEPENDENCIES odoo/odoo:
    - sale_management
    - sale
    - sales_team
    - base
    - mail
    - base_setup
    - web
    - bus
    - web_tour
    - payment
    - account
    - product
    - uom
    - analytic
    - portal
    - web_editor
    - http_routing
    - auth_signup
    - digest
    - resource
    - utm
    - hr_expense
    - hr_contract
    - hr
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION
Reinvoice Employee Expense
==========================

Create some products for which you can re-invoice the costs.
This module allow to reinvoice employee expense, by setting the SO directly on the expense.

Code Analysis

Views touched (9)
XML IDNameModelTypeStatus
assets_backend assets_backend ir.ui.view qweb Inherits web.assets_backend
hr_expense_form_view_inherit_account_manager hr.expense.form.inherit.sale.expense hr.expense xpath Inherits sale_expense.hr_expense_form_view_inherit_sale_expense
hr_expense_form_view_inherit_sale_expense hr.expense.form.inherit.sale.expense hr.expense xpath Inherits hr_expense.hr_expense_view_form
hr_expense_form_view_inherit_saleman hr.expense.form.inherit.saleman hr.expense xpath Inherits sale_expense.hr_expense_form_view_inherit_sale_expense
hr_expense_sheet_form_view_inherit_sale_expense hr.expense.sheet.form.inherit.sale.expense hr.expense.sheet xpath Inherits hr_expense.view_hr_expense_sheet_form
hr_expense_tree_view_inherit_sale_expense hr.expense.tree.inherit.sale.expense hr.expense xpath Inherits hr_expense.view_expenses_tree
product_product_view_form_inherit_sale_expense product.template.expense product.product xpath Inherits hr_expense.product_product_expense_form_view
qunit_suite qunit_suite ir.ui.view qweb Inherits web.qunit_suite_tests
sale_order_form_view_inherit sale.order.form.inherit.sale.expense sale.order data Inherits sale.view_order_form
Models touched (4)

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (3)
  • analytic_account_id Many2one
    compute='_compute_analytic_account_id' readonly=False store=True
  • can_be_reinvoiced Boolean
    compute='_compute_can_be_reinvoiced' args: 'Can be reinvoiced'
  • sale_order_id Many2one → sale.order
    compute='_compute_sale_order_id' domain="[('state', '=', 'sale'), ('company_id', '=', company_id)]" help='If the product has an expense policy, it will be reinvoiced on this sales order' readonly=False states={'approved': [('readonly', True)], 'done': [('readonly', True)], 'refused': [('readonly', True)]} store=True string='Customer to Reinvoice' tracking=True args: 'sale.order'
Public methods (1)
  • action_move_create(self)
    When posting expense, if the AA is given, we will track cost in that If a SO is set, this means we want to reinvoice the expense. But to do so, we need the analytic entries to be generated, so a AA is required to reinvoice. So, we ensure the AA if a SO is given.

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (2)
  • expense_count Integer
    compute='_compute_expense_count' compute_sudo=True args: '# of Expenses'
  • expense_ids One2many → hr.expense
    copy=False domain=[('state', '=', 'done')] readonly=True string='Expenses' args: 'hr.expense', 'sale_order_id'
Public methods (0)

No public methods.

REPOSITORY
REPOSITORYodoo/odoo
GIT
GIThttps://github.com/odoo/odoo.git
GIT FOLDER
GIT FOLDERhttps://github.com/odoo/odoo/tree/13.0/sale_expense
VERSION
VERSION 1.0
CATEGORY
CATEGORYSales/Sales
LICENSE
LICENSELGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLEYes
AUTHORS
AUTHORS
MAINTAINERS
MAINTAINERS
COMMITTERS
COMMITTERSOdoo Translation Bot, Martin Trigaux, Christophe Simonis, Goffin Simon, qdp-odoo, Damien Bouvy, Yannick Tivisse, jem-odoo, Adrian Torres, Aurélien Warnon, Xavier-Do, Parth Choksi, Hiral Bhavsar, jdoutreloux
WEBSITE
WEBSITE
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:06:44
ODOO DEPENDENCIES
ODOO DEPENDENCIES odoo/odoo:
    - sale_management
    - sale
    - sales_team
    - base
    - mail
    - base_setup
    - web
    - bus
    - web_tour
    - payment
    - account
    - product
    - uom
    - analytic
    - portal
    - web_editor
    - http_routing
    - auth_signup
    - digest
    - resource
    - utm
    - hr_expense
    - hr_contract
    - hr
    - mail_bot
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION
Reinvoice Employee Expense
==========================

Create some products for which you can re-invoice the costs.
This module allow to reinvoice employee expense, by setting the SO directly on the expense.

Code Analysis

Views touched (8)
XML IDNameModelTypeStatus
assets_backend assets_backend ir.ui.view qweb Inherits web.assets_backend
hr_expense_form_view_inherit_account_manager hr.expense.form.inherit.sale.expense hr.expense xpath Inherits sale_expense.hr_expense_form_view_inherit_sale_expense
hr_expense_form_view_inherit_sale_expense hr.expense.form.inherit.sale.expense hr.expense xpath Inherits hr_expense.hr_expense_view_form
hr_expense_form_view_inherit_saleman hr.expense.form.inherit.saleman hr.expense xpath Inherits sale_expense.hr_expense_form_view_inherit_sale_expense
hr_expense_sheet_form_view_inherit_sale_expense hr.expense.sheet.form.inherit.sale.expense hr.expense.sheet xpath Inherits hr_expense.view_hr_expense_sheet_form
product_product_view_form_inherit_sale_expense product.template.expense product.product xpath Inherits hr_expense.product_product_expense_form_view
qunit_suite qunit_suite ir.ui.view qweb Inherits web.qunit_suite
sale_order_form_view_inherit sale.order.form.inherit.sale.expense sale.order data Inherits sale.view_order_form
Models touched (4)

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (2)
  • can_be_reinvoiced Boolean
    compute='_compute_can_be_reinvoiced' args: 'Can be reinvoiced'
  • sale_order_id Many2one → sale.order
    domain="[('state', '=', 'sale'), ('company_id', '=', company_id)]" help='If the product has an expense policy, it will be reinvoiced on this sales order' readonly=True states={'draft': [('readonly', False)], 'reported': [('readonly', False)]} string='Reinvoice Customer' args: 'sale.order'
Public methods (1)
  • action_move_create(self)
    When posting expense, if the AA is given, we will track cost in that If a SO is set, this means we want to reinvoice the expense. But to do so, we need the analytic entries to be generated, so a AA is required to reinvoice. So, we ensure the AA if a SO is given.

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (2)
  • expense_count Integer
    compute='_compute_expense_count' compute_sudo=True args: '# of Expenses'
  • expense_ids One2many → hr.expense
    copy=False domain=[('state', '=', 'done')] readonly=True string='Expenses' args: 'hr.expense', 'sale_order_id'
Public methods (0)

No public methods.

REPOSITORY
REPOSITORYodoo/odoo
GIT
GIThttps://github.com/odoo/odoo.git
GIT FOLDER
GIT FOLDERhttps://github.com/odoo/odoo/tree/12.0/sale_expense
VERSION
VERSION 1.0
CATEGORY
CATEGORYSales
LICENSE
LICENSELGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLEYes
AUTHORS
AUTHORS
MAINTAINERS
MAINTAINERS
COMMITTERS
COMMITTERSOdoo Translation Bot, Martin Trigaux, Fabien Pinckaers, Thibault Delavallée, Christophe Simonis, Yannick Tivisse, jem-odoo, RomainLibert, Christophe Monniez, fda-odoo, XavierDo, Xavier-Do, Sébastien Theys
WEBSITE
WEBSITE
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-05 23:57:02
ODOO DEPENDENCIES
ODOO DEPENDENCIES odoo/odoo:
    - sale_management
    - sale
    - sales_team
    - base
    - mail
    - base_setup
    - web
    - bus
    - web_tour
    - payment
    - account
    - product
    - decimal_precision
    - uom
    - analytic
    - portal
    - http_routing
    - digest
    - hr_expense
    - hr_contract
    - hr
    - resource
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION
Reinvoice Employee Expense
==========================

Create some products for which you can re-invoice the costs.
This module allow to reinvoice employee expense, by setting the SO directly on the expense.

Code Analysis

Views touched (4)
XML IDNameModelTypeStatus
hr_expense_form_view_inherit_sale_expense hr.expense.form.inherit.sale.expense hr.expense xpath Inherits hr_expense.hr_expense_view_form
hr_expense_sheet_form_view_inherit_sale_expense hr.expense.sheet.form.inherit.sale.expense hr.expense.sheet xpath Inherits hr_expense.view_hr_expense_sheet_form
product_product_view_form_inherit_sale_expense product.template.expense product.product xpath Inherits hr_expense.product_product_expense_form_view
sale_order_form_view_inherit sale.order.form.inherit.sale.expense sale.order data Inherits sale.view_order_form
Models touched (3)

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (1)
  • sale_order_id Many2one → sale.order
    domain=[('state', '=', 'sale')] readonly=True states={'draft': [('readonly', False)], 'reported': [('readonly', False)]} string='Sale Order' args: 'sale.order'
Public methods (1)
  • action_move_create(self)
    @api.multi
    When posting expense, if a SO is set, this means you want to reinvoice. To do so, we have to set an Analytic Account on the expense. We choose the one from the SO, and if it does not exist, we generate it. Create AA even for product with no expense policy to keep track of the analytic.

New fields (2)
  • expense_count Integer
    compute='_compute_expense_count' compute_sudo=True args: '# of Expenses'
  • expense_ids One2many → hr.expense
    copy=False domain=[('state', '=', 'done')] readonly=True string='Expenses' args: 'hr.expense', 'sale_order_id'
Public methods (0)

No public methods.

REPOSITORY
REPOSITORYodoo/odoo
GIT
GIThttps://github.com/odoo/odoo.git
GIT FOLDER
GIT FOLDERhttps://github.com/odoo/odoo/tree/11.0/sale_expense
VERSION
VERSION 1.0
CATEGORY
CATEGORYSales
LICENSE
LICENSELGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLEYes
AUTHORS
AUTHORS
MAINTAINERS
MAINTAINERS
COMMITTERS
COMMITTERSOdoo Translation Bot, Martin Trigaux, Christophe Simonis, Jérome Maes, GitHub, Yannick Tivisse, Odoo Online, Nans Lefebvre
WEBSITE
WEBSITEhttps://www.odoo.com/page/warehouse
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-05 23:53:44
ODOO DEPENDENCIES
ODOO DEPENDENCIES odoo/odoo:
    - sale_management
    - sale
    - sales_team
    - base
    - mail
    - base_setup
    - web
    - bus
    - web_tour
    - account
    - product
    - decimal_precision
    - analytic
    - web_planner
    - portal
    - http_routing
    - account_invoicing
    - hr_expense
    - hr_contract
    - hr
    - resource
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION
Reinvoice Employee Expense
==========================

Create some products for which you can re-invoice the costs.
This module allow to reinvoice employee expense, by setting the SO directly on the expense.

Code Analysis

Views touched (4)
XML IDNameModelTypeStatus
hr_expense_form_view_inherit_sale_expense hr.expense.form.inherit.sale.expense hr.expense xpath Inherits hr_expense.hr_expense_form_view
hr_expense_sheet_form_view_inherit_sale_expense hr.expense.sheet.form.inherit.sale.expense hr.expense.sheet xpath Inherits hr_expense.view_hr_expense_sheet_form
product_product_view_form_inherit_sale_expense product.template.expense product.product xpath Inherits hr_expense.product_product_expense_form_view
product_template_form_view_expense_policy product.template.expense.policy product.template field Inherits sale.product_template_form_view_invoice_policy
Models touched (3)

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (1)
  • sale_order_id Many2one → sale.order
    domain=[('state', '=', 'sale')] readonly=True states={'draft': [('readonly', False)], 'reported': [('readonly', False)]} string='Sale Order' args: 'sale.order'
Public methods (1)
  • action_move_create(self)
    @api.multi
    When posting expense, if a SO is set, this means you want to reinvoice. To do so, we have to set an Analytic Account on the expense. We choose the one from the SO, and if it does not exist, we generate it. Create AA even for product with no expense policy to keep track of the analytic.

New fields (0)

No new fields.

Public methods (0)

No public methods.

REPOSITORY
REPOSITORYodoo/odoo
GIT
GIThttps://github.com/odoo/odoo.git
GIT FOLDER
GIT FOLDERhttps://github.com/odoo/odoo/tree/10.0/sale_expense
VERSION
VERSION 1.0
CATEGORY
CATEGORYSales
LICENSE
LICENSELGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLEYes
AUTHORS
AUTHORS
MAINTAINERS
MAINTAINERS
COMMITTERS
COMMITTERSMartin Trigaux, Fabien Pinckaers, Olivier Dony, Thibault Delavallée, Denis Ledoux, Christophe Simonis, Nicolas Martinelli, Julien Legros, qdp-odoo, Yannick Tivisse
WEBSITE
WEBSITEhttps://www.odoo.com/page/warehouse
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-05 23:50:49
ODOO DEPENDENCIES
ODOO DEPENDENCIES odoo/odoo:
    - sale
    - sales_team
    - base
    - mail
    - base_setup
    - web_kanban
    - web
    - bus
    - web_tour
    - account
    - product
    - decimal_precision
    - report
    - analytic
    - web_planner
    - procurement
    - hr_expense
    - hr_contract
    - base_action_rule
    - resource
    - hr
    - account_accountant
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION
Module used for demo data
=========================

Create some products for which you can re-invoice the costs.
This module does not add any feature, despite a few demo data to
test the features easily.

Code Analysis

Views touched (1)
XML IDNameModelTypeStatus
product_template_form_view_expense_policy product.template.expense.policy product.template field Inherits sale.product_template_form_view_invoice_policy
Models touched (1)

New fields (0)

No new fields.

Public methods (0)

No public methods.

REPOSITORY
REPOSITORYodoo/odoo
GIT
GIThttps://github.com/odoo/odoo.git
GIT FOLDER
GIT FOLDERhttps://github.com/odoo/odoo/tree/9.0/sale_expense
VERSION
VERSION 1.0
CATEGORY
CATEGORYSales
LICENSE
LICENSELGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLEYes
AUTHORS
AUTHORS
MAINTAINERS
MAINTAINERS
COMMITTERS
COMMITTERSOdoo Translation Bot, Martin Trigaux, Fabien Pinckaers, Nicolas Martinelli, qdp-odoo, Yannick Tivisse
WEBSITE
WEBSITEhttps://www.odoo.com/page/warehouse
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-05 23:48:31
ODOO DEPENDENCIES
ODOO DEPENDENCIES odoo/odoo:
    - sale
    - sales_team
    - base
    - mail
    - base_setup
    - web_kanban
    - web
    - bus
    - account
    - product
    - decimal_precision
    - report
    - analytic
    - web_tip
    - web_planner
    - procurement
    - hr_expense
    - hr_contract
    - base_action_rule
    - resource
    - hr
    - account_accountant
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION
Module used for demo data
=========================

Create some products for which you can re-invoice the costs.
This module does not add any feature, despite a few demo data to
test the features easily.

Code Analysis

Views touched (1)
XML IDNameModelTypeStatus
product_template_form_view_expense_policy product.template.expense.policy product.template field Inherits sale.product_template_form_view_invoice_policy
Models touched (2)

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (1)
  • expense_policy Selection
    default='cost' help='If you invoice at cost, the expense will be invoiced on the sale order at the cost of the analytic line;if you invoice at sales price, the price of the product will be used instead.' string='Expense Invoice Policy' args: [('cost', 'At Cost'), ('sales_price', 'At Sales Price')]
Public methods (0)

No public methods.