From 070aaa0105eca05b63c4b34bda58c447725b6be2 Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Wed, 2 Sep 2015 15:17:07 +0200 Subject: [PATCH] [FIX] hr_payroll: replace non-ascii help string by unicode literal Would trigger a UnicodeWarning when looking to update ir.model.fields in _field_create (final loop): the unicode value from the database would be compared with the str value from the model, the str would fail to decode triggering the warning and assuming a False test, probably also triggering an unnecessary database UPDATE. --- addons/hr_payroll/hr_payroll.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/hr_payroll/hr_payroll.py b/addons/hr_payroll/hr_payroll.py index 5a66b49e5e5..b51a07a244f 100644 --- a/addons/hr_payroll/hr_payroll.py +++ b/addons/hr_payroll/hr_payroll.py @@ -734,7 +734,7 @@ class hr_salary_rule(osv.osv): 'name':fields.char('Name', required=True, readonly=False), 'code':fields.char('Code', size=64, required=True, help="The code of salary rules can be used as reference in computation of other rules. In that case, it is case sensitive."), 'sequence': fields.integer('Sequence', required=True, help='Use to arrange calculation sequence', select=True), - 'quantity': fields.char('Quantity', help="It is used in computation for percentage and fixed amount.For e.g. A rule for Meal Voucher having fixed amount of 1€ per worked day can have its quantity defined in expression like worked_days.WORK100.number_of_days."), + 'quantity': fields.char('Quantity', help=u"It is used in computation for percentage and fixed amount.For e.g. A rule for Meal Voucher having fixed amount of 1€ per worked day can have its quantity defined in expression like worked_days.WORK100.number_of_days."), 'category_id':fields.many2one('hr.salary.rule.category', 'Category', required=True), 'active':fields.boolean('Active', help="If the active field is set to false, it will allow you to hide the salary rule without removing it."), 'appears_on_payslip': fields.boolean('Appears on Payslip', help="Used to display the salary rule on payslip."),