summaryrefslogtreecommitdiff
path: root/addons/resource/models
diff options
context:
space:
mode:
authorMartin Trigaux <mat@odoo.com>2020-06-04 12:39:11 +0200
committerMartin Trigaux <mat@odoo.com>2020-06-18 13:03:34 +0200
commitba244cef01132347df4d2d9553ea3105ba13a938 (patch)
tree20cdb55afb6b9f700bfe2844a90ca8de0050c941 /addons/resource/models
parent3c3b88f6768e31417263b3828a874ca204e29514 (diff)
[IMP] *: replace to new _() syntax
Using a few regex like \((_\(.*%s.*)(\) % )([\w\[\]][\w .\[\]\(\)'"]*)\) ($1, $3)) Old syntax is still compatible but starts the migration to the new syntax that catches error.
Diffstat (limited to 'addons/resource/models')
-rw-r--r--addons/resource/models/resource.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/addons/resource/models/resource.py b/addons/resource/models/resource.py
index 7c497a61856..e590bdc0643 100644
--- a/addons/resource/models/resource.py
+++ b/addons/resource/models/resource.py
@@ -160,7 +160,7 @@ class ResourceCalendar(models.Model):
def default_get(self, fields):
res = super(ResourceCalendar, self).default_get(fields)
if not res.get('name') and res.get('company_id'):
- res['name'] = _('Working Hours of %s') % self.env['res.company'].browse(res['company_id']).name
+ res['name'] = _('Working Hours of %s', self.env['res.company'].browse(res['company_id']).name)
if 'attendance_ids' in fields and not res.get('attendance_ids'):
res['attendance_ids'] = [
(0, 0, {'name': _('Monday Morning'), 'dayofweek': '0', 'hour_from': 8, 'hour_to': 12, 'day_period': 'morning'}),