Commit Graph
12 Commits
Author SHA1 Message Date
Kevin Baptiste ba619ce027 [IMP] hr_holidays: allow users to cancel Time Off
A user without Time Off rights is now allowed to cancel their own
validated time off when:
    - It's not yet started;
    - No work-entries has been generated for it yet.

The time off is archived and the days taken reallocated.

closes odoo/odoo#76722

Taskid: 2643713
Related: odoo/upgrade#2843
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-10-28 11:34:57 +00:00
yhu-odoo 32fc38ef58 [IMP] hr_appraisal: Improve employee archiving flow
PURPOSE
=======

When you close a payroll (employees), there are often a lot of document
linked. Archiving an employee should archive the contract, cancel future
leaves, archive the private address

Specification
=============

Add departure date (hr):
  - Add a Date field to both hr.departure.wizard and hr.employee. In
    the wizard, the field is required.
  - In toggle_active() method in hr.employee, set departure_date to
    false when unarchive the employee.
  - If user has a current running contract, a user error will raise if
    user enter a departure date earlier than the start date of the
    contract.
Add checkbox to set a closing date on hr.contract (hr.contract):
  - In the hr.departure.wizard, set the departure date to be the end
    date of runing contract. Set the states of all draft contracts to
    "cancel".
Add checkbox to free car (hr.fleet):
  - In the hr.departure.wizard, set end_date to
    fleet.vehicle.assignation.log, if there is no end_date or end_date >
    departure_date
  - Go through fleet.vehicle, find records with dirver_id to be the
    employee, set it to False.
Add checkbox to archive private address (hr):
   - when the private address not link to a internel user, set
     employee.address_home_id.active to Flase
   - unarchive it after the employee unarchived
Add checkbox to cancel future appraisals (hr.appraisal)
   - find all appraisals link to the employee and state in
     ['new', 'pending'], set their state to 'cancel'.
Add checkbox to cancel future leaves (hr.holidays):
   - only consider leaves are not in state ['refuse', 'cancel'],
     find leaves with to_date > departure_date, set their state to
     'cancel'.

PR #42526
Task 2153106

Related: odoo/enterprise#7471
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2020-01-29 10:05:12 +00:00
Yannick Tivisse abd73d61a2 [IMP] hr_holidays: Improve general UX (back2basics)
TaskID: 2053585

closes odoo/odoo#35737

Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2019-08-16 11:24:04 +00:00
xmo-odoo b4429c2a91 [FIX] Various P3-related import changes
* LDAP import: python-ldap is not python3-compatible, pyldap is

  Warning: only supported from debian Stretch (current testing)?
  https://packages.debian.org/search?searchon=names&keywords=pyldap

* implicitly relative imports
* imports of moved or removed stdlib modules

issue #8530
2017-04-28 09:06:53 +02:00
Olivier Dony 0bd4545348 [LEGAL] Use global LICENSE/COPYRIGHT files, remove boilerplate text
- Preserved explicit 3rd-party copyright notices
- Explicit boilerplate should not be necessary - copyright law applies
  automatically in all countries thanks to Berne Convention + WTO rules,
  and a reference to the applicable license is clear enough.
2015-06-02 03:16:04 +02:00
Leonardo Donelli 4a0b13ed92 [REF] remove vim modelines and resulting trailing blank lines
Let 2015 be a year without modelines!
cf #4174
2014-12-31 15:52:13 +01:00
mra (Open ERP) b1cd4c9456 [ADD] hr_holidays: print summary by employee => osv memory
bzr revid: mra@tinyerp.com-20100415105220-vwoxot3apvg6kkw1
2010-04-15 16:22:20 +05:30
mra (Open ERP) b8cf5efd2c [ADD] hr_holidays: summary report dept wise => OSV memory
bzr revid: mra@tinyerp.com-20100415052414-ooweg59lx4p9lmp7
2010-04-15 10:54:14 +05:30
Stephane Wirtel fb3ef7a2f4 [FIX] Change the year of the copyright
bzr revid: stephane@openerp.com-20100112091839-a6p7tenhb4e4zxyx
2010-01-12 10:18:39 +01:00
PSO(OpenERP) eb0b928cc0 Changed licencing terms
bzr revid: hda@tinyerp.com-20091014111534-1vtk21rz8byhszzf
2009-10-14 16:45:34 +05:30
ChristopheChauvet(syleam) 41e8ed59ef changed encoding to coding in all py files
lp bug: https://launchpad.net/bugs/357182 fixed

bzr revid: hda@tinyerp.com-20091013055837-3ntnbe8b938xmk97
2009-10-13 11:28:37 +05:30
Fabien Pinckaers 734fa42184 added from extra-addons
bzr revid: fp@tinyerp.com-20080824144543-33o2j8ddmvaxx4ce
2008-08-24 16:45:43 +02:00