TIP: You can type at any time to perform a new search.
Sustainability Employee Commuting
sustainability_employee_commuting · OCA/sustainability
- Repository
- OCA/sustainability · module folder · Try on Runboat
- Module version
- 1.2.1
- Category
- Accounting/Sustainability
- Folder size
- 0.1 MB
- License
- AGPL-3
- Application
- No
- Auto-installable
- No
- Website
- https://github.com/sustainability-suite/sustainability-odoo
- Last tracking update
- 2026-09-21 11:18:10
- Authors
- Open Net Sàrl, MCO2
- Maintainers
- Open Net Sàrl, MCO2
- Committers
- Julien Guenat, SustainabilityBot, sustainabilitybot, Adam Bonnet
Code Analysis ⓘ
Views touched (2)
| XML ID | Name | Model | Type | Status |
|---|---|---|---|---|
res_config_settings_view_form |
res.config.settings.view.form.inherit.sustainability.commuting | res.config.settings | form | Inherits sustainability.res_config_settings_view_form |
view_employee_form_commuting |
hr.employee.form.inherit.commuting | hr.employee | form | Inherits hr.view_employee_form |
HTTP endpoints (0)
No HTTP endpoints found for this module.
Models touched (6)
New fields (4)
-
employee_commuting_carbon_dateDatecopy=Falsedefault=False args: 'Employee commuting date' -
employee_remote_work_carbon_dateDatecopy=Falsedefault=False -
is_employee_commuting_carbonBooleancopy=Falsedefault=False args: "Employees' commuting carbon emissions" -
is_employee_remote_work_carbonBooleancopy=Falsedefault=False
No public methods.
New fields (4)
-
allowed_carbon_factor_idsMany2many → carbon.factordomain=<expr>related='employee_id.company_id.employee_commuting_carbon_factor_id.descendant_ids' args: 'carbon.factor' -
carbon_factor_idMany2one → carbon.factordomain="[('id', 'in', allowed_carbon_factor_ids),('carbon_value', '!=', False)]"required=Truestring='Transport mean' args: 'carbon.factor' -
distance_kmIntegerstring='Average weekly distance in kilometers' -
employee_idMany2one → hr.employeestring='Employee' args: 'hr.employee'
-
get_commuting_carbon_value_at_date(self, date)
New fields (1)
-
carbon_commuting_idsOne2many → carbon.hr.commutingstring='Employee commuting records' args: 'carbon.hr.commuting', 'employee_id'
No public methods.
New fields (2)
-
has_locationBooleandefault=Falsestore=True -
work_days_homeIntegercompute='_compute_work_days_home'help='Number of days per week the employee works from home.'store=Truestring='Work Days at Home'
No public methods.
New fields (9)
-
employee_commuting_account_idMany2one → account.accountdomain="[('deprecated', '=', False)]"string='Employee Commuting Account' args: 'account.account' -
employee_commuting_carbon_cronjob_activeBooleandefault=Falsestring='Cronjob active' -
employee_commuting_carbon_factor_idMany2one → carbon.factorargs: 'carbon.factor' -
employee_commuting_journal_idMany2one → account.journalargs: 'account.journal' -
employee_commuting_post_account_move_activeBooleandefault=Falsestring='Post account move when cron is finished' -
employee_remote_work_account_idMany2one → account.accountdomain="[('deprecated', '=', False)]"string='Employee Remote Work Account' args: 'account.account' -
employee_remote_work_carbon_cronjob_activeBooleandefault=Falsestring='Remote Work Cronjob Active' -
employee_remote_work_carbon_factor_idMany2one → carbon.factorargs: 'carbon.factor' -
employee_remote_work_journal_idMany2one → account.journalargs: 'account.journal'
-
calculate_average(self, metric_sum, count)Calculates the average of a given metric if the count is non-zero. -
carbon_commuting_create_account_move(self, account_move_date, to_post=False) -
create_account_move(self, ref, journal_id, account_move_date, aml_vals_list, mode)Creates an account move with the given parameters. -
delete_existing_account_moves(self, account_move_date, mode)Deletes existing account moves for a given date to avoid duplicates. -
get_employees_with_contracts(self, account_move_date, employees_domain=None)Retrieves employees with active contracts in the company. -
prepare_account_move_line(self, employee, carbon_value, account_id, description)Prepares account move line dictionary for an employee. -
remote_work_create_account_move(self, account_move_date, to_post=False)Generate account move for employee remote work carbon emissions. Calculates carbon emissions based on remote work days for each employee, fallback to average if no employees with remote work set.
New fields (9)
-
employee_commuting_account_idMany2one → account.accountreadonly=Falserelated='company_id.employee_commuting_account_id' args: 'account.account' -
employee_commuting_carbon_cronjob_activeBooleanreadonly=Falserelated='company_id.employee_commuting_carbon_cronjob_active' args: 'Cron job active' -
employee_commuting_carbon_factor_idMany2one → carbon.factorreadonly=Falserelated='company_id.employee_commuting_carbon_factor_id' args: 'carbon.factor' -
employee_commuting_journal_idMany2one → account.journalreadonly=Falserelated='company_id.employee_commuting_journal_id' args: 'account.journal' -
employee_commuting_post_account_move_activeBooleanreadonly=Falserelated='company_id.employee_commuting_post_account_move_active'string='Post account move when cron is finished' -
employee_remote_work_account_idMany2one → account.accountreadonly=Falserelated='company_id.employee_remote_work_account_id' args: 'account.account' -
employee_remote_work_carbon_cronjob_activeBooleanreadonly=Falserelated='company_id.employee_remote_work_carbon_cronjob_active' args: 'Cron job' -
employee_remote_work_carbon_factor_idMany2one → carbon.factordomain=<expr>readonly=Falserelated='company_id.employee_remote_work_carbon_factor_id' args: 'carbon.factor' -
employee_remote_work_journal_idMany2one → account.journalreadonly=Falserelated='company_id.employee_remote_work_journal_id' args: 'account.journal'
-
set_values(self)
Loading…
Loading…
- Status
- Open migration PR — not merged yet for this version
- CI status
- green — ready to merge
- Open since
- 206 days ago
- Last activity
- 206 days ago
- Repository
- OCA/sustainability
- Pull request
- [19.0][MIG] sustainability_employee_commuting: Migration to 19.0 (#525)