From 9dac7587aaafb5294abb840191c77e9517482a74 Mon Sep 17 00:00:00 2001 From: Christophe Simonis Date: Mon, 29 Dec 2008 15:55:49 +0100 Subject: [PATCH] [FIX] pricelist: name_get: utf8 it bzr revid: christophe@cobalt-20081229145549-b9gwgmam73yeyg6h --- addons/product/pricelist.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/addons/product/pricelist.py b/addons/product/pricelist.py index 01749be89cb..62bf44134c9 100644 --- a/addons/product/pricelist.py +++ b/addons/product/pricelist.py @@ -26,6 +26,7 @@ from osv import fields, osv from _common import rounding import time from tools import config +from tools.misc import ustr from tools.translate import _ class price_type(osv.osv): @@ -96,13 +97,13 @@ class product_pricelist(osv.osv): result= [] for pl in self.browse(cr, uid, ids, context): - name = str(pl.name) + ' ('+ str(pl.currency_id.name) + ')' + name = "%s (%s)" % (ustr(pl.name), ustr(pl.currency_id.name)) result.append((pl.id,name)) return result def _get_currency(self, cr, uid, ctx): - comp = self.pool.get('res.users').browse(cr,uid,uid).company_id + comp = self.pool.get('res.users').browse(cr, uid, uid).company_id if not comp: comp_id = self.pool.get('res.company').search(cr, uid, [])[0] comp = self.pool.get('res.company').browse(cr, uid, comp_id)