diff --git a/addons/account_followup/report/account_followup_print.py b/addons/account_followup/report/account_followup_print.py index eecba81acb9..ffac09cc082 100644 --- a/addons/account_followup/report/account_followup_print.py +++ b/addons/account_followup/report/account_followup_print.py @@ -100,9 +100,12 @@ class report_rappel(report_sxw.rml_parse): partner_max_text = i.followup_line_id.description text = partner_max_delay and partner_max_text or default_text if text: + lang_obj = self.pool['res.lang'] + lang_ids = lang_obj.search(self.cr, self.uid, [('code', '=', stat_line.partner_id.lang)], context=context) + date_format = lang_ids and lang_obj.browse(self.cr, self.uid, lang_ids[0], context=context).date_format or '%Y-%m-%d' text = text % { 'partner_name': stat_line.partner_id.name, - 'date': time.strftime('%Y-%m-%d'), + 'date': time.strftime(date_format), 'company_name': stat_line.company_id.name, 'user_signature': self.pool['res.users'].browse(self.cr, self.uid, self.uid, context).signature or '', } diff --git a/addons/hr_timesheet_sheet/static/src/js/timesheet.js b/addons/hr_timesheet_sheet/static/src/js/timesheet.js index ef1e2f17145..ca949937879 100644 --- a/addons/hr_timesheet_sheet/static/src/js/timesheet.js +++ b/addons/hr_timesheet_sheet/static/src/js/timesheet.js @@ -259,7 +259,9 @@ openerp.hr_timesheet_sheet = function(instance) { return; } var ops = self.generate_o2m_value(); - new instance.web.Model("hr.analytic.timesheet").call("on_change_account_id", [[], id]).then(function(res) { + new instance.web.Model("hr.analytic.timesheet").call("multi_on_change_account_id", [[], [id], + new instance.web.CompoundContext({'user_id': self.get('user_id')})]).then(function(res) { + res = res[id]; var def = _.extend({}, self.default_get, res.value, { name: self.description_line, unit_amount: 0,