summaryrefslogtreecommitdiff
path: root/addons/document_ics/document.py
diff options
context:
space:
mode:
authorHarry (Open ERP) <hmo@tinyerp.com>2009-10-23 11:09:40 +0530
committerHarry (Open ERP) <hmo@tinyerp.com>2009-10-23 11:09:40 +0530
commite0d09ed6bfb553b715dc0e3218f5509a4fae5215 (patch)
treedb8b729130369e8a07696426910bae329f3faf56 /addons/document_ics/document.py
parent0a424fe358d62cf4d56454b85acc52d58570b97e (diff)
[FIX]document_ics : solved accent problem
lp bug: https://launchpad.net/bugs/458415 fixed bzr revid: hmo@tinyerp.com-20091023053940-px64bjhm0fvypu52
Diffstat (limited to 'addons/document_ics/document.py')
-rw-r--r--addons/document_ics/document.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/addons/document_ics/document.py b/addons/document_ics/document.py
index 048a82c7680..2d70f3f5770 100644
--- a/addons/document_ics/document.py
+++ b/addons/document_ics/document.py
@@ -128,6 +128,7 @@ class document_directory_content(osv.osv):
event.add('last-modified').value = ics_datetime(perm[0]['write_date'][:19])
for field in node.content.ics_field_ids:
value = getattr(obj, field.field_id.name)
+ value = value and tools.ustr(value)
if (not value) and field.name=='uid':
value = 'OpenERP-%s_%s@%s' % (node.content.ics_object_id.model, str(obj.id), cr.dbname,)
obj_class.write(cr, uid, [obj.id], {field.field_id.name: value})
@@ -146,7 +147,7 @@ class document_directory_content(osv.osv):
else:
value = ics_datetime(value)
event.add(field.name).value = value
- s= StringIO.StringIO(cal.serialize().encode('utf8'))
+ s= StringIO.StringIO(cal.serialize())
s.name = node
cr.commit()
return s