ITA - Gestione Cespiti

assets_management
REPOSITORY
REPOSITORYOCA/l10n-italy
GIT
GIThttps://github.com/OCA/l10n-italy.git
GIT FOLDER
GIT FOLDERhttps://github.com/OCA/l10n-italy/tree/14.0/assets_management
VERSION
VERSION 1.7.0
CATEGORY
CATEGORYLocalization/Italy
LICENSE
LICENSEAGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLENo
AUTHORS
AUTHORSOdoo Community Association (OCA), Openforce
MAINTAINERS
MAINTAINERSOdoo Community Association (OCA), Openforce
COMMITTERS
COMMITTERSGitHub, Weblate, OCA-git-bot, sergiocorato, Simone Rubino, oca-ci, George Smirnov, Alessandro Uffreduzzi, Marco Colombo, odooNextev, Borruso, daniel-chionne, Alessio Renda, PicchiSeba, Daniel Chionne
WEBSITE
WEBSITEhttps://github.com/OCA/l10n-italy
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:40:58
ODOO DEPENDENCIES
ODOO DEPENDENCIES OCA/account-financial-reporting:
    - account_financial_report
OCA/account-financial-tools:
    - account_fiscal_year
OCA/reporting-engine:
    - report_xlsx
OCA/server-ux:
    - date_range
odoo/odoo:
    - account
    - base_setup
    - base
    - web
    - product
    - mail
    - bus
    - web_tour
    - uom
    - analytic
    - portal
    - web_editor
    - http_routing
    - auth_signup
    - digest
    - resource
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION

Code Analysis

Views touched (72)
XML IDNameModelTypeStatus
asset_accounting_info_form_view asset.accounting.info.form.view asset.accounting.info form New
asset_accounting_info_search_view asset.accounting.info.search.view asset.accounting.info search New
asset_accounting_info_tree_view asset.accounting.info.tree.view asset.accounting.info tree New
asset_category_form_view asset.category.form.view asset.category form New
asset_category_tree_view asset.category.asset.tree asset.category tree New
asset_dep_line_form_view asset.dep.line.form.view asset.depreciation.line form New
asset_dep_line_search_view asset.depreciation.line.view asset.depreciation.line search New
asset_dep_line_tree_view asset.dep.line.tree.view asset.depreciation.line tree New
asset_depreciation_line_type_form_view asset.dep.line.type.form.view asset.depreciation.line.type form New
asset_depreciation_line_type_tree_view asset.dep.line.type.tree.view asset.depreciation.line.type tree New
asset_depreciation_mode_form_view asset.depreciation.mode.form.view asset.depreciation.mode form New
asset_depreciation_mode_tree_view asset.depreciation.mode.tree.view asset.depreciation.mode tree New
asset_depreciation_type_form_view asset.depreciation.type.form.view asset.depreciation.type form New
asset_depreciation_type_tree_view asset.depreciation.type.tree.view asset.depreciation.type tree New
asset_form_view asset.form.view asset.asset form New
asset_search_view asset.search.view asset.asset search New
asset_tag_form_view asset.tag.form.view asset.tag form New
asset_tag_tree_view asset.tag.tree.view asset.tag tree New
asset_tree_view asset.tree.view asset.asset tree New
document_layout document_layout ir.ui.view qweb New
template_asset_journal_asset template_asset_journal_asset ir.ui.view qweb New
template_asset_journal_asset_accounting_table_data template_asset_journal_asset_accounting_table_data ir.ui.view qweb New
template_asset_journal_asset_accounting_table_header template_asset_journal_asset_accounting_table_header ir.ui.view qweb New
template_asset_journal_asset_depreciation_table_data template_asset_journal_asset_depreciation_table_data ir.ui.view qweb New
template_asset_journal_asset_depreciation_table_header template_asset_journal_asset_depreciation_table_header ir.ui.view qweb New
template_asset_journal_asset_depreciations template_asset_journal_asset_depreciations ir.ui.view qweb New
template_asset_journal_asset_table_data template_asset_journal_asset_table_data ir.ui.view qweb New
template_asset_journal_asset_table_header template_asset_journal_asset_table_header ir.ui.view qweb New
template_asset_journal_asset_title template_asset_journal_asset_title ir.ui.view qweb New
template_asset_journal_asset_year_depreciation_accounting_data template_asset_journal_asset_year_depreciation_accounting_data ir.ui.view qweb New
template_asset_journal_asset_year_depreciation_amount_details template_asset_journal_asset_year_depreciation_amount_details ir.ui.view qweb New
template_asset_journal_asset_year_depreciation_table_data template_asset_journal_asset_year_depreciation_table_data ir.ui.view qweb New
template_asset_journal_asset_year_depreciation_table_header template_asset_journal_asset_year_depreciation_table_header ir.ui.view qweb New
template_asset_journal_base template_asset_journal_base ir.ui.view qweb New
template_asset_journal_body template_asset_journal_body ir.ui.view qweb New
template_asset_journal_category_data template_asset_journal_category_data ir.ui.view qweb New
template_asset_journal_category_totals template_asset_journal_category_totals ir.ui.view qweb New
template_asset_journal_qweb template_asset_journal_qweb ir.ui.view qweb New
template_asset_journal_report template_asset_journal_report ir.ui.view qweb New
template_asset_journal_title template_asset_journal_title ir.ui.view qweb New
template_asset_journal_totals template_asset_journal_totals ir.ui.view qweb New
template_asset_journal_totals_data template_asset_journal_totals_data ir.ui.view qweb New
template_asset_journal_totals_header template_asset_journal_totals_header ir.ui.view qweb New
template_asset_previsional_asset template_asset_previsional_asset ir.ui.view qweb New
template_asset_previsional_asset_accounting_table_data template_asset_previsional_asset_accounting_table_data ir.ui.view qweb New
template_asset_previsional_asset_accounting_table_header template_asset_previsional_asset_accounting_table_header ir.ui.view qweb New
template_asset_previsional_asset_depreciation_table_data template_asset_previsional_asset_depreciation_table_data ir.ui.view qweb New
template_asset_previsional_asset_depreciation_table_header template_asset_previsional_asset_depreciation_table_header ir.ui.view qweb New
template_asset_previsional_asset_depreciations template_asset_previsional_asset_depreciations ir.ui.view qweb New
template_asset_previsional_asset_table_data template_asset_previsional_asset_table_data ir.ui.view qweb New
template_asset_previsional_asset_table_header template_asset_previsional_asset_table_header ir.ui.view qweb New
template_asset_previsional_asset_title template_asset_previsional_asset_title ir.ui.view qweb New
template_asset_previsional_asset_year_depreciation_table_data template_asset_previsional_asset_year_depreciation_table_data ir.ui.view qweb New
template_asset_previsional_asset_year_depreciation_table_header template_asset_previsional_asset_year_depreciation_table_header ir.ui.view qweb New
template_asset_previsional_base template_asset_previsional_base ir.ui.view qweb New
template_asset_previsional_body template_asset_previsional_body ir.ui.view qweb New
template_asset_previsional_category_data template_asset_previsional_category_data ir.ui.view qweb New
template_asset_previsional_category_totals template_asset_previsional_category_totals ir.ui.view qweb New
template_asset_previsional_qweb template_asset_previsional_qweb ir.ui.view qweb New
template_asset_previsional_report template_asset_previsional_report ir.ui.view qweb New
template_asset_previsional_title template_asset_previsional_title ir.ui.view qweb New
template_asset_previsional_totals template_asset_previsional_totals ir.ui.view qweb New
template_asset_previsional_totals_data template_asset_previsional_totals_data ir.ui.view qweb New
template_asset_previsional_totals_header template_asset_previsional_totals_header ir.ui.view qweb New
view_asset_depreciation_form asset.depreciation.form.view asset.depreciation form New
view_asset_depreciation_tree view.asset.depreciation.tree asset.depreciation tree New
view_move_form_inherit view.move.form.inherit account.move xpath Inherits account.view_move_form
view_move_line_form_inherit view.move.line.form.inherit account.move.line xpath Inherits account.view_move_line_form
wizard_account_move_mange_asset_form_view wizard.account.move.manage.asset.form.view wizard.account.move.manage.asset form New
wizard_asset_generate_depreciation_form_view wizard.asset.generate.depreciation.form.view wizard.asset.generate.depreciation form New
wizard_asset_journal_report_form_view wizard.asset.journal.report.form.view wizard.asset.journal.report form New
wizard_asset_previsional_report_form_view wizard.asset.previsional.report.form.view wizard.asset.previsional.report form New
Models touched (36)

New fields (0)

No new fields.

Public methods (1)
  • unlink(self)

New fields (0)

No new fields.

Public methods (2)
  • get_fiscal_year_by_date(self, date, limit=1, company=None, miss_raise=True)
    @api.model
    Retrieves fiscal year by given ``date`` (a datetime.date object). By default, only 1 fiscal year will be returned, unless specified differently. If ``miss_raise`` is True and no fiscal year is found, an error will be raised.
  • get_fiscal_year_by_date_domain(self, date, company=None)
    @api.model
    Prepares a search() domain to retrieve fiscal years by given ``date``.

New fields (0)

No new fields.

Public methods (1)
  • unlink(self)

New fields (4)
  • asset_accounting_info_ids One2many → asset.accounting.info
    string='Assets Accounting Info' args: 'asset.accounting.info', 'move_id'
  • asset_ids Many2many → asset.asset
    compute='_compute_asset_data' store=True string='Assets' args: 'asset.asset'
  • dep_line_ids Many2many → asset.depreciation.line
    compute='_compute_asset_data' store=True string='Depreciation Lines' args: 'asset.depreciation.line'
  • hide_link_asset_button Boolean
    compute='_compute_hide_link_asset_button' compute_sudo=True default=True string='Hide Asset Button'
Public methods (5)
  • button_cancel(self)
  • check_company(self)
    @api.constrains('company_id')
  • get_linked_aa_info_records(self)
  • get_valid_accounts(self)
  • open_wizard_manage_asset(self)

New fields (3)
  • asset_accounting_info_ids One2many → asset.accounting.info
    string='Assets Accounting Info' args: 'asset.accounting.info', 'move_line_id'
  • asset_ids Many2many → asset.asset
    compute='_compute_asset_data' store=True string='Assets' args: 'asset.asset'
  • dep_line_ids Many2many → asset.depreciation.line
    compute='_compute_asset_data' store=True string='Depreciation Lines' args: 'asset.depreciation.line'
Public methods (3)
  • check_company(self)
    @api.constrains('company_id')
  • get_asset_purchase_amount(self, currency=None)
  • get_linked_aa_info_records(self)

New fields (7)
  • asset_id Many2one → asset.asset
    ondelete='set null' string='Asset' args: 'asset.asset'
  • company_id Many2one → res.company
    readonly=True string='Company' args: 'res.company'
  • dep_line_id Many2one → asset.depreciation.line
    ondelete='set null' string='Depreciation Line' args: 'asset.depreciation.line'
  • move_id Many2one → account.move
    related='move_line_id.move_id' string='Move' args: 'account.move'
  • move_line_id Many2one → account.move.line
    ondelete='cascade' string='Move Line' args: 'account.move.line'
  • move_type Selection
    related='dep_line_id.move_type'
  • relation_type Selection
    required=True string='Relation Type' args: [('create', 'Asset Creation'), ('update', 'Asset Update'), ('partial_dismiss', 'Asset Partial Dismissal'), ('dismiss', 'Asset Dismissal')]
Public methods (15)
  • button_unlink(self)
    Button action: deletes a.a.info
  • check_and_normalize(self)
  • check_coherence(self)
    Checks info coherence
  • check_company_coherence(self)
    Checks companies
  • check_data_coherence(self)
  • create(self, vals)
    @api.model
  • cron_vacuum_table(self)
    @api.model
    A cron that deletes obsolete records
  • get_all_companies(self)
  • get_main_fields(self)
    @api.model
  • get_normalized_info_vals(self)
  • get_records_to_delete_by_cron(self)
    Returns every a.a.info that fits the condition: (no asset AND no depreciation line) OR (no move AND no move line)
  • make_name(self)
  • name_get(self)
  • normalize_info(self)
    Normalize asset accounting info if needed
  • write(self, vals)

New fields (21)
  • asset_accounting_info_ids One2many → asset.accounting.info
    string='Accounting Info' args: 'asset.accounting.info', 'asset_id'
  • category_id Many2one → asset.category
    check_company=True required=True string='Category' args: 'asset.category'
  • code Char
    default='' string='Code'
  • company_id Many2one → res.company
    default=get_default_company_id readonly=True required=True string='Company' tracking=True args: 'res.company'
  • currency_id Many2one → res.currency
    required=True string='Currency' args: 'res.currency'
  • customer_id Many2one → res.partner
    check_company=True string='Customer' args: 'res.partner'
  • depreciation_ids One2many → asset.depreciation
    check_company=True string='Depreciations' args: 'asset.depreciation', 'asset_id'
  • dismiss_date Date
  • dismissed Boolean
    string='Dismissed'
  • name Char
    required=True string='Name' tracking=True
  • purchase_amount Monetary
    string='Purchase Value' tracking=True
  • purchase_date Date
    default=fields.Date.today() string='Purchase Date' tracking=True
  • purchase_move_id Many2one → account.move
    check_company=True string='Purchase Move' args: 'account.move'
  • sale_amount Monetary
    string='Sale Value'
  • sale_date Date
    string='Sale Date'
  • sale_move_id Many2one → account.move
    check_company=True string='Sale Move' args: 'account.move'
  • sold Boolean
    string='Sold'
  • state Selection
    compute='_compute_state' default='non_depreciated' store=True string='State' args: [('non_depreciated', 'Non Depreciated'), ('partially_depreciated', 'Partially Depreciated'), ('totally_depreciated', 'Depreciated')]
  • supplier_id Many2one → res.partner
    check_company=True string='Supplier' args: 'res.partner'
  • supplier_ref Char
    string='Supplier Ref.'
  • used Boolean
    string='Used'
Public methods (14)
  • check_company(self)
    @api.constrains('company_id')
  • create(self, vals)
    @api.model
  • get_asset_state(self)
  • get_default_company_id(self)
    @api.model
  • get_linked_aa_info_records(self)
  • launch_wizard_generate_depreciations(self)
  • make_name(self)
  • name_get(self)
  • onchange_category_id(self)
    @api.onchange('category_id')
  • onchange_company_currency(self)
    @api.onchange('company_id')
  • onchange_purchase_amount(self)
    @api.onchange('purchase_amount')
  • onchange_purchase_date(self)
    @api.onchange('purchase_date')
  • unlink(self)
  • write(self, vals)

New fields (12)
  • asset_account_id Many2one → account.account
    check_company=True required=True string='Asset Account' args: 'account.account'
  • comment Text
    string='Comment'
  • company_id Many2one → res.company
    default=get_default_company_id readonly=True string='Company' args: 'res.company'
  • depreciation_account_id Many2one → account.account
    check_company=True required=True string='Depreciation Account' args: 'account.account'
  • fund_account_id Many2one → account.account
    check_company=True required=True string='Fund Account' args: 'account.account'
  • gain_account_id Many2one → account.account
    check_company=True required=True string='Capital Gain Account' args: 'account.account'
  • journal_id Many2one → account.journal
    check_company=True required=True string='Journal' args: 'account.journal'
  • loss_account_id Many2one → account.account
    check_company=True required=True string='Capital Loss Account' args: 'account.account'
  • name Char
    required=True string='Name'
  • print_by_default Boolean
    default=True help="Defines whether a category should be added by default when printing assets' reports." string='Print By Default'
  • tag_ids Many2many → asset.tag
    check_company=True string='Tag' args: 'asset.tag'
  • type_ids One2many → asset.category.depreciation.type
    check_company=True default=get_default_type_ids string='Depreciation Types' args: 'asset.category.depreciation.type', 'category_id'
Public methods (5)
  • copy(self, default=None)
  • get_default_company_id(self)
    @api.model
  • get_default_type_ids(self)
    @api.model
  • get_depreciation_vals(self, amount_depreciable=0)
  • unlink(self)

New fields (7)
  • base_coeff Float
    default=1 help='Coeff to compute depreciable amount from purchase amount' string='Dep Base Coeff'
  • category_id Many2one → asset.category
    check_company=True ondelete='cascade' readonly=True required=True string='Category' args: 'asset.category'
  • company_id Many2one → res.company
    readonly=True related='category_id.company_id' string='Company' args: 'res.company'
  • depreciation_type_id Many2one → asset.depreciation.type
    check_company=True required=True string='Type' args: 'asset.depreciation.type'
  • mode_id Many2one → asset.depreciation.mode
    check_company=True required=True string='Dep Mode' args: 'asset.depreciation.mode'
  • percentage Float
    string='Depreciation %'
  • pro_rata_temporis Boolean
    string='Pro-rata Temporis'
Public methods (1)
  • get_depreciation_vals(self, amount_depreciable=0)

New fields (27)
  • amount_depreciable Monetary
    string='Initial Depreciable Amount'
  • amount_depreciable_updated Monetary
    compute='_compute_amounts' store=True string='Updated Depreciable Amount'
  • amount_depreciated Monetary
    compute='_compute_amounts' store=True string='Depreciated Amount'
  • amount_gain Monetary
    compute='_compute_amounts' store=True string='Capital Gain'
  • amount_historical Monetary
    compute='_compute_amounts' store=True string='Historical Amount'
  • amount_in Monetary
    compute='_compute_amounts' store=True string='In Amount'
  • amount_loss Monetary
    compute='_compute_amounts' store=True string='Capital Loss'
  • amount_out Monetary
    compute='_compute_amounts' store=True string='Out Amount'
  • amount_residual Monetary
    compute='_compute_amounts' store=True string='Residual Amount'
  • asset_id Many2one → asset.asset
    ondelete='cascade' readonly=True required=True string='Asset' args: 'asset.asset'
  • base_coeff Float
    default=1 help='Coeff to compute amount depreciable from purchase amount' string='Depreciable Base Coeff'
  • company_id Many2one → res.company
    readonly=True related='asset_id.company_id' string='Company' args: 'res.company'
  • currency_id Many2one → res.currency
    readonly=True related='asset_id.currency_id' string='Currency' args: 'res.currency'
  • date_start Date
    string='Date Start'
  • dismiss_move_id Many2one → account.move
    check_company=True string='Dismiss Move' args: 'account.move'
  • first_dep_nr Integer
    default=1 string='First Dep. Num'
  • force_all_dep_nr Boolean
    string='Force All Dep. Num'
  • force_first_dep_nr Boolean
    string='Force First Dep. Num'
  • last_depreciation_date Date
    compute='_compute_last_depreciation_date' store=True string='Last Dep.'
  • line_ids One2many → asset.depreciation.line
    check_company=True string='Lines' args: 'asset.depreciation.line', 'depreciation_id'
  • mode_id Many2one → asset.depreciation.mode
    check_company=True required=True string='Mode' args: 'asset.depreciation.mode'
  • percentage Float
    string='Depreciation (%)'
  • pro_rata_temporis Boolean
    string='Pro-rata Temporis'
  • requires_account_move Boolean
    readonly=True related='type_id.requires_account_move' string='Requires Account Move'
  • state Selection
    compute='_compute_state' default='non_depreciated' store=True string='State' args: [('non_depreciated', 'Non Depreciated'), ('partially_depreciated', 'Partially Depreciated'), ('totally_depreciated', 'Depreciated')]
  • type_id Many2one → asset.depreciation.type
    check_company=True string='Depreciation Type' args: 'asset.depreciation.type'
  • zero_depreciation_until Date
    string='Zero Depreciation Up To'
Public methods (27)
  • check_before_generate_depreciation_lines(self, dep_date)
  • create(self, vals)
    @api.model
  • generate_depreciation_lines(self, dep_date, period=None, period_count=None)
  • generate_depreciation_lines_single(self, dep_date, period=None, period_count=None)
  • generate_dismiss_account_move(self)
  • get_computed_amounts(self)
  • get_depreciable_amount(self, dep_date=None)
  • get_depreciation_amount(self, dep_date, period=None, period_count=None)
  • get_depreciation_amount_multiplier(self, dep_date, period=None, period_count=None)
  • get_depreciation_state(self)
  • get_dismiss_account_move_line_vals(self)
  • get_dismiss_account_move_vals(self)
  • get_pro_rata_temporis_dates(self, date)
    Gets useful dates for pro rata temporis computations, according to given date, by retrieving its fiscal year. :param date: given date for depreciation :return: date objects triplet (dt_start, dt, dt_end) - dt_start: fiscal year first day - dt: given date - dt_end: fiscal year last day
  • get_pro_rata_temporis_multiplier(self, date=None, mode='std')
    Computes and returns pro rata temporis multiplier according to given depreciation, date, fiscal year and mode :param date: given date as a fields.Date string :param mode: string, defines how to compute multiplier. Valid values: - 'std': start-to-date, computes multiplier using days from fiscal year's first day to given date; - 'dte': date-to-end, computes multiplier using days from given date to fiscal year's last day
  • make_name(self)
  • name_get(self)
  • need_normalize_first_dep_nr(self)
  • normalize_first_dep_nr(self, force=False)
    Normalize first numbered line according to `first_dep_nr` value :param force: if True, force normalization
  • onchange_base_coeff(self)
    @api.onchange('asset_id', 'base_coeff')
  • onchange_force_all_dep_nr(self)
    @api.onchange('force_all_dep_nr')
  • onchange_force_dep_nrs(self)
    @api.onchange('force_all_dep_nr', 'force_first_dep_nr')
  • onchange_force_first_dep_nr(self)
    @api.onchange('force_first_dep_nr')
  • onchange_normalize_first_dep_nr(self)
    @api.onchange('first_dep_nr')
  • post_generate_depreciation_lines(self, lines=None)
  • prepare_depreciation_line_vals(self, dep_date)
  • unlink(self)
  • write(self, vals)

New fields (20)
  • amount Monetary
    string='Amount'
  • asset_accounting_info_ids One2many → asset.accounting.info
    check_company=True string='Accounting Info' args: 'asset.accounting.info', 'dep_line_id'
  • asset_id Many2one → asset.asset
    readonly=True related='depreciation_id.asset_id' store=True string='Asset' args: 'asset.asset'
  • balance Monetary
    compute='_compute_balance' store=True string='Balance'
  • base Float
    string='Base'
  • company_id Many2one → res.company
    readonly=True related='depreciation_id.company_id' args: 'res.company'
  • currency_id Many2one → res.currency
    readonly=True related='depreciation_id.currency_id' args: 'res.currency'
  • date Date
    required=True string='Date'
  • depreciation_id Many2one → asset.depreciation
    ondelete='cascade' readonly=True required=True string='Asset depreciation' args: 'asset.depreciation'
  • depreciation_line_type_id Many2one → asset.depreciation.line.type
    check_company=True string='Depreciation Type' args: 'asset.depreciation.line.type'
  • depreciation_nr Integer
    string='Dep. Num'
  • depreciation_type_id Many2one → asset.depreciation.type
    readonly=True related='depreciation_id.type_id' store=True string='Asset depreciation type' args: 'asset.depreciation.type'
  • force_dep_nr Boolean
    readonly=True related='depreciation_id.force_all_dep_nr' string='Force Dep. Num'
  • move_id Many2one → account.move
    check_company=True string='Move' args: 'account.move'
  • move_type Selection
    required=True string='Type' args: [('depreciated', 'Depreciation'), ('historical', 'Historical'), ('in', 'In'), ('out', 'Out'), ('loss', 'Capital Loss'), ('gain', 'Capital Gain')]
  • name Char
    required=True string='Name'
  • partial_dismissal Boolean
    string='Partial Dismissal'
  • percentage Float
    string='%'
  • requires_account_move Boolean
    readonly=True related='depreciation_id.type_id.requires_account_move' string='Required Account Move'
  • requires_depreciation_nr Boolean
    compute='_compute_requires_depreciation_nr' search='_search_requires_depreciation_nr_lines' string='Requires Dep Num'
Public methods (34)
  • button_generate_account_move(self)
  • button_regenerate_account_move(self)
  • button_remove_account_move(self)
  • check_company(self)
  • check_depreciation_nr_coherence(self)
    @api.constrains('depreciation_nr')
  • create(self, vals)
    @api.model
  • generate_account_move(self)
  • generate_account_move_single(self)
  • get_account_move_line_vals(self)
    Switcher between methods
  • get_account_move_line_vals_methods(self)
    Maps line `move_type` to its own method for generating move lines.
  • get_account_move_vals(self)
  • get_balances_grouped(self)
    Groups balances of line in `self` by line.move_type, adding all possible type to ensure values are computed always.
  • get_depreciated_account_move_line_vals(self)
  • get_depreciation_nr_dict(self)
    Returns dict {line: new number}
  • get_gain_account_move_line_vals(self)
  • get_historical_account_move_line_vals(self)
  • get_in_account_move_line_vals(self)
  • get_linked_aa_info_records(self)
  • get_loss_account_move_line_vals(self)
  • get_non_residual_move_types(self)
    Returns list of `move_type` vals that do not concur to asset.depreciation's `amount_residual` field compute
  • get_numbered_move_types(self)
    Returns list of `move_type` vals that require numeration
  • get_out_account_move_line_vals(self)
  • get_update_move_types(self)
    Returns list of `move_type` that concur to update asset.depreciation's `amount_depreciable_updated` field
  • is_depreciation_nr_required(self)
    Defines if a line requires to be numbered
  • make_name(self)
  • name_get(self)
  • need_normalize_depreciation_nr(self)
    Check if numbers need to be normalized
  • needs_account_move(self)
  • normalize_depreciation_nr(self, force=False)
    Normalize depreciation numbers to be consecutive for depreciation and historical lines within the same depreciation set; force to 0 every non-depreciation line. :param force: force normalization for every depreciations' lines
  • onchange_move_type(self)
    @api.onchange('move_type')
  • post_dismiss_asset(self)
  • post_partial_dismiss_asset(self)
  • unlink(self)
  • write(self, vals)

New fields (4)
  • code Char
    string='Code'
  • company_id Many2one → res.company
    default=get_default_company_id string='Company' args: 'res.company'
  • name Char
    required=True string='Name'
  • type Selection
    string='Type' args: [('in', 'In'), ('out', 'Out')]
Public methods (4)
  • get_default_company_id(self)
    @api.model
  • make_name(self)
  • name_get(self)
  • unlink(self)

New fields (5)
  • company_id Many2one → res.company
    default=get_default_company_id readonly=True string='Company' args: 'res.company'
  • default Boolean
    string='Default Mode'
  • line_ids One2many → asset.depreciation.mode.line
    check_company=True string='Lines' args: 'asset.depreciation.mode.line', 'mode_id'
  • name Char
    required=True string='Name'
  • used_asset_coeff Float
    default=1.0 string='Used Asset Coeff.'
Public methods (5)
  • check_default_modes(self)
    @api.constrains('company_id', 'default')
  • copy(self, default=None)
  • get_default_company_id(self)
    @api.model
  • get_depreciation_amount_multiplier(self)
  • unlink(self)

New fields (7)
  • application Selection
    default='coefficient' required=True string='Application by' args: [('coefficient', 'Coefficient'), ('percentage', 'Percentage')]
  • coefficient Float
    string='Coefficient'
  • company_id Many2one → res.company
    readonly=True related='mode_id.company_id' string='Company' args: 'res.company'
  • from_year_nr Integer
    help='Minimum number of fiscal years passed from asset purchase date to apply this line.' required=True string='From Year'
  • mode_id Many2one → asset.depreciation.mode
    ondelete='cascade' readonly=True required=True string='Mode' args: 'asset.depreciation.mode'
  • percentage Float
    string='Percentage'
  • to_year_nr Integer
    help='Maximum number of fiscal years passed from asset purchase date to apply this line.' string='To Year'
Public methods (2)
  • get_depreciation_amount_multiplier(self)
  • onchange_application(self)
    @api.onchange('application')

New fields (4)
  • company_id Many2one → res.company
    default=get_default_company_id string='Company' args: 'res.company'
  • name Char
    required=True string='Name'
  • print_by_default Boolean
    default=True help="Defines whether a category should be added by default when printing assets' reports." string='Print By Default'
  • requires_account_move Boolean
    string='Requires Account Move'
Public methods (2)
  • get_default_company_id(self)
    @api.model
  • unlink(self)

New fields (2)
  • company_id Many2one → res.company
    default=get_default_company_id readonly=True string='Company' args: 'res.company'
  • name Char
    required=True string='Name'
Public methods (1)
  • get_default_company_id(self)
    @api.model

New fields (0)

No new fields.

Public methods (23)
  • generate_asset_accounting_doc_data(self, report_data)
  • generate_asset_data(self, report_data)
  • generate_category_data(self, report_data)
  • generate_depreciation_data(self, report_data)
  • generate_depreciation_line_accounting_doc_data(self, report_data)
  • generate_depreciation_line_amount_detail_data(self, report_data)
  • generate_depreciation_line_year_data(self, report_data)
  • generate_xlsx_report(self, workbook, data, objects)
    Set wb, data and report attributes
  • get_max_width_dict(self, report_data)
  • get_totals_data(self, report_data)
  • set_asset_accounting_doc_data(self, report_data)
  • set_asset_data(self, report_data)
  • set_category_data(self, report_data)
  • set_depreciation_data(self, report_data)
  • set_depreciation_line_accounting_doc_data(self, report_data)
  • set_depreciation_line_amount_detail_data(self, report_data)
  • set_depreciation_line_year_data(self, report_data)
  • set_formats(self, workbook, report_data)
    Defines custom formats
  • set_report_data(self, report_data)
  • set_totals_data(self, report_data)
  • write_all(self, report_data, obj, index)
  • write_header(self, report_data, index)
  • write_value(self, report_data, obj, index)

New fields (0)

No new fields.

Public methods (21)
  • generate_asset_accounting_doc_data(self, report_data)
  • generate_asset_data(self, report_data)
  • generate_category_data(self, report_data)
  • generate_depreciation_data(self, report_data)
  • generate_depreciation_line_amount_detail_data(self, report_data)
  • generate_depreciation_line_year_data(self, report_data)
  • generate_xlsx_report(self, workbook, data, objects)
    Set wb, data and report attributes
  • get_max_width_dict(self, report_data)
  • get_totals_data(self, report_data)
  • set_asset_accounting_doc_data(self, report_data)
  • set_asset_data(self, report_data)
  • set_category_data(self, report_data)
  • set_depreciation_data(self, report_data)
  • set_depreciation_line_amount_detail_data(self, report_data)
  • set_depreciation_line_year_data(self, report_data)
  • set_formats(self, workbook, report_data)
    Defines custom formats
  • set_report_data(self, report_data)
  • set_totals_data(self, report_data)
  • write_all(self, report_data, obj, index)
  • write_header(self, report_data, index)
  • write_value(self, report_data, obj, index)

New fields (17)
  • asset_ids Many2many → asset.asset
    args: 'asset.asset'
  • asset_order_fname Char
  • category_ids Many2many → asset.category
    args: 'asset.category'
  • company_id Many2one → res.company
    args: 'res.company'
  • date Date
  • report_asset_ids One2many → report_asset_journal_asset
    args: 'report_asset_journal_asset', 'report_id'
  • report_category_ids One2many → report_asset_journal_category
    args: 'report_asset_journal_category', 'report_id'
  • report_depreciation_ids One2many → report_asset_journal_depreciation
    args: 'report_asset_journal_depreciation', 'report_id'
  • report_depreciation_line_year_ids One2many → report_asset_journal_depreciation_line_year
    args: 'report_asset_journal_depreciation_line_year', 'report_id'
  • report_footer_year Char
  • report_name Char
  • report_total_ids One2many → report_asset_journal_totals
    args: 'report_asset_journal_totals', 'report_id'
  • show_category_totals Boolean
  • show_dismissed_assets Boolean
  • show_sold_assets Boolean
  • show_totals Boolean
  • type_ids Many2many → asset.depreciation.type
    args: 'asset.depreciation.type'
Public methods (10)
  • compute_data_for_report(self)
    Compute data to be printed
  • do_print(self, report_type)
  • generate_data(self)
  • generate_structure(self)
  • generate_totals(self)
  • get_depreciations(self)
  • get_html(self, given_context=None)
    @api.model
    Method needed from JavaScript widget to render HTML view
  • print_report(self, report_type=None)
    This method is called from the JS widget buttons 'Print' and 'Export' in the HTML view. Prints PDF and XLSX reports. :param report_type: string that represents the report type
  • set_report_name(self)
  • sort_assets(self, assets)

New fields (9)
  • document_date Char
  • document_nr Char
  • partner_name Char
  • partner_ref Char
  • partner_vat Char
  • report_id Many2one → report_asset_journal
    args: 'report_asset_journal'
  • res_id Integer
  • res_model Char
  • sequence Integer
Public methods (0)

No public methods.

New fields (11)
  • asset_code Char
  • asset_id Many2one → asset.asset
    ondelete='cascade' required=True args: 'asset.asset'
  • asset_name Char
  • asset_purchase_amount Float
  • asset_state Char
  • asset_used Char
  • report_category_id Many2one → report_asset_journal_category
    args: 'report_asset_journal_category'
  • report_depreciation_ids One2many → report_asset_journal_depreciation
    args: 'report_asset_journal_depreciation', 'report_asset_id'
  • report_id Many2one → report_asset_journal
    args: 'report_asset_journal'
  • report_purchase_doc_id Many2one → report_asset_journal_accounting_doc
    args: 'report_asset_journal_accounting_doc'
  • report_sale_doc_id Many2one → report_asset_journal_accounting_doc
    args: 'report_asset_journal_accounting_doc'
Public methods (6)
  • format_amount(self, amount, currency=None)
  • generate_data(self)
  • get_currency(self)
  • get_purchase_vals(self)
  • get_report_asset_data(self)
  • get_sale_vals(self)

New fields (5)
  • category_id Many2one → asset.category
    ondelete='cascade' required=True args: 'asset.category'
  • category_name Char
  • report_asset_ids One2many → report_asset_journal_asset
    args: 'report_asset_journal_asset', 'report_category_id'
  • report_id Many2one → report_asset_journal
    args: 'report_asset_journal'
  • report_total_ids One2many → report_asset_journal_totals
    args: 'report_asset_journal_totals', 'report_category_id'
Public methods (3)
  • generate_data(self)
  • generate_totals(self)
  • get_report_categ_data(self)

New fields (10)
  • dep_amount_depreciable Float
  • dep_date_start Char
  • dep_percentage Float
  • dep_pro_rata_temporis Char
  • depreciation_id Many2one → asset.depreciation
    ondelete='cascade' required=True args: 'asset.depreciation'
  • mode_name Char
  • report_asset_id Many2one → report_asset_journal_asset
    args: 'report_asset_journal_asset'
  • report_depreciation_year_line_ids One2many → report_asset_journal_depreciation_line_year
    args: 'report_asset_journal_depreciation_line_year', 'report_depreciation_id'
  • report_id Many2one → report_asset_journal
    args: 'report_asset_journal'
  • type_name Char
Public methods (4)
  • format_amount(self, amount, currency=None)
  • generate_data(self)
  • get_currency(self)
  • get_report_dep_data(self)

New fields (30)
  • amount_depreciable Float
  • amount_depreciable_updated Float
  • amount_depreciated Float
  • amount_depreciation_fund_curr_year Float
  • amount_depreciation_fund_prev_year Float
  • amount_gain Float
  • amount_gain_total Float
  • amount_historical Float
  • amount_in Float
  • amount_in_detail Char
  • amount_in_total Float
  • amount_loss Float
  • amount_loss_total Float
  • amount_out Float
  • amount_out_detail Char
  • amount_out_total Float
  • amount_residual Float
  • date_start Char
  • dep_line_ids Many2many → asset.depreciation.line
    relation='report_journal_line_year_dep_line' args: 'asset.depreciation.line'
  • fiscal_year_id Many2one → account.fiscal.year
    args: 'account.fiscal.year'
  • gain_loss Float
  • gain_loss_total Float
  • has_amount_detail Boolean
  • percentage Float
  • report_accounting_doc_ids Many2many → report_asset_journal_accounting_doc
    relation='year_dep_line_accounting_doc_rel' args: 'report_asset_journal_accounting_doc'
  • report_depreciation_id Many2one → report_asset_journal_depreciation
    args: 'report_asset_journal_depreciation'
  • report_id Many2one → report_asset_journal
    args: 'report_asset_journal'
  • sequence Integer
  • type_name Char
  • year Char
Public methods (4)
  • format_amount(self, amount, currency=None)
  • generate_data(self)
  • get_currency(self)
  • get_report_dep_line_year_data(self)

New fields (16)
  • amount_depreciable_updated Float
  • amount_depreciated Float
  • amount_depreciation_fund_curr_year Float
  • amount_depreciation_fund_prev_year Float
  • amount_gain Float
  • amount_in_total Float
  • amount_loss Float
  • amount_out_total Float
  • amount_residual Float
  • gain_loss Float
  • gain_loss_total Float
  • name Char
  • report_category_id Many2one → report_asset_journal_category
    args: 'report_asset_journal_category'
  • report_id Many2one → report_asset_journal
    args: 'report_asset_journal'
  • type_id Many2one → asset.depreciation.type
    args: 'asset.depreciation.type'
  • type_name Char
Public methods (2)
  • format_amount(self, amount, currency=None)
  • get_currency(self)

New fields (18)
  • asset_ids Many2many → asset.asset
    args: 'asset.asset'
  • asset_order_fname Char
  • category_ids Many2many → asset.category
    args: 'asset.category'
  • company_id Many2one → res.company
    args: 'res.company'
  • date Date
  • previsional_line_ids Many2many → asset.depreciation.line
    args: 'asset.depreciation.line'
  • report_asset_ids One2many → report_asset_previsional_asset
    args: 'report_asset_previsional_asset', 'report_id'
  • report_category_ids One2many → report_asset_previsional_category
    args: 'report_asset_previsional_category', 'report_id'
  • report_depreciation_ids One2many → report_asset_previsional_depreciation
    args: 'report_asset_previsional_depreciation', 'report_id'
  • report_depreciation_line_year_ids One2many → report_asset_previsional_depreciation_line_year
    args: 'report_asset_previsional_depreciation_line_year', 'report_id'
  • report_footer_year Char
  • report_name Char
  • report_total_ids One2many → report_asset_previsional_totals
    args: 'report_asset_previsional_totals', 'report_id'
  • show_category_totals Boolean
  • show_dismissed_assets Boolean
  • show_sold_assets Boolean
  • show_totals Boolean
  • type_ids Many2many → asset.depreciation.type
    args: 'asset.depreciation.type'
Public methods (10)
  • compute_data_for_report(self)
    Compute data to be printed
  • do_print(self, report_type)
  • generate_data(self)
  • generate_structure(self)
  • generate_totals(self)
  • get_assets(self)
  • get_html(self, given_context=None)
    @api.model
    Method needed from JavaScript widget to render HTML view
  • print_report(self, report_type=None)
    This method is called from the JS widget buttons 'Print' and 'Export' in the HTML view. Prints PDF and XLSX reports. :param report_type: string that represents the report type
  • set_report_name(self)
  • sort_assets(self, assets)

New fields (9)
  • document_date Char
  • document_nr Char
  • partner_name Char
  • partner_ref Char
  • partner_vat Char
  • report_id Many2one → report_asset_previsional
    args: 'report_asset_previsional'
  • res_id Integer
  • res_model Char
  • sequence Integer
Public methods (0)

No public methods.

New fields (11)
  • asset_code Char
  • asset_id Many2one → asset.asset
    ondelete='cascade' required=True args: 'asset.asset'
  • asset_name Char
  • asset_purchase_amount Float
  • asset_state Char
  • asset_used Char
  • report_category_id Many2one → report_asset_previsional_category
    args: 'report_asset_previsional_category'
  • report_depreciation_ids One2many → report_asset_previsional_depreciation
    args: 'report_asset_previsional_depreciation', 'report_asset_id'
  • report_id Many2one → report_asset_previsional
    args: 'report_asset_previsional'
  • report_purchase_doc_id Many2one → report_asset_previsional_accounting_doc
    args: 'report_asset_previsional_accounting_doc'
  • report_sale_doc_id Many2one → report_asset_previsional_accounting_doc
    args: 'report_asset_previsional_accounting_doc'
Public methods (6)
  • format_amount(self, amount, currency=None)
  • generate_data(self)
  • get_currency(self)
  • get_purchase_vals(self)
  • get_report_asset_data(self)
  • get_sale_vals(self)

New fields (5)
  • category_id Many2one → asset.category
    ondelete='cascade' required=True args: 'asset.category'
  • category_name Char
  • report_asset_ids One2many → report_asset_previsional_asset
    args: 'report_asset_previsional_asset', 'report_category_id'
  • report_id Many2one → report_asset_previsional
    args: 'report_asset_previsional'
  • report_total_ids One2many → report_asset_previsional_totals
    args: 'report_asset_previsional_totals', 'report_category_id'
Public methods (3)
  • generate_data(self)
  • generate_totals(self)
  • get_report_categ_data(self)

New fields (10)
  • dep_amount_depreciable Float
  • dep_date_start Char
  • dep_percentage Float
  • dep_pro_rata_temporis Char
  • depreciation_id Many2one → asset.depreciation
    ondelete='cascade' required=True args: 'asset.depreciation'
  • mode_name Char
  • report_asset_id Many2one → report_asset_previsional_asset
    args: 'report_asset_previsional_asset'
  • report_depreciation_year_line_ids One2many → report_asset_previsional_depreciation_line_year
    args: 'report_asset_previsional_depreciation_line_year', 'report_depreciation_id'
  • report_id Many2one → report_asset_previsional
    args: 'report_asset_previsional'
  • type_name Char
Public methods (4)
  • format_amount(self, amount, currency=None)
  • generate_data(self)
  • get_currency(self)
  • get_report_dep_data(self)

New fields (31)
  • amount_depreciable Float
  • amount_depreciable_updated Float
  • amount_depreciated Float
  • amount_depreciation_fund_curr_year Float
  • amount_depreciation_fund_prev_year Float
  • amount_gain Float
  • amount_gain_total Float
  • amount_historical Float
  • amount_in Float
  • amount_in_detail Char
  • amount_in_total Float
  • amount_loss Float
  • amount_loss_total Float
  • amount_out Float
  • amount_out_detail Char
  • amount_out_total Float
  • amount_residual Float
  • date_start Char
  • dep_line_ids Many2many → asset.depreciation.line
    relation='report_previsional_line_year_dep_line' args: 'asset.depreciation.line'
  • fiscal_year_id Many2one → account.fiscal.year
    args: 'account.fiscal.year'
  • gain_loss Float
  • gain_loss_total Float
  • has_amount_detail Boolean
  • hidden Boolean
  • needs_previsional Boolean
  • percentage Float
  • report_depreciation_id Many2one → report_asset_previsional_depreciation
    args: 'report_asset_previsional_depreciation'
  • report_id Many2one → report_asset_previsional
    args: 'report_asset_previsional'
  • sequence Integer
  • type_name Char
  • year Char
Public methods (8)
  • clean_unused(self)
  • do_clean(self)
  • format_amount(self, amount, currency=None)
  • generate_data(self)
  • generate_previsional_line_single(self)
  • generate_previsional_lines(self)
  • get_currency(self)
  • get_report_dep_line_year_data(self)

New fields (16)
  • amount_depreciable_updated Float
  • amount_depreciated Float
  • amount_depreciation_fund_curr_year Float
  • amount_depreciation_fund_prev_year Float
  • amount_gain Float
  • amount_in_total Float
  • amount_loss Float
  • amount_out_total Float
  • amount_residual Float
  • gain_loss Float
  • gain_loss_total Float
  • name Char
  • report_category_id Many2one → report_asset_previsional_category
    args: 'report_asset_previsional_category'
  • report_id Many2one → report_asset_previsional
    args: 'report_asset_previsional'
  • type_id Many2one → asset.depreciation.type
    args: 'asset.depreciation.type'
  • type_name Char
Public methods (2)
  • format_amount(self, amount, currency=None)
  • get_currency(self)

New fields (18)
  • asset_id Many2one → asset.asset
    check_company=True string='Asset' args: 'asset.asset'
  • asset_purchase_amount Monetary
    string='Purchase Amount'
  • category_id Many2one → asset.category
    check_company=True string='Category' args: 'asset.category'
  • code Char
    default='' string='Code'
  • company_id Many2one → res.company
    default=get_default_company_id readonly=True string='Company' args: 'res.company'
  • currency_id Many2one → res.currency
    readonly=True related='company_id.currency_id' string='Currency' args: 'res.currency'
  • depreciated_fund_amount Monetary
    string='Depreciated Fund Amount'
  • depreciation_type_ids Many2many → asset.depreciation.type
    check_company=True string='Depreciation Types' args: 'asset.depreciation.type'
  • dismiss_asset_without_sale Boolean
  • dismiss_date Date
    default=fields.Date.today() string='Dismiss Date'
  • is_move_state_ok Boolean
    string='Move State'
  • management_type Selection
    string='Management Type' args: [('create', 'Create New'), ('update', 'Update Existing'), ('partial_dismiss', 'Partial Dismiss'), ('dismiss', 'Dismiss Asset')]
  • move_ids Many2many → account.move
    check_company=True default=get_default_move_ids string='Moves' args: 'account.move'
  • move_line_ids Many2many → account.move.line
    check_company=True string='Move Lines' args: 'account.move.line'
  • move_type Selection
    string='Move Type' args: [('sale', 'Sale'), ('purchase', 'Purchase'), ('general', 'Miscellaneous'), ('out_invoice', 'Customer Invoice'), ('in_invoice', 'Vendor Bill'), ('out_refund', 'Customer Credit Note'), ('in_refund', 'Vendor Credit Note'), ('wrong', 'Wrong')]
  • name Char
    string='Name'
  • purchase_date Date
    default=fields.Date.today() string='Purchase Date'
  • used Boolean
    string='Used'
Public methods (20)
  • check_pre_create_asset(self)
  • check_pre_dismiss_asset(self)
  • check_pre_link_asset(self)
  • check_pre_update_asset(self)
  • create_asset(self)
    Creates asset and returns it
  • dismiss_asset(self)
    Dismisses asset and returns it
  • get_create_asset_vals(self)
  • get_default_company_id(self)
    @api.model
  • get_default_move_ids(self)
    @api.model
  • get_dismiss_asset_vals(self)
  • get_management_type_2_method(self)
  • get_move_journal_type_2_dep_line_type(self)
  • get_partial_dismiss_asset_vals(self)
  • get_update_asset_vals(self)
  • link_asset(self)
  • onchange_category_id(self)
    @api.onchange('category_id')
  • onchange_depreciation_type_ids(self)
    @api.onchange('asset_id', 'management_type')
  • onchange_moves(self)
    @api.onchange('move_ids')
  • partial_dismiss_asset(self)
    Dismisses asset partially and returns it
  • update_asset(self)
    Updates asset and returns it

New fields (9)
  • asset_ids Many2many → asset.asset
    check_company=True string='Assets' args: 'asset.asset'
  • category_ids Many2many → asset.category
    check_company=True string='Categories' args: 'asset.category'
  • company_id Many2one → res.company
    check_company=True default=get_default_company_id readonly=True string='Company' args: 'res.company'
  • date_dep Date
    default=get_default_date_dep required=True string='Depreciation Date'
  • journal_id Many2one → account.journal
    comodel_name='account.journal' help="Create move entries in this journal instead of the category's journal." string='Override journal'
  • missing_fiscal_year_warning Text
    compute='_compute_missing_fiscal_year_warning' help='Message to warn the user that some fiscal years are missing.'
  • period Selection
    default='year' required=True selection=[('year', 'Year'), ('month', 'Month')]
  • period_count Integer
    default=1 string='Number of periods'
  • type_ids Many2many → asset.depreciation.type
    check_company=True default=get_default_type_ids required=True string='Depreciation Types' args: 'asset.depreciation.type'
Public methods (6)
  • do_generate(self)
    Launches the generation of new depreciation lines for the retrieved assets. Reloads the current window if necessary.
  • get_default_company_id(self)
    @api.model
  • get_default_date_dep(self)
    @api.model
  • get_default_type_ids(self)
    @api.model
  • get_depreciations(self)
  • get_depreciations_domain(self)

New fields (11)
  • asset_ids Many2many → asset.asset
    check_company=True string='Assets' args: 'asset.asset'
  • asset_order_fname Selection
    default=get_default_asset_order_fname required=True string='Asset Print Order' args: get_asset_order_fname_selection
  • category_ids Many2many → asset.category
    check_company=True default=get_default_category_ids string='Categories' args: 'asset.category'
  • company_id Many2one → res.company
    default=get_default_company_id readonly=True required=True string='Company' args: 'res.company'
  • date Date
    default=get_default_date string='To Date'
  • report_footer_year Char
    default=get_default_report_footer_year string='Report Footer Year'
  • show_category_totals Boolean
    default=True string='Show Category Totals'
  • show_dismissed_assets Boolean
  • show_sold_assets Boolean
    help='By default, only unsold or assets sold in the selected year are printed.\nBy selecting this flag, the report will show all assets, ignoring the sold check.'
  • show_totals Boolean
    default=True string='Show Totals'
  • type_ids Many2many → asset.depreciation.type
    check_company=True default=get_default_type_ids string='Depreciation Types' args: 'asset.depreciation.type'
Public methods (15)
  • button_export_asset_journal_html(self)
  • button_export_asset_journal_pdf(self)
  • button_export_asset_journal_xlsx(self)
  • export_asset_journal_report(self, report_type=None)
  • filter_assets(self)
  • get_asset_domain(self)
  • get_asset_order_fname_selection(self)
    @api.model
  • get_default_asset_order_fname(self)
    @api.model
  • get_default_category_ids(self)
    @api.model
  • get_default_company_id(self)
    @api.model
  • get_default_date(self)
    @api.model
  • get_default_report_footer_year(self)
    @api.model
  • get_default_type_ids(self)
    @api.model
  • onchange_assets(self)
    @api.onchange('category_ids', 'company_id', 'date', 'type_ids')
  • prepare_report_vals(self)

New fields (11)
  • asset_ids Many2many → asset.asset
    check_company=True string='Assets' args: 'asset.asset'
  • asset_order_fname Selection
    default=get_default_asset_order_fname required=True string='Asset Print Order' args: get_asset_order_fname_selection
  • category_ids Many2many → asset.category
    check_company=True default=get_default_category_ids string='Categories' args: 'asset.category'
  • company_id Many2one → res.company
    default=get_default_company_id readonly=True required=True string='Company' args: 'res.company'
  • date Date
    default=get_default_date string='To Date'
  • report_footer_year Char
    default=get_default_report_footer_year string='Report Footer Year'
  • show_category_totals Boolean
    default=True string='Show Category Totals'
  • show_dismissed_assets Boolean
  • show_sold_assets Boolean
    help='By default, only unsold or assets sold in the selected year are printed.\nBy selecting this flag, the report will show all assets, ignoring the sold check.'
  • show_totals Boolean
    default=True string='Show Totals'
  • type_ids Many2many → asset.depreciation.type
    check_company=True default=get_default_type_ids string='Depreciation Types' args: 'asset.depreciation.type'
Public methods (15)
  • button_export_asset_previsional_html(self)
  • button_export_asset_previsional_pdf(self)
  • button_export_asset_previsional_xlsx(self)
  • export_asset_previsional_report(self, report_type=None)
  • filter_assets(self)
  • get_asset_domain(self)
  • get_asset_order_fname_selection(self)
    @api.model
  • get_default_asset_order_fname(self)
    @api.model
  • get_default_category_ids(self)
    @api.model
  • get_default_company_id(self)
    @api.model
  • get_default_date(self)
    @api.model
  • get_default_report_footer_year(self)
    @api.model
  • get_default_type_ids(self)
    @api.model
  • onchange_assets(self)
    @api.onchange('category_ids', 'company_id', 'date', 'type_ids')
  • prepare_report_vals(self)
REPOSITORY
REPOSITORYOCA/l10n-italy
GIT
GIThttps://github.com/OCA/l10n-italy.git
GIT FOLDER
GIT FOLDERhttps://github.com/OCA/l10n-italy/tree/12.0/assets_management
VERSION
VERSION 1.0.2
CATEGORY
CATEGORYLocalization/Italy
LICENSE
LICENSEAGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLENo
AUTHORS
AUTHORSOdoo Community Association (OCA), Openforce
MAINTAINERS
MAINTAINERSOdoo Community Association (OCA), Openforce
COMMITTERS
COMMITTERSSergio Zanchetta, OCA Transbot, oca-travis, Weblate, OCA-git-bot, Simone Rubino, oca-ci, SilvioGregorini
WEBSITE
WEBSITEhttps://github.com/OCA/l10n-italy/tree/12.0/assets_management
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:29:17
ODOO DEPENDENCIES
ODOO DEPENDENCIES OCA/account-financial-reporting:
    - account_financial_report
OCA/account-financial-tools:
    - account_fiscal_year
OCA/reporting-engine:
    - report_xlsx
OCA/server-ux:
    - date_range
odoo/odoo:
    - account
    - base_setup
    - base
    - web
    - product
    - decimal_precision
    - mail
    - bus
    - web_tour
    - uom
    - analytic
    - portal
    - http_routing
    - digest
    - account_cancel
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES xlrd
xlsxwriter
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION

Code Analysis

Views touched (76)
XML IDNameModelTypeStatus
asset_accounting_info_form_view asset.accounting.info.form.view asset.accounting.info form New
asset_accounting_info_search_view asset.accounting.info.search.view asset.accounting.info search New
asset_accounting_info_tree_view asset.accounting.info.tree.view asset.accounting.info tree New
asset_category_form_view asset.category.form.view asset.category form New
asset_category_tree_view asset.category.asset.tree asset.category tree New
asset_dep_line_form_view asset.dep.line.form.view asset.depreciation.line form New
asset_dep_line_search_view asset.depreciation.line.view asset.depreciation.line search New
asset_dep_line_tree_view asset.dep.line.tree.view asset.depreciation.line tree New
asset_depreciation_line_type_form_view asset.dep.line.type.form.view asset.depreciation.line.type form New
asset_depreciation_line_type_tree_view asset.dep.line.type.tree.view asset.depreciation.line.type tree New
asset_depreciation_mode_form_view asset.depreciation.mode.form.view asset.depreciation.mode form New
asset_depreciation_mode_tree_view asset.depreciation.mode.tree.view asset.depreciation.mode tree New
asset_depreciation_type_form_view asset.depreciation.type.form.view asset.depreciation.type form New
asset_depreciation_type_tree_view asset.depreciation.type.tree.view asset.depreciation.type tree New
asset_form_view asset.form.view asset.asset form New
asset_search_view asset.search.view asset.asset search New
asset_tag_form_view asset.tag.form.view asset.tag form New
asset_tag_tree_view asset.tag.tree.view asset.tag tree New
asset_tree_view asset.tree.view asset.asset tree New
document_layout document_layout ir.ui.view qweb New
invoice_form_inherit invoice.form.inherit account.invoice xpath Inherits account.invoice_form
invoice_supplier_form_inherit invoice.supplier.form.inherit account.invoice xpath Inherits account.invoice_supplier_form
template_asset_journal_asset template_asset_journal_asset ir.ui.view qweb New
template_asset_journal_asset_accounting_table_data template_asset_journal_asset_accounting_table_data ir.ui.view qweb New
template_asset_journal_asset_accounting_table_header template_asset_journal_asset_accounting_table_header ir.ui.view qweb New
template_asset_journal_asset_depreciation_table_data template_asset_journal_asset_depreciation_table_data ir.ui.view qweb New
template_asset_journal_asset_depreciation_table_header template_asset_journal_asset_depreciation_table_header ir.ui.view qweb New
template_asset_journal_asset_depreciations template_asset_journal_asset_depreciations ir.ui.view qweb New
template_asset_journal_asset_table_data template_asset_journal_asset_table_data ir.ui.view qweb New
template_asset_journal_asset_table_header template_asset_journal_asset_table_header ir.ui.view qweb New
template_asset_journal_asset_title template_asset_journal_asset_title ir.ui.view qweb New
template_asset_journal_asset_year_depreciation_accounting_data template_asset_journal_asset_year_depreciation_accounting_data ir.ui.view qweb New
template_asset_journal_asset_year_depreciation_amount_details template_asset_journal_asset_year_depreciation_amount_details ir.ui.view qweb New
template_asset_journal_asset_year_depreciation_table_data template_asset_journal_asset_year_depreciation_table_data ir.ui.view qweb New
template_asset_journal_asset_year_depreciation_table_header template_asset_journal_asset_year_depreciation_table_header ir.ui.view qweb New
template_asset_journal_base template_asset_journal_base ir.ui.view qweb New
template_asset_journal_body template_asset_journal_body ir.ui.view qweb New
template_asset_journal_category_data template_asset_journal_category_data ir.ui.view qweb New
template_asset_journal_category_totals template_asset_journal_category_totals ir.ui.view qweb New
template_asset_journal_qweb template_asset_journal_qweb ir.ui.view qweb New
template_asset_journal_report template_asset_journal_report ir.ui.view qweb New
template_asset_journal_title template_asset_journal_title ir.ui.view qweb New
template_asset_journal_totals template_asset_journal_totals ir.ui.view qweb New
template_asset_journal_totals_data template_asset_journal_totals_data ir.ui.view qweb New
template_asset_journal_totals_header template_asset_journal_totals_header ir.ui.view qweb New
template_asset_previsional_asset template_asset_previsional_asset ir.ui.view qweb New
template_asset_previsional_asset_accounting_table_data template_asset_previsional_asset_accounting_table_data ir.ui.view qweb New
template_asset_previsional_asset_accounting_table_header template_asset_previsional_asset_accounting_table_header ir.ui.view qweb New
template_asset_previsional_asset_depreciation_table_data template_asset_previsional_asset_depreciation_table_data ir.ui.view qweb New
template_asset_previsional_asset_depreciation_table_header template_asset_previsional_asset_depreciation_table_header ir.ui.view qweb New
template_asset_previsional_asset_depreciations template_asset_previsional_asset_depreciations ir.ui.view qweb New
template_asset_previsional_asset_table_data template_asset_previsional_asset_table_data ir.ui.view qweb New
template_asset_previsional_asset_table_header template_asset_previsional_asset_table_header ir.ui.view qweb New
template_asset_previsional_asset_title template_asset_previsional_asset_title ir.ui.view qweb New
template_asset_previsional_asset_year_depreciation_table_data template_asset_previsional_asset_year_depreciation_table_data ir.ui.view qweb New
template_asset_previsional_asset_year_depreciation_table_header template_asset_previsional_asset_year_depreciation_table_header ir.ui.view qweb New
template_asset_previsional_base template_asset_previsional_base ir.ui.view qweb New
template_asset_previsional_body template_asset_previsional_body ir.ui.view qweb New
template_asset_previsional_category_data template_asset_previsional_category_data ir.ui.view qweb New
template_asset_previsional_category_totals template_asset_previsional_category_totals ir.ui.view qweb New
template_asset_previsional_qweb template_asset_previsional_qweb ir.ui.view qweb New
template_asset_previsional_report template_asset_previsional_report ir.ui.view qweb New
template_asset_previsional_title template_asset_previsional_title ir.ui.view qweb New
template_asset_previsional_totals template_asset_previsional_totals ir.ui.view qweb New
template_asset_previsional_totals_data template_asset_previsional_totals_data ir.ui.view qweb New
template_asset_previsional_totals_header template_asset_previsional_totals_header ir.ui.view qweb New
view_asset_depreciation_form asset.depreciation.form.view asset.depreciation form New
view_asset_depreciation_tree view.asset.depreciation.tree asset.depreciation tree New
view_invoice_line_form_inherit invoice.line.form.inherit account.invoice.line xpath Inherits account.view_invoice_line_form
view_move_form_inherit view.move.form.inherit account.move xpath Inherits account.view_move_form
view_move_line_form_inherit view.move.line.form.inherit account.move.line xpath Inherits account.view_move_line_form
wizard_account_move_mange_asset_form_view wizard.account.move.manage.asset.form.view wizard.account.move.manage.asset form New
wizard_asset_generate_depreciation_form_view wizard.asset.generate.depreciation.form.view wizard.asset.generate.depreciation form New
wizard_asset_journal_report_form_view wizard.asset.journal.report.form.view wizard.asset.journal.report form New
wizard_asset_previsional_report_form_view wizard.asset.previsional.report.form.view wizard.asset.previsional.report form New
wizard_invoice_mange_asset_form_view wizard.invoice.manage.asset.form.view wizard.invoice.manage.asset form New
Models touched (39)

New fields (0)

No new fields.

Public methods (1)
  • unlink(self)
    @api.multi

New fields (0)

No new fields.

Public methods (2)
  • get_fiscal_year_by_date(self, date, limit=1, company=None, miss_raise=True)
    @api.model
    Retrieves fiscal year by given ``date`` (a datetime.date object). By default, only 1 fiscal year will be returned, unless specified differently. If ``miss_raise`` is True and no fiscal year is found, an error will be raised.
  • get_fiscal_year_by_date_domain(self, date, company=None)
    @api.model
    Prepares a search() domain to retrieve fiscal years by given ``date``.

New fields (4)
  • asset_accounting_info_ids One2many → asset.accounting.info
    string='Assets Accounting Info' args: 'asset.accounting.info', 'invoice_id'
  • asset_ids Many2many → asset.asset
    compute='_compute_asset_data' store=True string='Assets' args: 'asset.asset'
  • dep_line_ids Many2many → asset.depreciation.line
    compute='_compute_asset_data' store=True string='Depreciation Lines' args: 'asset.depreciation.line'
  • hide_link_asset_button Boolean
    compute='_compute_hide_link_asset_button' default=True string='Hide Asset Button'
Public methods (5)
  • action_invoice_cancel(self)
    @api.multi
  • check_company(self)
    @api.constrains('company_id')
  • get_linked_aa_info_records(self)
  • get_valid_accounts(self)
  • open_wizard_manage_asset(self)
    @api.multi

New fields (3)
  • asset_accounting_info_ids One2many → asset.accounting.info
    string='Assets Accounting Info' args: 'asset.accounting.info', 'invoice_line_id'
  • asset_ids Many2many → asset.asset
    compute='_compute_asset_data' store=True string='Assets' args: 'asset.asset'
  • dep_line_ids Many2many → asset.depreciation.line
    compute='_compute_asset_data' store=True string='Depreciation Lines' args: 'asset.depreciation.line'
Public methods (3)
  • check_company(self)
    @api.constrains('company_id')
  • get_asset_purchase_amount(self, currency=None)
  • get_linked_aa_info_records(self)

New fields (0)

No new fields.

Public methods (1)
  • unlink(self)
    @api.multi

New fields (4)
  • asset_accounting_info_ids One2many → asset.accounting.info
    string='Assets Accounting Info' args: 'asset.accounting.info', 'move_id'
  • asset_ids Many2many → asset.asset
    compute='_compute_asset_data' store=True string='Assets' args: 'asset.asset'
  • dep_line_ids Many2many → asset.depreciation.line
    compute='_compute_asset_data' store=True string='Depreciation Lines' args: 'asset.depreciation.line'
  • hide_link_asset_button Boolean
    compute='_compute_hide_link_asset_button' default=True string='Hide Asset Button'
Public methods (5)
  • button_cancel(self)
    @api.multi
  • check_company(self)
    @api.constrains('company_id')
  • get_linked_aa_info_records(self)
  • get_valid_accounts(self)
  • open_wizard_manage_asset(self)
    @api.multi

New fields (3)
  • asset_accounting_info_ids One2many → asset.accounting.info
    string='Assets Accounting Info' args: 'asset.accounting.info', 'move_line_id'
  • asset_ids Many2many → asset.asset
    compute='_compute_asset_data' store=True string='Assets' args: 'asset.asset'
  • dep_line_ids Many2many → asset.depreciation.line
    compute='_compute_asset_data' store=True string='Depreciation Lines' args: 'asset.depreciation.line'
Public methods (3)
  • check_company(self)
    @api.constrains('company_id')
  • get_asset_purchase_amount(self, currency=None)
  • get_linked_aa_info_records(self)

New fields (8)
  • asset_id Many2one → asset.asset
    ondelete='set null' string='Asset' args: 'asset.asset'
  • company_id Many2one → res.company
    readonly=True string='Company' args: 'res.company'
  • dep_line_id Many2one → asset.depreciation.line
    ondelete='set null' string='Depreciation Line' args: 'asset.depreciation.line'
  • invoice_id Many2one → account.invoice
    ondelete='set null' string='Invoice' args: 'account.invoice'
  • invoice_line_id Many2one → account.invoice.line
    ondelete='set null' string='Invoice Line' args: 'account.invoice.line'
  • move_id Many2one → account.move
    ondelete='set null' string='Move' args: 'account.move'
  • move_line_id Many2one → account.move.line
    ondelete='set null' string='Move Line' args: 'account.move.line'
  • relation_type Selection
    required=True string='Relation Type' args: [('create', 'Asset Creation'), ('update', 'Asset Update'), ('partial_dismiss', 'Asset Partial Dismissal'), ('dismiss', 'Asset Dismissal')]
Public methods (15)
  • button_unlink(self)
    @api.multi
    Button action: deletes a.a.info
  • check_and_normalize(self)
  • check_coherence(self)
    Checks info coherence
  • check_company_coherence(self)
    Checks companies
  • check_data_coherence(self)
  • create(self, vals)
    @api.model
  • cron_vacuum_table(self)
    @api.model
    A cron that deletes obsolete records
  • get_all_companies(self)
  • get_main_fields(self)
    @api.model
  • get_normalized_info_vals(self)
  • get_records_to_delete_by_cron(self)
    Returns every a.a.info that fits the condition: (no asset AND no depreciation line) OR (no invoice AND no invoice line AND no move AND no move line)
  • make_name(self)
  • name_get(self)
    @api.multi
  • normalize_info(self)
    Normalize asset accounting info if needed
  • write(self, vals)
    @api.multi

New fields (21)
  • asset_accounting_info_ids One2many → asset.accounting.info
    string='Accounting Info' args: 'asset.accounting.info', 'asset_id'
  • category_id Many2one → asset.category
    required=True string='Category' args: 'asset.category'
  • code Char
    default='' string='Code'
  • company_id Many2one → res.company
    default=get_default_company_id required=True string='Company' track_visibility='onchange' args: 'res.company'
  • currency_id Many2one → res.currency
    required=True string='Currency' args: 'res.currency'
  • customer_id Many2one → res.partner
    string='Customer' args: 'res.partner'
  • depreciation_ids One2many → asset.depreciation
    string='Depreciations' args: 'asset.depreciation', 'asset_id'
  • name Char
    required=True string='Name' track_visibility='onchange'
  • purchase_amount Monetary
    string='Purchase Value' track_visibility='onchange'
  • purchase_date Date
    default=fields.Date.today() string='Purchase Date' track_visibility='onchange'
  • purchase_invoice_id Many2one → account.invoice
    string='Purchase Invoice' args: 'account.invoice'
  • purchase_move_id Many2one → account.move
    string='Purchase Move' args: 'account.move'
  • sale_amount Monetary
    string='Sale Value'
  • sale_date Date
    string='Sale Date'
  • sale_invoice_id Many2one → account.invoice
    string='Sale Invoice' args: 'account.invoice'
  • sale_move_id Many2one → account.move
    string='Sale Move' args: 'account.move'
  • sold Boolean
    string='Sold'
  • state Selection
    compute='_compute_state' default='non_depreciated' store=True string='State' args: [('non_depreciated', 'Non Depreciated'), ('partially_depreciated', 'Partially Depreciated'), ('totally_depreciated', 'Depreciated')]
  • supplier_id Many2one → res.partner
    string='Supplier' args: 'res.partner'
  • supplier_ref Char
    string='Supplier Ref.'
  • used Boolean
    string='Used'
Public methods (14)
  • check_company(self)
    @api.constrains('company_id')
  • create(self, vals)
    @api.model
  • get_asset_state(self)
  • get_default_company_id(self)
    @api.model
  • get_linked_aa_info_records(self)
  • launch_wizard_generate_depreciations(self)
    @api.multi
  • make_name(self)
  • name_get(self)
    @api.multi
  • onchange_category_id(self)
    @api.onchange('category_id')
  • onchange_company_currency(self)
    @api.onchange('company_id')
  • onchange_purchase_amount(self)
    @api.onchange('purchase_amount')
  • onchange_purchase_date(self)
    @api.onchange('purchase_date')
  • unlink(self)
    @api.multi
  • write(self, vals)
    @api.multi

New fields (12)
  • asset_account_id Many2one → account.account
    required=True string='Asset Account' args: 'account.account'
  • comment Text
    string='Comment'
  • company_id Many2one → res.company
    default=get_default_company_id string='Company' args: 'res.company'
  • depreciation_account_id Many2one → account.account
    required=True string='Depreciation Account' args: 'account.account'
  • fund_account_id Many2one → account.account
    required=True string='Fund Account' args: 'account.account'
  • gain_account_id Many2one → account.account
    required=True string='Capital Gain Account' args: 'account.account'
  • journal_id Many2one → account.journal
    required=True string='Journal' args: 'account.journal'
  • loss_account_id Many2one → account.account
    required=True string='Capital Loss Account' args: 'account.account'
  • name Char
    required=True string='Name'
  • print_by_default Boolean
    default=True help="Defines whether a category should be added by default when printing assets' reports." string='Print By Default'
  • tag_ids Many2many → asset.tag
    string='Tag' args: 'asset.tag'
  • type_ids One2many → asset.category.depreciation.type
    default=get_default_type_ids string='Depreciation Types' args: 'asset.category.depreciation.type', 'category_id'
Public methods (5)
  • copy(self, default=None)
    @api.multi
  • get_default_company_id(self)
    @api.model
  • get_default_type_ids(self)
    @api.model
  • get_depreciation_vals(self, amount_depreciable=0)
  • unlink(self)
    @api.multi

New fields (7)
  • base_coeff Float
    default=1 help='Coeff to compute depreciable amount from purchase amount' string='Dep Base Coeff'
  • category_id Many2one → asset.category
    ondelete='cascade' readonly=True required=True string='Category' args: 'asset.category'
  • company_id Many2one → res.company
    readonly=True related='category_id.company_id' string='Company' args: 'res.company'
  • depreciation_type_id Many2one → asset.depreciation.type
    required=True string='Type' args: 'asset.depreciation.type'
  • mode_id Many2one → asset.depreciation.mode
    required=True string='Dep Mode' args: 'asset.depreciation.mode'
  • percentage Float
    string='Depreciation %'
  • pro_rata_temporis Boolean
    string='Pro-rata Temporis'
Public methods (1)
  • get_depreciation_vals(self, amount_depreciable=0)

New fields (27)
  • amount_depreciable Monetary
    string='Depreciable Amount'
  • amount_depreciable_updated Monetary
    compute='_compute_amounts' store=True string='Updated Amount'
  • amount_depreciated Monetary
    compute='_compute_amounts' store=True string='Depreciated Amount'
  • amount_gain Monetary
    compute='_compute_amounts' store=True string='Capital Gain'
  • amount_historical Monetary
    compute='_compute_amounts' store=True string='Historical Amount'
  • amount_in Monetary
    compute='_compute_amounts' store=True string='In Amount'
  • amount_loss Monetary
    compute='_compute_amounts' store=True string='Capital Loss'
  • amount_out Monetary
    compute='_compute_amounts' store=True string='Out Amount'
  • amount_residual Monetary
    compute='_compute_amounts' store=True string='Residual Amount'
  • asset_id Many2one → asset.asset
    ondelete='cascade' readonly=True required=True string='Asset' args: 'asset.asset'
  • base_coeff Float
    default=1 help='Coeff to compute amount depreciable from purchase amount' string='Depreciable Base Coeff'
  • company_id Many2one → res.company
    readonly=True related='asset_id.company_id' string='Company' args: 'res.company'
  • currency_id Many2one → res.currency
    readonly=True related='asset_id.currency_id' string='Currency' args: 'res.currency'
  • date_start Date
    string='Date Start'
  • dismiss_move_id Many2one → account.move
    string='Dismiss Move' args: 'account.move'
  • first_dep_nr Integer
    default=1 string='First Dep. Num'
  • force_all_dep_nr Boolean
    string='Force All Dep. Num'
  • force_first_dep_nr Boolean
    string='Force First Dep. Num'
  • last_depreciation_date Date
    compute='_compute_last_depreciation_date' store=True string='Last Dep.'
  • line_ids One2many → asset.depreciation.line
    string='Lines' args: 'asset.depreciation.line', 'depreciation_id'
  • mode_id Many2one → asset.depreciation.mode
    required=True string='Mode' args: 'asset.depreciation.mode'
  • percentage Float
    string='Depreciation (%)'
  • pro_rata_temporis Boolean
    string='Pro-rata Temporis'
  • requires_account_move Boolean
    readonly=True related='type_id.requires_account_move' string='Requires Account Move'
  • state Selection
    compute='_compute_state' default='non_depreciated' store=True string='State' args: [('non_depreciated', 'Non Depreciated'), ('partially_depreciated', 'Partially Depreciated'), ('totally_depreciated', 'Depreciated')]
  • type_id Many2one → asset.depreciation.type
    string='Depreciation Type' args: 'asset.depreciation.type'
  • zero_depreciation_until Date
    string='Zero Depreciation Up To'
Public methods (28)
  • check_before_generate_depreciation_lines(self, dep_date)
  • create(self, vals)
    @api.model
  • generate_depreciation_lines(self, dep_date)
  • generate_depreciation_lines_single(self, dep_date)
  • generate_dismiss_account_move(self)
  • get_computed_amounts(self)
  • get_depreciable_amount(self, dep_date=None)
  • get_depreciation_amount(self, dep_date)
  • get_depreciation_amount_multiplier(self, dep_date)
  • get_depreciation_state(self)
  • get_dismiss_account_move_line_vals(self)
  • get_dismiss_account_move_vals(self)
  • get_max_depreciation_nr(self)
  • get_pro_rata_temporis_dates(self, date)
    Gets useful dates for pro rata temporis computations, according to given date, by retrieving its fiscal year. :param date: given date for depreciation :return: date objects triplet (dt_start, dt, dt_end) - dt_start: fiscal year first day - dt: given date - dt_end: fiscal year last day
  • get_pro_rata_temporis_multiplier(self, date=None, mode='std')
    Computes and returns pro rata temporis multiplier according to given depreciation, date, fiscal year and mode :param date: given date as a fields.Date string :param mode: string, defines how to compute multiplier. Valid values: - 'std': start-to-date, computes multiplier using days from fiscal year's first day to given date; - 'dte': date-to-end, computes multiplier using days from given date to fiscal year's last day
  • make_name(self)
  • name_get(self)
    @api.multi
  • need_normalize_first_dep_nr(self)
  • normalize_first_dep_nr(self, force=False)
    Normalize first numbered line according to `first_dep_nr` value :param force: if True, force normalization
  • onchange_base_coeff(self)
    @api.onchange('asset_id', 'base_coeff')
  • onchange_force_all_dep_nr(self)
    @api.onchange('force_all_dep_nr')
  • onchange_force_dep_nrs(self)
    @api.onchange('force_all_dep_nr', 'force_first_dep_nr')
  • onchange_force_first_dep_nr(self)
    @api.onchange('force_first_dep_nr')
  • onchange_normalize_first_dep_nr(self)
    @api.onchange('first_dep_nr')
  • post_generate_depreciation_lines(self, lines=None)
  • prepare_depreciation_line_vals(self, dep_date)
  • unlink(self)
    @api.multi
  • write(self, vals)
    @api.multi

New fields (20)
  • amount Monetary
    string='Amount'
  • asset_accounting_info_ids One2many → asset.accounting.info
    string='Accounting Info' args: 'asset.accounting.info', 'dep_line_id'
  • asset_id Many2one → asset.asset
    readonly=True related='depreciation_id.asset_id' store=True string='Asset' args: 'asset.asset'
  • balance Monetary
    compute='_compute_balance' store=True string='Balance'
  • base Float
    string='Base'
  • company_id Many2one → res.company
    readonly=True related='depreciation_id.company_id' args: 'res.company'
  • currency_id Many2one → res.currency
    readonly=True related='depreciation_id.currency_id' args: 'res.currency'
  • date Date
    required=True string='Date'
  • depreciation_id Many2one → asset.depreciation
    ondelete='cascade' readonly=True required=True string='Asset depreciation' args: 'asset.depreciation'
  • depreciation_line_type_id Many2one → asset.depreciation.line.type
    string='Depreciation Type' args: 'asset.depreciation.line.type'
  • depreciation_nr Integer
    string='Dep. Num'
  • depreciation_type_id Many2one → asset.depreciation.type
    readonly=True related='depreciation_id.type_id' store=True string='Asset depreciation type' args: 'asset.depreciation.type'
  • force_dep_nr Boolean
    readonly=True related='depreciation_id.force_all_dep_nr' string='Force Dep. Num'
  • move_id Many2one → account.move
    string='Move' args: 'account.move'
  • move_type Selection
    required=True string='Type' args: [('depreciated', 'Depreciation'), ('historical', 'Historical'), ('in', 'In'), ('out', 'Out'), ('loss', 'Capital Loss'), ('gain', 'Capital Gain')]
  • name Char
    required=True string='Name'
  • partial_dismissal Boolean
    string='Partial Dismissal'
  • percentage Float
    string='%'
  • requires_account_move Boolean
    readonly=True related='depreciation_id.type_id.requires_account_move' string='Required Account Move'
  • requires_depreciation_nr Boolean
    compute='_compute_requires_depreciation_nr' search='_search_requires_depreciation_nr_lines' string='Requires Dep Num'
Public methods (34)
  • button_generate_account_move(self)
    @api.multi
  • button_regenerate_account_move(self)
    @api.multi
  • button_remove_account_move(self)
    @api.multi
  • check_company(self)
    @api.constrains('company_id')
  • check_depreciation_nr_coherence(self)
    @api.constrains('depreciation_nr')
  • create(self, vals)
    @api.model
  • generate_account_move(self)
  • generate_account_move_single(self)
  • get_account_move_line_vals(self)
    Switcher between methods
  • get_account_move_line_vals_methods(self)
    Maps line `move_type` to its own method for generating move lines.
  • get_account_move_vals(self)
  • get_balances_grouped(self)
    Groups balances of line in `self` by line.move_type
  • get_depreciated_account_move_line_vals(self)
  • get_depreciation_nr_dict(self)
    Returns dict {line: new number}
  • get_gain_account_move_line_vals(self)
  • get_historical_account_move_line_vals(self)
  • get_in_account_move_line_vals(self)
  • get_linked_aa_info_records(self)
  • get_loss_account_move_line_vals(self)
  • get_non_residual_move_types(self)
    Returns list of `move_type` vals that do not concur to asset.depreciation's `amount_residual` field compute
  • get_numbered_move_types(self)
    Returns list of `move_type` vals that require numeration
  • get_out_account_move_line_vals(self)
  • get_update_move_types(self)
    Returns list of `move_type` that concur to update asset.depreciation's `amount_depreciable_updated` field
  • is_depreciation_nr_required(self)
    Defines if a line requires to be numbered
  • make_name(self)
  • name_get(self)
    @api.multi
  • need_normalize_depreciation_nr(self)
    Check if numbers need to be normalized
  • needs_account_move(self)
  • normalize_depreciation_nr(self, force=False)
    Normalize depreciation numbers to be consecutive for depreciation and historical lines within the same depreciation set; force to 0 every non-depreciation line. :param force: force normalization for every depreciations' lines
  • onchange_move_type(self)
    @api.onchange('move_type')
  • post_dismiss_asset(self)
  • post_partial_dismiss_asset(self)
  • unlink(self)
    @api.multi
  • write(self, vals)
    @api.multi

New fields (4)
  • code Char
    string='Code'
  • company_id Many2one → res.company
    default=get_default_company_id string='Company' args: 'res.company'
  • name Char
    required=True string='Name'
  • type Selection
    string='Type' args: [('in', 'In'), ('out', 'Out')]
Public methods (4)
  • get_default_company_id(self)
    @api.model
  • make_name(self)
  • name_get(self)
    @api.multi
  • unlink(self)
    @api.multi

New fields (5)
  • company_id Many2one → res.company
    default=get_default_company_id string='Company' args: 'res.company'
  • default Boolean
    string='Default Mode'
  • line_ids One2many → asset.depreciation.mode.line
    string='Lines' args: 'asset.depreciation.mode.line', 'mode_id'
  • name Char
    required=True string='Name'
  • used_asset_coeff Float
    default=1.0 string='Used Asset Coeff.'
Public methods (5)
  • check_default_modes(self)
    @api.constrains('company_id', 'default')
  • copy(self, default=None)
    @api.multi
  • get_default_company_id(self)
    @api.model
  • get_depreciation_amount_multiplier(self)
  • unlink(self)
    @api.multi

New fields (7)
  • application Selection
    default='coefficient' required=True string='Application by' args: [('coefficient', 'Coefficient'), ('percentage', 'Percentage')]
  • coefficient Float
    string='Coefficient'
  • company_id Many2one → res.company
    readonly=True related='mode_id.company_id' string='Company' args: 'res.company'
  • from_nr Integer
    required=True string='From Nr'
  • mode_id Many2one → asset.depreciation.mode
    ondelete='cascade' readonly=True required=True string='Mode' args: 'asset.depreciation.mode'
  • percentage Float
    string='Percentage'
  • to_nr Integer
    string='To Nr'
Public methods (2)
  • get_depreciation_amount_multiplier(self)
  • onchange_application(self)
    @api.onchange('application')

New fields (4)
  • company_id Many2one → res.company
    default=get_default_company_id string='Company' args: 'res.company'
  • name Char
    required=True string='Name'
  • print_by_default Boolean
    default=True help="Defines whether a category should be added by default when printing assets' reports." string='Print By Default'
  • requires_account_move Boolean
    string='Requires Account Move'
Public methods (2)
  • get_default_company_id(self)
    @api.model
  • unlink(self)
    @api.multi

New fields (2)
  • company_id Many2one → res.company
    default=get_default_company_id string='Company' args: 'res.company'
  • name Char
    required=True string='Name'
Public methods (1)
  • get_default_company_id(self)
    @api.model

New fields (0)

No new fields.

Public methods (23)
  • generate_asset_accounting_doc_data(self)
  • generate_asset_data(self)
  • generate_category_data(self)
  • generate_depreciation_data(self)
  • generate_depreciation_line_accounting_doc_data(self)
  • generate_depreciation_line_amount_detail_data(self)
  • generate_depreciation_line_year_data(self)
  • generate_xlsx_report(self, workbook, data, objects)
    Set wb, data and report attributes
  • get_max_width_dict(self)
  • get_totals_data(self)
  • set_asset_accounting_doc_data(self)
  • set_asset_data(self)
  • set_category_data(self)
  • set_depreciation_data(self)
  • set_depreciation_line_accounting_doc_data(self)
  • set_depreciation_line_amount_detail_data(self)
  • set_depreciation_line_year_data(self)
  • set_formats(self)
    Defines custom formats
  • set_report_data(self)
  • set_totals_data(self)
  • write_all(self, data, obj)
  • write_header(self, data)
  • write_value(self, data, obj)

New fields (0)

No new fields.

Public methods (21)
  • generate_asset_accounting_doc_data(self)
  • generate_asset_data(self)
  • generate_category_data(self)
  • generate_depreciation_data(self)
  • generate_depreciation_line_amount_detail_data(self)
  • generate_depreciation_line_year_data(self)
  • generate_xlsx_report(self, workbook, data, objects)
    Set wb, data and report attributes
  • get_max_width_dict(self)
  • get_totals_data(self)
  • set_asset_accounting_doc_data(self)
  • set_asset_data(self)
  • set_category_data(self)
  • set_depreciation_data(self)
  • set_depreciation_line_amount_detail_data(self)
  • set_depreciation_line_year_data(self)
  • set_formats(self)
    Defines custom formats
  • set_report_data(self)
  • set_totals_data(self)
  • write_all(self, data, obj)
  • write_header(self, data)
  • write_value(self, data, obj)

New fields (15)
  • asset_ids Many2many → asset.asset
    args: 'asset.asset'
  • asset_order_fname Char
  • category_ids Many2many → asset.category
    args: 'asset.category'
  • company_id Many2one → res.company
    args: 'res.company'
  • date Date
  • report_asset_ids One2many → report_asset_journal_asset
    args: 'report_asset_journal_asset', 'report_id'
  • report_category_ids One2many → report_asset_journal_category
    args: 'report_asset_journal_category', 'report_id'
  • report_depreciation_ids One2many → report_asset_journal_depreciation
    args: 'report_asset_journal_depreciation', 'report_id'
  • report_depreciation_line_year_ids One2many → report_asset_journal_depreciation_line_year
    args: 'report_asset_journal_depreciation_line_year', 'report_id'
  • report_footer_year Char
  • report_name Char
  • report_total_ids One2many → report_asset_journal_totals
    args: 'report_asset_journal_totals', 'report_id'
  • show_category_totals Boolean
  • show_totals Boolean
  • type_ids Many2many → asset.depreciation.type
    args: 'asset.depreciation.type'
Public methods (11)
  • compute_data_for_report(self)
    Compute data to be printed
  • do_print(self, report_type)
  • generate_data(self)
  • generate_structure(self)
  • generate_totals(self)
  • get_depreciations(self)
  • get_html(self, given_context=None)
    @api.model
    Method needed from JavaScript widget to render HTML view
  • print_report(self, report_type=None)
    @api.multi
    This method is called from the JS widget buttons 'Print' and 'Export' in the HTML view. Prints PDF and XLSX reports. :param report_type: string that represents the report type
  • set_report_name(self)
  • sort_assets(self, assets)
  • view_report(self)
    @api.multi
    Launches view for HTML report

New fields (9)
  • document_date Char
  • document_nr Char
  • partner_name Char
  • partner_ref Char
  • partner_vat Char
  • report_id Many2one → report_asset_journal
    args: 'report_asset_journal'
  • res_id Integer
  • res_model Char
  • sequence Integer
Public methods (0)

No public methods.

New fields (11)
  • asset_code Char
  • asset_id Many2one → asset.asset
    ondelete='cascade' required=True args: 'asset.asset'
  • asset_name Char
  • asset_purchase_amount Float
  • asset_state Char
  • asset_used Char
  • report_category_id Many2one → report_asset_journal_category
    args: 'report_asset_journal_category'
  • report_depreciation_ids One2many → report_asset_journal_depreciation
    args: 'report_asset_journal_depreciation', 'report_asset_id'
  • report_id Many2one → report_asset_journal
    args: 'report_asset_journal'
  • report_purchase_doc_id Many2one → report_asset_journal_accounting_doc
    args: 'report_asset_journal_accounting_doc'
  • report_sale_doc_id Many2one → report_asset_journal_accounting_doc
    args: 'report_asset_journal_accounting_doc'
Public methods (6)
  • format_amount(self, amount, currency=None)
  • generate_data(self)
  • get_currency(self)
  • get_purchase_vals(self)
  • get_report_asset_data(self)
  • get_sale_vals(self)

New fields (5)
  • category_id Many2one → asset.category
    ondelete='cascade' required=True args: 'asset.category'
  • category_name Char
  • report_asset_ids One2many → report_asset_journal_asset
    args: 'report_asset_journal_asset', 'report_category_id'
  • report_id Many2one → report_asset_journal
    args: 'report_asset_journal'
  • report_total_ids One2many → report_asset_journal_totals
    args: 'report_asset_journal_totals', 'report_category_id'
Public methods (3)
  • generate_data(self)
  • generate_totals(self)
  • get_report_categ_data(self)

New fields (10)
  • dep_amount_depreciable Float
  • dep_date_start Char
  • dep_percentage Float
  • dep_pro_rata_temporis Char
  • depreciation_id Many2one → asset.depreciation
    ondelete='cascade' required=True args: 'asset.depreciation'
  • mode_name Char
  • report_asset_id Many2one → report_asset_journal_asset
    args: 'report_asset_journal_asset'
  • report_depreciation_year_line_ids One2many → report_asset_journal_depreciation_line_year
    args: 'report_asset_journal_depreciation_line_year', 'report_depreciation_id'
  • report_id Many2one → report_asset_journal
    args: 'report_asset_journal'
  • type_name Char
Public methods (4)
  • format_amount(self, amount, currency=None)
  • generate_data(self)
  • get_currency(self)
  • get_report_dep_data(self)

New fields (30)
  • amount_depreciable Float
  • amount_depreciable_updated Float
  • amount_depreciated Float
  • amount_depreciation_fund_curr_year Float
  • amount_depreciation_fund_prev_year Float
  • amount_gain Float
  • amount_gain_total Float
  • amount_historical Float
  • amount_in Float
  • amount_in_detail Char
  • amount_in_total Float
  • amount_loss Float
  • amount_loss_total Float
  • amount_out Float
  • amount_out_detail Char
  • amount_out_total Float
  • amount_residual Float
  • date_start Char
  • dep_line_ids Many2many → asset.depreciation.line
    relation='report_journal_line_year_dep_line' args: 'asset.depreciation.line'
  • fiscal_year_id Many2one → account.fiscal.year
    args: 'account.fiscal.year'
  • gain_loss Float
  • gain_loss_total Float
  • has_amount_detail Boolean
  • percentage Float
  • report_accounting_doc_ids Many2many → report_asset_journal_accounting_doc
    relation='year_dep_line_accounting_doc_rel' args: 'report_asset_journal_accounting_doc'
  • report_depreciation_id Many2one → report_asset_journal_depreciation
    args: 'report_asset_journal_depreciation'
  • report_id Many2one → report_asset_journal
    args: 'report_asset_journal'
  • sequence Integer
  • type_name Char
  • year Char
Public methods (4)
  • format_amount(self, amount, currency=None)
  • generate_data(self)
  • get_currency(self)
  • get_report_dep_line_year_data(self)

New fields (16)
  • amount_depreciable_updated Float
  • amount_depreciated Float
  • amount_depreciation_fund_curr_year Float
  • amount_depreciation_fund_prev_year Float
  • amount_gain Float
  • amount_in_total Float
  • amount_loss Float
  • amount_out_total Float
  • amount_residual Float
  • gain_loss Float
  • gain_loss_total Float
  • name Char
  • report_category_id Many2one → report_asset_journal_category
    args: 'report_asset_journal_category'
  • report_id Many2one → report_asset_journal
    args: 'report_asset_journal'
  • type_id Many2one → asset.depreciation.type
    args: 'asset.depreciation.type'
  • type_name Char
Public methods (2)
  • format_amount(self, amount, currency=None)
  • get_currency(self)

New fields (16)
  • asset_ids Many2many → asset.asset
    args: 'asset.asset'
  • asset_order_fname Char
  • category_ids Many2many → asset.category
    args: 'asset.category'
  • company_id Many2one → res.company
    args: 'res.company'
  • date Date
  • previsional_line_ids Many2many → asset.depreciation.line
    args: 'asset.depreciation.line'
  • report_asset_ids One2many → report_asset_previsional_asset
    args: 'report_asset_previsional_asset', 'report_id'
  • report_category_ids One2many → report_asset_previsional_category
    args: 'report_asset_previsional_category', 'report_id'
  • report_depreciation_ids One2many → report_asset_previsional_depreciation
    args: 'report_asset_previsional_depreciation', 'report_id'
  • report_depreciation_line_year_ids One2many → report_asset_previsional_depreciation_line_year
    args: 'report_asset_previsional_depreciation_line_year', 'report_id'
  • report_footer_year Char
  • report_name Char
  • report_total_ids One2many → report_asset_previsional_totals
    args: 'report_asset_previsional_totals', 'report_id'
  • show_category_totals Boolean
  • show_totals Boolean
  • type_ids Many2many → asset.depreciation.type
    args: 'asset.depreciation.type'
Public methods (11)
  • compute_data_for_report(self)
    Compute data to be printed
  • do_print(self, report_type)
  • generate_data(self)
  • generate_structure(self)
  • generate_totals(self)
  • get_assets(self)
  • get_html(self, given_context=None)
    @api.model
    Method needed from JavaScript widget to render HTML view
  • print_report(self, report_type=None)
    @api.multi
    This method is called from the JS widget buttons 'Print' and 'Export' in the HTML view. Prints PDF and XLSX reports. :param report_type: string that represents the report type
  • set_report_name(self)
  • sort_assets(self, assets)
  • view_report(self)
    @api.multi
    Launches view for HTML report

New fields (9)
  • document_date Char
  • document_nr Char
  • partner_name Char
  • partner_ref Char
  • partner_vat Char
  • report_id Many2one → report_asset_previsional
    args: 'report_asset_previsional'
  • res_id Integer
  • res_model Char
  • sequence Integer
Public methods (0)

No public methods.

New fields (11)
  • asset_code Char
  • asset_id Many2one → asset.asset
    ondelete='cascade' required=True args: 'asset.asset'
  • asset_name Char
  • asset_purchase_amount Float
  • asset_state Char
  • asset_used Char
  • report_category_id Many2one → report_asset_previsional_category
    args: 'report_asset_previsional_category'
  • report_depreciation_ids One2many → report_asset_previsional_depreciation
    args: 'report_asset_previsional_depreciation', 'report_asset_id'
  • report_id Many2one → report_asset_previsional
    args: 'report_asset_previsional'
  • report_purchase_doc_id Many2one → report_asset_previsional_accounting_doc
    args: 'report_asset_previsional_accounting_doc'
  • report_sale_doc_id Many2one → report_asset_previsional_accounting_doc
    args: 'report_asset_previsional_accounting_doc'
Public methods (6)
  • format_amount(self, amount, currency=None)
  • generate_data(self)
  • get_currency(self)
  • get_purchase_vals(self)
  • get_report_asset_data(self)
  • get_sale_vals(self)

New fields (5)
  • category_id Many2one → asset.category
    ondelete='cascade' required=True args: 'asset.category'
  • category_name Char
  • report_asset_ids One2many → report_asset_previsional_asset
    args: 'report_asset_previsional_asset', 'report_category_id'
  • report_id Many2one → report_asset_previsional
    args: 'report_asset_previsional'
  • report_total_ids One2many → report_asset_previsional_totals
    args: 'report_asset_previsional_totals', 'report_category_id'
Public methods (3)
  • generate_data(self)
  • generate_totals(self)
  • get_report_categ_data(self)

New fields (10)
  • dep_amount_depreciable Float
  • dep_date_start Char
  • dep_percentage Float
  • dep_pro_rata_temporis Char
  • depreciation_id Many2one → asset.depreciation
    ondelete='cascade' required=True args: 'asset.depreciation'
  • mode_name Char
  • report_asset_id Many2one → report_asset_previsional_asset
    args: 'report_asset_previsional_asset'
  • report_depreciation_year_line_ids One2many → report_asset_previsional_depreciation_line_year
    args: 'report_asset_previsional_depreciation_line_year', 'report_depreciation_id'
  • report_id Many2one → report_asset_previsional
    args: 'report_asset_previsional'
  • type_name Char
Public methods (4)
  • format_amount(self, amount, currency=None)
  • generate_data(self)
  • get_currency(self)
  • get_report_dep_data(self)

New fields (31)
  • amount_depreciable Float
  • amount_depreciable_updated Float
  • amount_depreciated Float
  • amount_depreciation_fund_curr_year Float
  • amount_depreciation_fund_prev_year Float
  • amount_gain Float
  • amount_gain_total Float
  • amount_historical Float
  • amount_in Float
  • amount_in_detail Char
  • amount_in_total Float
  • amount_loss Float
  • amount_loss_total Float
  • amount_out Float
  • amount_out_detail Char
  • amount_out_total Float
  • amount_residual Float
  • date_start Char
  • dep_line_ids Many2many → asset.depreciation.line
    relation='report_previsional_line_year_dep_line' args: 'asset.depreciation.line'
  • fiscal_year_id Many2one → account.fiscal.year
    args: 'account.fiscal.year'
  • gain_loss Float
  • gain_loss_total Float
  • has_amount_detail Boolean
  • hidden Boolean
  • needs_previsional Boolean
  • percentage Float
  • report_depreciation_id Many2one → report_asset_previsional_depreciation
    args: 'report_asset_previsional_depreciation'
  • report_id Many2one → report_asset_previsional
    args: 'report_asset_previsional'
  • sequence Integer
  • type_name Char
  • year Char
Public methods (8)
  • clean_unused(self)
  • do_clean(self)
  • format_amount(self, amount, currency=None)
  • generate_data(self)
  • generate_previsional_line_single(self)
  • generate_previsional_lines(self)
  • get_currency(self)
  • get_report_dep_line_year_data(self)

New fields (16)
  • amount_depreciable_updated Float
  • amount_depreciated Float
  • amount_depreciation_fund_curr_year Float
  • amount_depreciation_fund_prev_year Float
  • amount_gain Float
  • amount_in_total Float
  • amount_loss Float
  • amount_out_total Float
  • amount_residual Float
  • gain_loss Float
  • gain_loss_total Float
  • name Char
  • report_category_id Many2one → report_asset_previsional_category
    args: 'report_asset_previsional_category'
  • report_id Many2one → report_asset_previsional
    args: 'report_asset_previsional'
  • type_id Many2one → asset.depreciation.type
    args: 'asset.depreciation.type'
  • type_name Char
Public methods (2)
  • format_amount(self, amount, currency=None)
  • get_currency(self)

New fields (17)
  • asset_id Many2one → asset.asset
    string='Asset' args: 'asset.asset'
  • asset_purchase_amount Monetary
    string='Purchase Amount'
  • category_id Many2one → asset.category
    string='Category' args: 'asset.category'
  • code Char
    default='' string='Code'
  • company_id Many2one → res.company
    default=get_default_company_id string='Company' args: 'res.company'
  • currency_id Many2one → res.currency
    readonly=True related='company_id.currency_id' string='Currency' args: 'res.currency'
  • depreciated_fund_amount Monetary
    string='Depreciated Fund Amount'
  • depreciation_type_ids Many2many → asset.depreciation.type
    string='Depreciation Types' args: 'asset.depreciation.type'
  • dismiss_date Date
    default=fields.Date.today() string='Dismiss Date'
  • is_move_state_ok Boolean
    string='Move State'
  • management_type Selection
    string='Management Type' args: [('create', 'Create New'), ('update', 'Update Existing'), ('partial_dismiss', 'Partial Dismiss'), ('dismiss', 'Dismiss Asset')]
  • move_ids Many2many → account.move
    default=get_default_move_ids string='Moves' args: 'account.move'
  • move_line_ids Many2many → account.move.line
    string='Move Lines' args: 'account.move.line'
  • move_type Selection
    string='Move Type' args: [('sale', 'Sale'), ('purchase', 'Purchase'), ('general', 'Miscellaneous'), ('wrong', 'Wrong')]
  • name Char
    string='Name'
  • purchase_date Date
    default=fields.Date.today() string='Purchase Date'
  • used Boolean
    string='Used'
Public methods (20)
  • check_pre_create_asset(self)
  • check_pre_dismiss_asset(self)
  • check_pre_link_asset(self)
  • check_pre_partial_dismiss_asset(self)
  • check_pre_update_asset(self)
  • create_asset(self)
    Creates asset and returns it
  • dismiss_asset(self)
    Dismisses asset and returns it
  • get_create_asset_vals(self)
  • get_default_company_id(self)
    @api.model
  • get_default_move_ids(self)
    @api.model
  • get_dismiss_asset_vals(self)
  • get_management_type_2_method(self)
  • get_move_journal_type_2_dep_line_type(self)
  • get_partial_dismiss_asset_vals(self)
  • get_update_asset_vals(self)
  • link_asset(self)
    @api.multi
  • onchange_depreciation_type_ids(self)
    @api.onchange('asset_id', 'management_type')
  • onchange_moves(self)
    @api.onchange('move_ids')
  • partial_dismiss_asset(self)
    Dismisses asset partially and returns it
  • update_asset(self)
    Updates asset and returns it

New fields (5)
  • asset_ids Many2many → asset.asset
    string='Assets' args: 'asset.asset'
  • category_ids Many2many → asset.category
    string='Categories' args: 'asset.category'
  • company_id Many2one → res.company
    default=get_default_company_id string='Company' args: 'res.company'
  • date_dep Date
    default=get_default_date_dep required=True string='Depreciation Date'
  • type_ids Many2many → asset.depreciation.type
    default=get_default_type_ids required=True string='Depreciation Types' args: 'asset.depreciation.type'
Public methods (6)
  • do_generate(self)
    @api.multi
    Launches the generation of new depreciation lines for the retrieved assets. Reloads the current window if necessary.
  • get_default_company_id(self)
    @api.model
  • get_default_date_dep(self)
    @api.model
  • get_default_type_ids(self)
    @api.model
  • get_depreciations(self)
  • get_depreciations_domain(self)

New fields (9)
  • asset_ids Many2many → asset.asset
    string='Assets' args: 'asset.asset'
  • asset_order_fname Selection
    default=get_default_asset_order_fname required=True string='Asset Print Order' args: get_asset_order_fname_selection
  • category_ids Many2many → asset.category
    default=get_default_category_ids string='Categories' args: 'asset.category'
  • company_id Many2one → res.company
    default=get_default_company_id required=True string='Company' args: 'res.company'
  • date Date
    default=get_default_date string='To Date'
  • report_footer_year Char
    default=get_default_report_footer_year string='Report Footer Year'
  • show_category_totals Boolean
    default=True string='Show Category Totals'
  • show_totals Boolean
    default=True string='Show Totals'
  • type_ids Many2many → asset.depreciation.type
    default=get_default_type_ids string='Depreciation Types' args: 'asset.depreciation.type'
Public methods (16)
  • button_export_asset_journal_html(self)
    @api.multi
  • button_export_asset_journal_pdf(self)
    @api.multi
  • button_export_asset_journal_xlsx(self)
    @api.multi
  • export_asset_journal_report(self, report_type=None)
  • filter_assets(self)
  • get_asset_domain(self)
  • get_asset_order_fname_selection(self)
    @api.model
  • get_default_asset_order_fname(self)
    @api.model
  • get_default_category_ids(self)
    @api.model
  • get_default_company_id(self)
    @api.model
  • get_default_date(self)
    @api.model
  • get_default_report_footer_year(self)
    @api.model
  • get_default_report_footer_year(self)
    @api.model
  • get_default_type_ids(self)
    @api.model
  • onchange_assets(self)
    @api.onchange('category_ids', 'company_id', 'date', 'type_ids')
  • prepare_report_vals(self)

New fields (9)
  • asset_ids Many2many → asset.asset
    string='Assets' args: 'asset.asset'
  • asset_order_fname Selection
    default=get_default_asset_order_fname required=True string='Asset Print Order' args: get_asset_order_fname_selection
  • category_ids Many2many → asset.category
    default=get_default_category_ids string='Categories' args: 'asset.category'
  • company_id Many2one → res.company
    default=get_default_company_id required=True string='Company' args: 'res.company'
  • date Date
    default=get_default_date string='To Date'
  • report_footer_year Char
    default=get_default_report_footer_year string='Report Footer Year'
  • show_category_totals Boolean
    default=True string='Show Category Totals'
  • show_totals Boolean
    default=True string='Show Totals'
  • type_ids Many2many → asset.depreciation.type
    default=get_default_type_ids string='Depreciation Types' args: 'asset.depreciation.type'
Public methods (15)
  • button_export_asset_previsional_html(self)
    @api.multi
  • button_export_asset_previsional_pdf(self)
    @api.multi
  • button_export_asset_previsional_xlsx(self)
    @api.multi
  • export_asset_previsional_report(self, report_type=None)
  • filter_assets(self)
  • get_asset_domain(self)
  • get_asset_order_fname_selection(self)
    @api.model
  • get_default_asset_order_fname(self)
    @api.model
  • get_default_category_ids(self)
    @api.model
  • get_default_company_id(self)
    @api.model
  • get_default_date(self)
    @api.model
  • get_default_report_footer_year(self)
    @api.model
  • get_default_type_ids(self)
    @api.model
  • onchange_assets(self)
    @api.onchange('category_ids', 'company_id', 'date', 'type_ids')
  • prepare_report_vals(self)

New fields (17)
  • asset_id Many2one → asset.asset
    string='Asset' args: 'asset.asset'
  • asset_purchase_amount Monetary
    string='Purchase Amount'
  • category_id Many2one → asset.category
    string='Category' args: 'asset.category'
  • code Char
    default='' string='Code'
  • company_id Many2one → res.company
    default=get_default_company_id string='Company' args: 'res.company'
  • currency_id Many2one → res.currency
    readonly=True related='company_id.currency_id' string='Currency' args: 'res.currency'
  • depreciated_fund_amount Monetary
    string='Depreciated Fund Amount'
  • depreciation_type_ids Many2many → asset.depreciation.type
    string='Depreciation Types' args: 'asset.depreciation.type'
  • dismiss_date Date
    default=fields.Date.today() string='Dismiss Date'
  • invoice_ids Many2many → account.invoice
    default=get_default_invoice_ids string='Invoices' args: 'account.invoice'
  • invoice_line_ids Many2many → account.invoice.line
    string='Invoice Lines' args: 'account.invoice.line'
  • invoice_type Selection
    string='Invoice Type' args: [('out_invoice', 'Customer Invoice'), ('in_invoice', 'Vendor Bill'), ('out_refund', 'Customer Credit Note'), ('in_refund', 'Vendor Credit Note'), ('wrong', 'Wrong')]
  • is_invoice_state_ok Boolean
    string='Invoice State'
  • management_type Selection
    string='Management Type' args: [('create', 'Create New'), ('update', 'Update Existing'), ('partial_dismiss', 'Partial Dismiss'), ('dismiss', 'Dismiss Asset')]
  • name Char
    string='Name'
  • purchase_date Date
    default=fields.Date.today() string='Purchase Date'
  • used Boolean
    string='Used'
Public methods (20)
  • check_pre_create_asset(self)
  • check_pre_dismiss_asset(self)
  • check_pre_link_asset(self)
  • check_pre_partial_dismiss_asset(self)
  • check_pre_update_asset(self)
  • create_asset(self)
    Creates asset and returns it
  • dismiss_asset(self)
    Dismisses asset and returns it
  • get_create_asset_vals(self)
  • get_default_company_id(self)
    @api.model
  • get_default_invoice_ids(self)
    @api.model
  • get_dismiss_asset_vals(self)
  • get_invoice_type_2_dep_line_type(self)
  • get_management_type_2_method(self)
  • get_partial_dismiss_asset_vals(self)
  • get_update_asset_vals(self)
  • link_asset(self)
    @api.multi
  • onchange_depreciation_type_ids(self)
    @api.onchange('asset_id', 'management_type')
  • onchange_invoices(self)
    @api.onchange('invoice_ids')
  • partial_dismiss_asset(self)
    Dismisses asset partially and returns it
  • update_asset(self)
    Updates asset and returns it