[MERGE] forward port of branch 7.0 up to 9066da3
This commit is contained in:
commit
cd6dba5257
|
@ -33,9 +33,9 @@ function openerp_pos_basewidget(instance, module){ //module is instance.point_of
|
||||||
amount = amount.toFixed(decimals);
|
amount = amount.toFixed(decimals);
|
||||||
}
|
}
|
||||||
if(this.currency.position === 'after'){
|
if(this.currency.position === 'after'){
|
||||||
return amount + ' ' + this.currency.symbol;
|
return amount + ' ' + (this.currency.symbol || '');
|
||||||
}else{
|
}else{
|
||||||
return this.currency.symbol + ' ' + amount;
|
return (this.currency.symbol || '') + ' ' + amount;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -333,11 +333,11 @@ class ir_translation(osv.osv):
|
||||||
AND name=%s""",
|
AND name=%s""",
|
||||||
(lang or '', types, tools.ustr(name)))
|
(lang or '', types, tools.ustr(name)))
|
||||||
res = cr.fetchone()
|
res = cr.fetchone()
|
||||||
trad = res and tools.ustr(res[0]) or u''
|
trad = res and res[0] or u''
|
||||||
if source and not trad:
|
if source and not trad:
|
||||||
return tools.ustr(source)
|
return tools.ustr(source)
|
||||||
# Remove control characters
|
# Remove control characters
|
||||||
return filter(lambda c: unicodedata.category(c) != 'Cc', trad)
|
return filter(lambda c: unicodedata.category(c) != 'Cc', tools.ustr(trad))
|
||||||
|
|
||||||
def create(self, cr, uid, vals, context=None):
|
def create(self, cr, uid, vals, context=None):
|
||||||
if context is None:
|
if context is None:
|
||||||
|
|
Loading…
Reference in New Issue