From 84906d26f72760a45083b6a8b654f87a0d886527 Mon Sep 17 00:00:00 2001 From: Fekete Mihai Date: Sat, 24 Mar 2018 17:39:10 +0200 Subject: [PATCH 1/5] Fix unlink date range type. --- date_range/models/date_range.py | 3 ++- date_range/tests/test_date_range_type.py | 16 ++++++++++++++++ 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/date_range/models/date_range.py b/date_range/models/date_range.py index 92ba83fe0..42796c544 100644 --- a/date_range/models/date_range.py +++ b/date_range/models/date_range.py @@ -19,7 +19,8 @@ class DateRange(models.Model): date_start = fields.Date(string='Start date', required=True) date_end = fields.Date(string='End date', required=True) type_id = fields.Many2one( - comodel_name='date.range.type', string='Type', index=1, required=True) + comodel_name='date.range.type', string='Type', index=1, required=True, + ondelete='restrict') type_name = fields.Char( string='Type', related='type_id.name', readonly=True, store=True) company_id = fields.Many2one( diff --git a/date_range/tests/test_date_range_type.py b/date_range/tests/test_date_range_type.py index 0816267f3..668cdc46b 100644 --- a/date_range/tests/test_date_range_type.py +++ b/date_range/tests/test_date_range_type.py @@ -3,6 +3,8 @@ # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl) from odoo.tests.common import TransactionCase +from odoo.tools import mute_logger +from psycopg2 import IntegrityError class DateRangeTypeTest(TransactionCase): @@ -18,3 +20,17 @@ class DateRangeTypeTest(TransactionCase): 'company_id': False, 'allow_overlap': False}) self.assertFalse(drt.company_id) + + def test_unlink(self): + date_range = self.env['date.range'] + drt = self.env['date.range.type'].create( + {'name': 'Fiscal year', + 'allow_overlap': False}) + date_range.create({ + 'name': 'FS2016', + 'date_start': '2015-01-01', + 'date_end': '2016-12-31', + 'type_id': drt.id, + }) + with self.assertRaises(IntegrityError), mute_logger('odoo.sql_db'): + drt.unlink() From b291ccfc725c671a96e1ab3ffa068180e8eb5aa0 Mon Sep 17 00:00:00 2001 From: mreficent Date: Fri, 23 Mar 2018 11:58:42 +0100 Subject: [PATCH 2/5] date_range: adapt to multicompany --- date_range/models/date_range.py | 20 ++++++++++++++++++- date_range/models/date_range_type.py | 17 ++++++++++++++++ date_range/security/date_range_security.xml | 4 ++-- date_range/security/ir.model.access.csv | 2 +- date_range/wizard/date_range_generator.py | 22 ++++++++++++++++++++- 5 files changed, 60 insertions(+), 5 deletions(-) diff --git a/date_range/models/date_range.py b/date_range/models/date_range.py index 42796c544..9fbd47545 100644 --- a/date_range/models/date_range.py +++ b/date_range/models/date_range.py @@ -20,7 +20,8 @@ class DateRange(models.Model): date_end = fields.Date(string='End date', required=True) type_id = fields.Many2one( comodel_name='date.range.type', string='Type', index=1, required=True, - ondelete='restrict') + ondelete='restrict', domain="['|', ('company_id', '=', company_id), " + "('company_id', '=', False)]") type_name = fields.Char( string='Type', related='type_id.name', readonly=True, store=True) company_id = fields.Many2one( @@ -34,6 +35,23 @@ class DateRange(models.Model): ('date_range_uniq', 'unique (name,type_id, company_id)', 'A date range must be unique per company !')] + @api.onchange('company_id') + def _onchange_company_id(self): + if self.company_id and self.type_id.company_id and \ + self.type_id.company_id != self.company_id: + self._cache.update( + self._convert_to_cache({'type_id': False}, update=True)) + + @api.multi + @api.constrains('company_id', 'type_id') + def _check_company_id_type_id(self): + for rec in self.sudo(): + if rec.company_id and rec.type_id.company_id and\ + rec.company_id != rec.type_id.company_id: + raise ValidationError( + _('The Company in the Date Range and in ' + 'Date Range Type must be the same.')) + @api.constrains('type_id', 'date_start', 'date_end', 'company_id') def _validate_range(self): for this in self: diff --git a/date_range/models/date_range_type.py b/date_range/models/date_range_type.py index bff6e4f5d..3450c6452 100644 --- a/date_range/models/date_range_type.py +++ b/date_range/models/date_range_type.py @@ -3,6 +3,8 @@ # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). from odoo import api, fields, models +from odoo.tools.translate import _ +from odoo.exceptions import ValidationError class DateRangeType(models.Model): @@ -22,7 +24,22 @@ class DateRangeType(models.Model): company_id = fields.Many2one( comodel_name='res.company', string='Company', index=1, default=_default_company) + date_range_ids = fields.One2many('date.range', 'type_id', string='Ranges') _sql_constraints = [ ('date_range_type_uniq', 'unique (name,company_id)', 'A date range type must be unique per company !')] + + @api.constrains('company_id') + def _check_company_id(self): + if not self.env.context.get('bypass_company_validation', False): + for rec in self.sudo(): + if not rec.company_id: + continue + if bool(self.date_range_ids.filtered( + lambda r: r.company_id and + r.company_id != rec.company_id)): + raise ValidationError( + _('You cannot change the company, as this ' + 'Date Range Type is assigned to Date Range ' + '(%s).') % (self.date_range_ids.name_get()[0][1])) diff --git a/date_range/security/date_range_security.xml b/date_range/security/date_range_security.xml index 87862f84b..70f04266b 100644 --- a/date_range/security/date_range_security.xml +++ b/date_range/security/date_range_security.xml @@ -3,11 +3,11 @@ Date Range Type multi-company - ['|',('company_id','=',user.company_id.id),('company_id','=',False)] + ['|',('company_id','child_of',[user.company_id.id]),('company_id','=',False)] Date Range multi-company - ['|',('company_id','=',user.company_id.id),('company_id','=',False)] + ['|',('company_id','child_of',[user.company_id.id]),('company_id','=',False)] diff --git a/date_range/security/ir.model.access.csv b/date_range/security/ir.model.access.csv index aabe7149d..1fe149604 100644 --- a/date_range/security/ir.model.access.csv +++ b/date_range/security/ir.model.access.csv @@ -2,4 +2,4 @@ id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink access_date_range_date_range,date_range.date_range,model_date_range,base.group_user,1,0,0,0 access_date_range_date_range_type,date_range.date_range_type,model_date_range_type,base.group_user,1,0,0,0 access_date_range_date_range_config,date_range.date_range.config,model_date_range,base.group_system,1,1,1,1 -access_date_range_date_range_type_config,date_range.date_range_type.config,model_date_range_type,base.group_system,1,1,1,1 \ No newline at end of file +access_date_range_date_range_type_config,date_range.date_range_type.config,model_date_range_type,base.group_system,1,1,1,1 diff --git a/date_range/wizard/date_range_generator.py b/date_range/wizard/date_range_generator.py index 970af6b71..2e9d8658d 100644 --- a/date_range/wizard/date_range_generator.py +++ b/date_range/wizard/date_range_generator.py @@ -3,6 +3,8 @@ # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). from odoo import api, fields, models +from odoo.tools.translate import _ +from odoo.exceptions import ValidationError from dateutil.rrule import (rrule, YEARLY, MONTHLY, @@ -22,7 +24,8 @@ class DateRangeGenerator(models.TransientModel): date_start = fields.Date(strint='Start date', required=True) type_id = fields.Many2one( comodel_name='date.range.type', string='Type', required=True, - ondelete='cascade') + domain="['|', ('company_id', '=', company_id), " + "('company_id', '=', False)]", ondelete='cascade') company_id = fields.Many2one( comodel_name='res.company', string='Company', default=_default_company) @@ -59,6 +62,23 @@ class DateRangeGenerator(models.TransientModel): 'company_id': self.company_id.id}) return date_ranges + @api.onchange('company_id') + def _onchange_company_id(self): + if self.company_id and self.type_id.company_id and \ + self.type_id.company_id != self.company_id: + self._cache.update( + self._convert_to_cache({'type_id': False}, update=True)) + + @api.multi + @api.constrains('company_id', 'type_id') + def _check_company_id_type_id(self): + for rec in self.sudo(): + if rec.company_id and rec.type_id.company_id and\ + rec.company_id != rec.type_id.company_id: + raise ValidationError( + _('The Company in the Date Range Generator and in ' + 'Date Range Type must be the same.')) + @api.multi def action_apply(self): date_ranges = self._compute_date_ranges() From 27ad43f9ff5b8ba68f127f56f2510da0e48c43d4 Mon Sep 17 00:00:00 2001 From: mreficent Date: Mon, 19 Nov 2018 10:11:18 +0100 Subject: [PATCH 3/5] [PATCH] [ADD] date_range: multicompany tests --- date_range/tests/test_date_range.py | 63 ++++++++++++++----- date_range/tests/test_date_range_generator.py | 44 ++++++++++++- date_range/tests/test_date_range_type.py | 31 ++++++++- 3 files changed, 118 insertions(+), 20 deletions(-) diff --git a/date_range/tests/test_date_range.py b/date_range/tests/test_date_range.py index e5cd5e480..1b774b6f2 100644 --- a/date_range/tests/test_date_range.py +++ b/date_range/tests/test_date_range.py @@ -10,45 +10,55 @@ class DateRangeTest(TransactionCase): def setUp(self): super(DateRangeTest, self).setUp() + self.date_range = self.env['date.range'] self.type = self.env['date.range.type'].create( {'name': 'Fiscal year', 'company_id': False, 'allow_overlap': False}) + self.company = self.env['res.company'].create({ + 'name': 'Test company', + }) + self.company_2 = self.env['res.company'].create({ + 'name': 'Test company 2', + 'parent_id': self.company.id, + }) + self.typeB = self.env['date.range.type'].create( + {'name': 'Fiscal year B', + 'company_id': self.company.id, + 'allow_overlap': False}) + def test_default_company(self): - date_range = self.env['date.range'] - dt = date_range.create({ + dr = self.date_range.create({ 'name': 'FS2016', 'date_start': '2015-01-01', 'date_end': '2016-12-31', 'type_id': self.type.id, }) - self.assertTrue(dt.company_id) + self.assertTrue(dr.company_id) # you can specify company_id to False - dt = date_range.create({ + dr = self.date_range.create({ 'name': 'FS2016_NO_COMPANY', 'date_start': '2015-01-01', 'date_end': '2016-12-31', 'type_id': self.type.id, 'company_id': False }) - self.assertFalse(dt.company_id) + self.assertFalse(dr.company_id) def test_empty_company(self): - date_range = self.env['date.range'] - dt = date_range.create({ + dr = self.date_range.create({ 'name': 'FS2016', 'date_start': '2015-01-01', 'date_end': '2016-12-31', 'type_id': self.type.id, 'company_id': None, }) - self.assertEqual(dt.name, 'FS2016') + self.assertEqual(dr.name, 'FS2016') def test_invalid(self): - date_range = self.env['date.range'] with self.assertRaises(ValidationError) as cm: - date_range.create({ + self.date_range.create({ 'name': 'FS2016', 'date_end': '2015-01-01', 'date_start': '2016-12-31', @@ -59,15 +69,14 @@ class DateRangeTest(TransactionCase): 'FS2016 is not a valid range (2016-12-31 > 2015-01-01)') def test_overlap(self): - date_range = self.env['date.range'] - date_range.create({ + self.date_range.create({ 'name': 'FS2015', 'date_start': '2015-01-01', 'date_end': '2015-12-31', 'type_id': self.type.id, }) with self.assertRaises(ValidationError) as cm, self.env.cr.savepoint(): - date_range.create({ + self.date_range.create({ 'name': 'FS2016', 'date_start': '2015-01-01', 'date_end': '2016-12-31', @@ -76,7 +85,7 @@ class DateRangeTest(TransactionCase): self.assertEqual(cm.exception.name, 'FS2016 overlaps FS2015') # check it's possible to overlap if it's allowed by the date range type self.type.allow_overlap = True - dr = date_range.create({ + dr = self.date_range.create({ 'name': 'FS2016', 'date_start': '2015-01-01', 'date_end': '2016-12-31', @@ -85,8 +94,7 @@ class DateRangeTest(TransactionCase): self.assertEquals(dr.name, 'FS2016') def test_domain(self): - date_range = self.env['date.range'] - dr = date_range.create({ + dr = self.date_range.create({ 'name': 'FS2015', 'date_start': '2015-01-01', 'date_end': '2015-12-31', @@ -98,3 +106,26 @@ class DateRangeTest(TransactionCase): domain, [('my_field', '>=', '2015-01-01'), ('my_field', '<=', '2015-12-31')]) + + def test_date_range_multicompany_1(self): + dr = self.date_range.new({ + 'name': 'FS2016', + 'date_start': '2015-01-01', + 'date_end': '2016-12-31', + 'type_id': self.typeB.id, + 'company_id': self.company.id, + }) + dr._cache.update(dr._convert_to_cache( + {'company_id': self.company_2.id}, update=True)) + dr._onchange_company_id() + self.assertFalse(dr.type_id) + + def test_date_range_multicompany_2(self): + with self.assertRaises(ValidationError): + self.date_range.create({ + 'name': 'FS2016', + 'date_start': '2015-01-01', + 'date_end': '2016-12-31', + 'type_id': self.typeB.id, + 'company_id': self.company_2.id, + }) diff --git a/date_range/tests/test_date_range_generator.py b/date_range/tests/test_date_range_generator.py index 419d7bcc7..7764fd3e3 100644 --- a/date_range/tests/test_date_range_generator.py +++ b/date_range/tests/test_date_range_generator.py @@ -3,6 +3,7 @@ # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl)nses/agpl). from odoo.tests.common import TransactionCase +from odoo.exceptions import ValidationError from dateutil.rrule import MONTHLY @@ -10,14 +11,26 @@ class DateRangeGeneratorTest(TransactionCase): def setUp(self): super(DateRangeGeneratorTest, self).setUp() + self.generator = self.env['date.range.generator'] self.type = self.env['date.range.type'].create( {'name': 'Fiscal year', 'company_id': False, 'allow_overlap': False}) + self.company = self.env['res.company'].create({ + 'name': 'Test company', + }) + self.company_2 = self.env['res.company'].create({ + 'name': 'Test company 2', + 'parent_id': self.company.id, + }) + self.typeB = self.env['date.range.type'].create( + {'name': 'Fiscal year B', + 'company_id': self.company.id, + 'allow_overlap': False}) + def test_generate(self): - generator = self.env['date.range.generator'] - generator = generator.create({ + generator = self.generator.create({ 'date_start': '1943-01-01', 'name_prefix': '1943-', 'type_id': self.type.id, @@ -32,3 +45,30 @@ class DateRangeGeneratorTest(TransactionCase): self.assertEqual(range4.date_start, '1943-10-01') self.assertEqual(range4.date_end, '1943-12-31') self.assertEqual(range4.type_id, self.type) + + def test_generator_multicompany_1(self): + generator = self.generator.new({ + 'date_start': '1943-01-01', + 'name_prefix': '1943-', + 'type_id': self.typeB.id, + 'duration_count': 3, + 'unit_of_time': MONTHLY, + 'count': 4, + 'company_id': self.company.id, + }) + generator._cache.update(generator._convert_to_cache( + {'company_id': self.company_2.id}, update=True)) + generator._onchange_company_id() + self.assertFalse(generator.type_id) + + def test_generator_multicompany_2(self): + with self.assertRaises(ValidationError): + self.generator.create({ + 'date_start': '1943-01-01', + 'name_prefix': '1943-', + 'type_id': self.typeB.id, + 'duration_count': 3, + 'unit_of_time': MONTHLY, + 'count': 4, + 'company_id': self.company_2.id, + }) diff --git a/date_range/tests/test_date_range_type.py b/date_range/tests/test_date_range_type.py index 668cdc46b..dce4587e9 100644 --- a/date_range/tests/test_date_range_type.py +++ b/date_range/tests/test_date_range_type.py @@ -5,17 +5,29 @@ from odoo.tests.common import TransactionCase from odoo.tools import mute_logger from psycopg2 import IntegrityError +from odoo.exceptions import ValidationError class DateRangeTypeTest(TransactionCase): + def setUp(self): + super(DateRangeTypeTest, self).setUp() + self.type = self.env['date.range.type'] + self.company = self.env['res.company'].create({ + 'name': 'Test company', + }) + self.company_2 = self.env['res.company'].create({ + 'name': 'Test company 2', + 'parent_id': self.company.id, + }) + def test_default_company(self): - drt = self.env['date.range.type'].create( + drt = self.type.create( {'name': 'Fiscal year', 'allow_overlap': False}) self.assertTrue(drt.company_id) # you can specify company_id to False - drt = self.env['date.range.type'].create( + drt = self.type.create( {'name': 'Fiscal year', 'company_id': False, 'allow_overlap': False}) @@ -34,3 +46,18 @@ class DateRangeTypeTest(TransactionCase): }) with self.assertRaises(IntegrityError), mute_logger('odoo.sql_db'): drt.unlink() + + def test_type_multicompany(self): + drt = self.type.create( + {'name': 'Fiscal year', + 'company_id': False, + 'allow_overlap': False}) + self.env['date.range'].create({ + 'name': 'FS2016', + 'date_start': '2015-01-01', + 'date_end': '2016-12-31', + 'type_id': drt.id, + 'company_id': self.company.id, + }) + with self.assertRaises(ValidationError): + drt.company_id = self.company_2 From 2cd241a5406236753cd6a8b037a3300f507233c8 Mon Sep 17 00:00:00 2001 From: Andrea Date: Tue, 2 Oct 2018 15:50:00 +0200 Subject: [PATCH 4/5] fixed constrains + fixed onchange + other minor fixes --- date_range/models/date_range.py | 3 ++- date_range/models/date_range_type.py | 5 +++-- date_range/readme/CONTRIBUTORS.rst | 1 + date_range/readme/INSTALL.rst | 2 -- date_range/wizard/date_range_generator.py | 1 + 5 files changed, 7 insertions(+), 5 deletions(-) diff --git a/date_range/models/date_range.py b/date_range/models/date_range.py index 9fbd47545..29da5b600 100644 --- a/date_range/models/date_range.py +++ b/date_range/models/date_range.py @@ -9,6 +9,7 @@ from odoo.exceptions import ValidationError class DateRange(models.Model): _name = "date.range" + _description = "Date Range" _order = "type_name,date_start" @api.model @@ -35,7 +36,7 @@ class DateRange(models.Model): ('date_range_uniq', 'unique (name,type_id, company_id)', 'A date range must be unique per company !')] - @api.onchange('company_id') + @api.onchange('company_id', 'type_id') def _onchange_company_id(self): if self.company_id and self.type_id.company_id and \ self.type_id.company_id != self.company_id: diff --git a/date_range/models/date_range_type.py b/date_range/models/date_range_type.py index 3450c6452..3d14ff467 100644 --- a/date_range/models/date_range_type.py +++ b/date_range/models/date_range_type.py @@ -9,6 +9,7 @@ from odoo.exceptions import ValidationError class DateRangeType(models.Model): _name = "date.range.type" + _description = "Date Range Type" @api.model def _default_company(self): @@ -36,10 +37,10 @@ class DateRangeType(models.Model): for rec in self.sudo(): if not rec.company_id: continue - if bool(self.date_range_ids.filtered( + if bool(rec.date_range_ids.filtered( lambda r: r.company_id and r.company_id != rec.company_id)): raise ValidationError( _('You cannot change the company, as this ' 'Date Range Type is assigned to Date Range ' - '(%s).') % (self.date_range_ids.name_get()[0][1])) + '(%s).') % (rec.date_range_ids.name_get()[0][1])) diff --git a/date_range/readme/CONTRIBUTORS.rst b/date_range/readme/CONTRIBUTORS.rst index 4d3702578..38b10b316 100644 --- a/date_range/readme/CONTRIBUTORS.rst +++ b/date_range/readme/CONTRIBUTORS.rst @@ -1,3 +1,4 @@ * Laurent Mignon * Alexis de Lattre * Miquel Raïch +* Andrea Stirpe diff --git a/date_range/readme/INSTALL.rst b/date_range/readme/INSTALL.rst index 695d21faf..f4bf76d5e 100644 --- a/date_range/readme/INSTALL.rst +++ b/date_range/readme/INSTALL.rst @@ -1,3 +1 @@ The addon use the daterange method from postgres. This method is supported as of postgresql 9.2 - - diff --git a/date_range/wizard/date_range_generator.py b/date_range/wizard/date_range_generator.py index 2e9d8658d..534263e0c 100644 --- a/date_range/wizard/date_range_generator.py +++ b/date_range/wizard/date_range_generator.py @@ -15,6 +15,7 @@ from dateutil.relativedelta import relativedelta class DateRangeGenerator(models.TransientModel): _name = 'date.range.generator' + _description = 'Date Range Generator' @api.model def _default_company(self): From e0a6e2de7cdfe38532b51e8f2f6abc879ac3079e Mon Sep 17 00:00:00 2001 From: "Laurent Mignon (ACSONE)" Date: Mon, 19 Nov 2018 09:19:37 +0100 Subject: [PATCH 5/5] Merge server-ur/11.0 into 10.0 until https://github.com/OCA/server-ux/commit/79bed09a01414fac4561dca6d8143f4ab58eff63#diff-3db8a615cdc543d077b5b3cfbc7f939d add history --- date_range/README.rst | 19 ++++++++- date_range/__manifest__.py | 2 +- date_range/readme/HISTORY.rst | 12 ++++++ date_range/static/description/index.html | 50 +++++++++++++++++------- 4 files changed, 66 insertions(+), 17 deletions(-) create mode 100644 date_range/readme/HISTORY.rst diff --git a/date_range/README.rst b/date_range/README.rst index b88a32166..b66c7cf56 100644 --- a/date_range/README.rst +++ b/date_range/README.rst @@ -38,8 +38,6 @@ Installation The addon use the daterange method from postgres. This method is supported as of postgresql 9.2 - - Usage ===== @@ -91,6 +89,22 @@ To configure this module, you need to: :scale: 80 % :alt: Date range as filter result +Changelog +========= + +10.0.2.0.1 (2018-11-19) +~~~~~~~~~~~~~~~~~~~~~~~ + +* [FIX] Fix bug in DateRange._onchange_company_id not called + when type_id is changed +* [FIX] Fix bug in DateRangeType._check_company_id when called + with more than one record. + (`#26 `_) +* [IMP] Adapt module to work in multi company. + (`#10 `_) +* [FIX] Fix unlink date range type. + (`#9 `_) + Bug Tracker =========== @@ -115,6 +129,7 @@ Contributors * Laurent Mignon * Alexis de Lattre * Miquel Raïch +* Andrea Stirpe Maintainers ~~~~~~~~~~~ diff --git a/date_range/__manifest__.py b/date_range/__manifest__.py index 2091c8495..d5309e0b0 100644 --- a/date_range/__manifest__.py +++ b/date_range/__manifest__.py @@ -4,7 +4,7 @@ { "name": "Date Range", "summary": "Manage all kind of date range", - "version": "10.0.1.0.2", + "version": "10.0.2.0.1", "category": "Uncategorized", "website": "https://odoo-community.org/", "author": "ACSONE SA/NV, Odoo Community Association (OCA)", diff --git a/date_range/readme/HISTORY.rst b/date_range/readme/HISTORY.rst new file mode 100644 index 000000000..9dcf0ba1d --- /dev/null +++ b/date_range/readme/HISTORY.rst @@ -0,0 +1,12 @@ +10.0.2.0.1 (2018-11-19) +~~~~~~~~~~~~~~~~~~~~~~~ + +* [FIX] Fix bug in DateRange._onchange_company_id not called + when type_id is changed +* [FIX] Fix bug in DateRangeType._check_company_id when called + with more than one record. + (`#26 `_) +* [IMP] Adapt module to work in multi company. + (`#10 `_) +* [FIX] Fix unlink date range type. + (`#9 `_) diff --git a/date_range/static/description/index.html b/date_range/static/description/index.html index d460ea125..45303357a 100644 --- a/date_range/static/description/index.html +++ b/date_range/static/description/index.html @@ -373,23 +373,27 @@ your values in tree views.

Table of contents

-

Installation

+

Installation

The addon use the daterange method from postgres. This method is supported as of postgresql 9.2

-

Usage

+

Usage

To configure this module, you need to:

  • Go to Settings > Technical > Date ranges > Date Range Types where @@ -428,8 +432,25 @@ you can create date ranges.

+
+

Changelog

+
+

10.0.2.0.1 (2018-11-19)

+
    +
  • [FIX] Fix bug in DateRange._onchange_company_id not called +when type_id is changed
  • +
  • [FIX] Fix bug in DateRangeType._check_company_id when called +with more than one record. +(#26)
  • +
  • [IMP] Adapt module to work in multi company. +(#10)
  • +
  • [FIX] Fix unlink date range type. +(#9)
  • +
+
+
-

Bug Tracker

+

Bug Tracker

Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. If you spotted it first, help us smashing it by providing a detailed and welcomed @@ -437,23 +458,24 @@ If you spotted it first, help us smashing it by providing a detailed and welcome

Do not contact contributors directly about support or help with technical issues.

-

Credits

+

Credits

-

Authors

+

Authors

  • ACSONE SA/NV
-

Maintainers

+

Maintainers

This module is maintained by the OCA.

Odoo Community Association

OCA, or the Odoo Community Association, is a nonprofit organization whose