Commit Graph
3 Commits
Author SHA1 Message Date
Jérome Maes 8cda7998ed [IMP] resource: add 35 and 38h/week working hours calendars
This commit proposes to add 35 and 38 hours/week resource calendars.
Those are considered as standard for a lot of countries. This helps
users starting with odoo time tracking.
2017-04-27 10:34:50 +02:00
Thibault Delavallée 2b90398cb6 [REF] resource: strengthen link between companies and calendars
Purpose of this commit is to always have a default calendar for each
company and ensure it is correctly set on resources.

Some cleaning is also performed in resource models to remove unused
fields, improve labels and make views a bit more odoo-ish.

 * [REF] res_company: add a m2o to the default calendar to use in the
   company as well as a o2m linking all resource calendars used in the
   company. Some code has been added to correctly update existing
   companies when installing the module;
 * [REF] resource_calendar
  * [REM] manager field on resource.calendar: this field is never used
    and is not necessary anyway
  * [ADD] global_leave_ids: filter leaves on a calendar to see global
    company leaves
  * [IMP] better default company / calendar computation to ensure there
    is always a calendar attached to a resource
  * [IMP] improve resource and calendar views in order to look more like
    other odoo views
2017-01-18 10:26:53 +01:00
Thibault Delavallée 9250cc60e1 [IMP] resource: set default calendar as data
Currently there is no default resource calendar. This leads to calendar
being rarely used as it is not clear how to define them and how to use
them. Moreover some code handle default-like calendar by trying to
use 8-16 work hours; this should be replaced by having a real default
calendar.

This commit replaces the demo calendar by a real data calendar. It will
soon be used as default everywhere a resource calendar can be defined.

Future improvements will come to make resource easier to use and clean
its API. This commit is only the beginning !
2017-01-18 10:24:41 +01:00