parent
6f60b165f8
commit
e5997c9958
|
@ -2130,7 +2130,10 @@ class orm(orm_template):
|
|||
|
||||
for order, object, ids, fields in result_store:
|
||||
if object<>self._name:
|
||||
self.pool.get(object)._store_set_values(cr, uid, ids, fields, context)
|
||||
cr.execute('select id from '+self._table+' where id in ('+','.join(map(str, ids))+')')
|
||||
ids = map(lambda x: x[0], cr.fetchall())
|
||||
if ids:
|
||||
self.pool.get(object)._store_set_values(cr, uid, ids, fields, context)
|
||||
return True
|
||||
|
||||
#
|
||||
|
|
|
@ -677,7 +677,12 @@ form: module.record_id""" % (xml_id,)
|
|||
if self.isnoupdate(data_node) and self.mode != 'init':
|
||||
# check if the xml record has an id string
|
||||
if rec_id:
|
||||
id = self.pool.get('ir.model.data')._update_dummy(cr, self.uid, rec_model, self.module, rec_id)
|
||||
if '.' in rec_id:
|
||||
module,rec_id2 = rec_id.split('.')
|
||||
else:
|
||||
module = self.module
|
||||
rec_id2 = rec_id
|
||||
id = self.pool.get('ir.model.data')._update_dummy(cr, self.uid, rec_model, module, rec_id2)
|
||||
# check if the resource already existed at the last update
|
||||
if id:
|
||||
# if it existed, we don't update the data, but we need to
|
||||
|
|
|
@ -566,7 +566,10 @@ def trans_load_data(db_name, fileobj, fileformat, lang, strict=False, lang_name=
|
|||
finally:
|
||||
# locale.resetlocale is bugged with some locales.
|
||||
# we need to normalize the result of locale.getdefaultlocale()
|
||||
locale.setlocale(locale.LC_ALL, locale.normalize(locale._build_localename(locale.getdefaultlocale())))
|
||||
try:
|
||||
locale.setlocale(locale.LC_ALL, locale.normalize(locale._build_localename(locale.getdefaultlocale())))
|
||||
except:
|
||||
locale.setlocale(locale.LC_ALL, lc)
|
||||
|
||||
|
||||
# now, the serious things: we read the language file
|
||||
|
|
Loading…
Reference in New Issue