[MERGE] stock: fix an encoding problem

bzr revid: stw@openerp.com-20120904152037-ow7u2g434htsc2rj
This commit is contained in:
Stephane Wirtel 2012-09-04 17:20:37 +02:00
commit a486ba87c1
1 changed files with 2 additions and 1 deletions

View File

@ -22,6 +22,7 @@ from pychart import *
import pychart.legend
import time
from report.misc import choice_colors
import tools
#
# Draw a graph for stocks
@ -41,7 +42,7 @@ class stock_graph(object):
product_name=product_name.replace('/', '//')
if product_id not in self._datas:
self._datas[product_id] = {}
self._names[product_id] = product_name
self._names[product_id] = tools.ustr(product_name)
for (dt,stock) in datas:
if not dt in self._datas[product_id]:
self._datas[product_id][dt]=0