Stefan Rijnhart (Therp) has proposed merging
lp:~openerp-community/openobject-addons/stefan-therp_lp696176-6.1 into
lp:openobject-addons.
Requested reviews:
OpenERP Core Team (openerp)
Related bugs:
Bug #696176 in OpenERP Addons: "TypeError: node contents must be a string
when using base_module_record "
https://bugs.launchpad.net/openobject-addons/+bug/696176
For more details, see:
https://code.launchpad.net/~openerp-community/openobject-addons/stefan-therp_lp696176-6.1/+merge/77493
This branch fixes a bug that prevents base_record_module to produce an xml data
file for a model containing a fields.selection with integer type keys
(account.account.type is a good test case).
--
https://code.launchpad.net/~openerp-community/openobject-addons/stefan-therp_lp696176-6.1/+merge/77493
Your team OpenERP Community is subscribed to branch
lp:~openerp-community/openobject-addons/stefan-therp_lp696176-6.1.
=== modified file 'base_module_record/base_module_record.py'
--- base_module_record/base_module_record.py 2011-06-15 15:31:51 +0000
+++ base_module_record/base_module_record.py 2011-09-29 10:21:16 +0000
@@ -104,7 +104,8 @@
for key,val in data.items():
if not (val or (fields[key]['type']=='boolean')):
continue
- if fields[key]['type'] in ('integer','float'):
+ if (fields[key]['type'] in ('integer','float') or
+ fields[key]['type'] == 'selection' and isinstance(val, int)):
field = doc.createElement('field')
field.setAttribute("name", key)
field.setAttribute("eval", val and str(val) or 'False' )
_______________________________________________
Mailing list: https://launchpad.net/~openerp-community
Post to : [email protected]
Unsubscribe : https://launchpad.net/~openerp-community
More help : https://help.launchpad.net/ListHelp